kernel/fs/xfs/xfs_bmap_util.c
.. .. @@ -800,9 +800,6 @@ 800 800 quota_flag = XFS_QMOPT_RES_REGBLKS; 801 801 } 802 802 803 - /*804 - * Allocate and setup the transaction.805 - */806 803 error = xfs_trans_alloc(mp, &M_RES(mp)->tr_write, resblks, 807 804 resrtextents, 0, &tp); 808 805 .. .. @@ -830,9 +827,9 @@ 830 827 if (error) 831 828 goto error0; 832 829 833 - /*834 - * Complete the transaction835 - */830 + ip->i_d.di_flags |= XFS_DIFLAG_PREALLOC;831 + xfs_trans_log_inode(tp, ip, XFS_ILOG_CORE);832 +836 833 error = xfs_trans_commit(tp); 837 834 xfs_iunlock(ip, XFS_ILOCK_EXCL); 838 835 if (error)