Date: Thu, 29 Mar 2012 09:19:00 +0000 (UTC) From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r233654 - stable/9/sys/ufs/ffs Message-ID: <201203290919.q2T9J0hZ085117@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
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);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201203290919.q2T9J0hZ085117>