From owner-svn-src-stable-9@FreeBSD.ORG Thu Mar 29 09:19:01 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F29F7106564A; Thu, 29 Mar 2012 09:19:00 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C390E8FC0A; Thu, 29 Mar 2012 09:19:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q2T9J0CF085120; Thu, 29 Mar 2012 09:19:00 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q2T9J0hZ085117; Thu, 29 Mar 2012 09:19:00 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201203290919.q2T9J0hZ085117@svn.freebsd.org> From: Konstantin Belousov Date: Thu, 29 Mar 2012 09:19:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r233654 - stable/9/sys/ufs/ffs X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Mar 2012 09:19:01 -0000 Author: kib Date: Thu Mar 29 09:19:00 2012 New Revision: 233654 URL: http://svn.freebsd.org/changeset/base/233654 Log: MFC r232948: Supply boolean as the second argument to ffs_update(), and not a MNT_[NO]WAIT constants, which in fact always caused sync operation. Modified: stable/9/sys/ufs/ffs/ffs_softdep.c stable/9/sys/ufs/ffs/ffs_vnops.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/ufs/ffs/ffs_softdep.c ============================================================================== --- stable/9/sys/ufs/ffs/ffs_softdep.c Thu Mar 29 09:16:10 2012 (r233653) +++ stable/9/sys/ufs/ffs/ffs_softdep.c Thu Mar 29 09:19:00 2012 (r233654) @@ -6310,7 +6310,7 @@ softdep_journal_freeblocks(ip, cred, len DIP_SET(ip, i_size, length); ip->i_flag |= IN_CHANGE | IN_UPDATE; allocbuf(bp, frags); - ffs_update(vp, MNT_NOWAIT); + ffs_update(vp, 0); bawrite(bp); } else if (lastoff != 0 && vp->v_type != VDIR) { int size; @@ -12345,7 +12345,7 @@ flush_newblk_dep(vp, mp, lbn) * point at the newdirblk before the dependency * will go away. */ - error = ffs_update(vp, MNT_WAIT); + error = ffs_update(vp, 1); if (error) break; ACQUIRE_LOCK(&lk); @@ -12381,7 +12381,7 @@ restart: */ if (dap->da_state & MKDIR_PARENT) { FREE_LOCK(&lk); - if ((error = ffs_update(pvp, MNT_WAIT)) != 0) + if ((error = ffs_update(pvp, 1)) != 0) break; ACQUIRE_LOCK(&lk); /* @@ -12423,7 +12423,7 @@ restart: * disk. */ if (error == 0 && dap == LIST_FIRST(diraddhdp)) - error = ffs_update(vp, MNT_WAIT); + error = ffs_update(vp, 1); vput(vp); if (error != 0) break; @@ -12480,7 +12480,7 @@ retry: if ((error = ffs_vgetf(mp, inum, LK_EXCLUSIVE, &vp, FFSV_FORCEINSMQ))) break; - error = ffs_update(vp, MNT_WAIT); + error = ffs_update(vp, 1); vput(vp); if (error) break; Modified: stable/9/sys/ufs/ffs/ffs_vnops.c ============================================================================== --- stable/9/sys/ufs/ffs/ffs_vnops.c Thu Mar 29 09:16:10 2012 (r233653) +++ stable/9/sys/ufs/ffs/ffs_vnops.c Thu Mar 29 09:19:00 2012 (r233654) @@ -322,7 +322,7 @@ next: /* Write the inode after sync passes to flush deps. */ if (wait && DOINGSOFTDEP(vp) && (flags & NO_INO_UPDT) == 0) { BO_UNLOCK(bo); - ffs_update(vp, MNT_WAIT); + ffs_update(vp, 1); BO_LOCK(bo); } /* switch between sync/async. */ @@ -337,7 +337,7 @@ next: BO_UNLOCK(bo); error = 0; if ((flags & NO_INO_UPDT) == 0) - error = ffs_update(vp, MNT_WAIT); + error = ffs_update(vp, 1); if (DOINGSUJ(vp)) softdep_journal_fsync(VTOI(vp)); return (error);