hc
2024-05-11 297b60346df8beafee954a0fd7c2d64f33f3b9bc
kernel/fs/xfs/xfs_pnfs.c
....@@ -164,10 +164,12 @@
164164 * that the blocks allocated and handed out to the client are
165165 * guaranteed to be present even after a server crash.
166166 */
167
- error = xfs_update_prealloc_flags(ip,
168
- XFS_PREALLOC_SET | XFS_PREALLOC_SYNC);
167
+ error = xfs_update_prealloc_flags(ip, XFS_PREALLOC_SET);
168
+ if (!error)
169
+ error = xfs_log_force_inode(ip);
169170 if (error)
170171 goto out_unlock;
172
+
171173 } else {
172174 xfs_iunlock(ip, lock_flags);
173175 }
....@@ -283,7 +285,8 @@
283285 xfs_trans_ijoin(tp, ip, XFS_ILOCK_EXCL);
284286 xfs_trans_log_inode(tp, ip, XFS_ILOG_CORE);
285287
286
- xfs_setattr_time(ip, iattr);
288
+ ASSERT(!(iattr->ia_valid & (ATTR_UID | ATTR_GID)));
289
+ setattr_copy(inode, iattr);
287290 if (update_isize) {
288291 i_size_write(inode, iattr->ia_size);
289292 ip->i_d.di_size = iattr->ia_size;