Revert r367669 to re-commit with proper message

This commit is contained in:
Konstantin Belousov 2020-11-14 05:19:44 +00:00
parent c0d2077f41
commit 7b795aa3c0
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=367670

View File

@ -67,17 +67,6 @@ __FBSDID("$FreeBSD$");
static int ffs_indirtrunc(struct inode *, ufs2_daddr_t, ufs2_daddr_t,
ufs2_daddr_t, int, ufs2_daddr_t *);
static void
ffs_inode_bwrite(struct vnode *vp, struct buf *bp, int flags)
{
if ((flags & IO_SYNC) != 0)
bwrite(bp);
else if (DOINGASYNC(vp))
bdwrite(bp);
else
bawrite(bp);
}
/*
* Update the access, modified, and inode change times as specified by the
* IN_ACCESS, IN_UPDATE, and IN_CHANGE flags respectively. Write the inode
@ -368,7 +357,12 @@ ffs_truncate(vp, length, flags, cred)
DIP_SET(ip, i_size, length);
if (bp->b_bufsize == fs->fs_bsize)
bp->b_flags |= B_CLUSTEROK;
ffs_inode_bwrite(vp, bp, flags);
if (flags & IO_SYNC)
bwrite(bp);
else if (DOINGASYNC(vp))
bdwrite(bp);
else
bawrite(bp);
UFS_INODE_SET_FLAG(ip, IN_SIZEMOD | IN_CHANGE | IN_UPDATE);
return (ffs_update(vp, waitforupdate));
}
@ -484,7 +478,12 @@ ffs_truncate(vp, length, flags, cred)
allocbuf(bp, size);
if (bp->b_bufsize == fs->fs_bsize)
bp->b_flags |= B_CLUSTEROK;
ffs_inode_bwrite(vp, bp, flags);
if (flags & IO_SYNC)
bwrite(bp);
else if (DOINGASYNC(vp))
bdwrite(bp);
else
bawrite(bp);
UFS_INODE_SET_FLAG(ip, IN_SIZEMOD | IN_CHANGE | IN_UPDATE);
}
/*