diff options
| author | 2026-09-28 11:54:27 -0400 | |
|---|---|---|
| committer | 2026-10-05 12:55:00 -0400 | |
| commit | 077d39c1ac8c9b2e2fad8e66a2ba6250ced1a860 (patch) | |
| tree | 75175930b700a09a5f0167ee22675ee9f9b2d139 /scripts/Makefile.thinlto | |
| parent | NFS/localio: detect a short read or write before the iterator has moved (diff) | |
NFS/localio: report the stability a DIO WRITE actually has
Since commit d32ddfeb5593 ("nfs/localio: Ensure DIO WRITE's IO on
stable storage upon completion") a DIO WRITE issued through LOCALIO
is persisted before it completes: nfs_local_iters_init() sets
IOCB_DSYNC|IOCB_SYNC on it despite whatever the caller asked for, so
that the buffered head and tail and the O_DIRECT middle of a
misaligned write cannot complete out of order. The reply still
reported the stability that was asked for, so an UNSTABLE write came
back UNSTABLE, the client kept its pages on the commit list, and the
COMMIT that followed ran an fsync for data that is already on stable
storage.
Report the stability the kiocb actually carries instead: FILE_SYNC
when IOCB_SYNC is set, DATA_SYNC when only IOCB_DSYNC is. A write
told FILE_SYNC has no reason to COMMIT and sends none. Buffered
writes, and any write that asked for at least what it got, are
unchanged.
Fixes: d32ddfeb5593 ("nfs/localio: Ensure DIO WRITE's IO on stable storage upon completion")
Cc: stable@vger.kernel.org
Assisted-by: Claude:claude-fable-5-1
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
Signed-off-by: Anna Schumaker <anna.schumaker@hammerspace.com>
Diffstat (limited to 'scripts/Makefile.thinlto')
0 files changed, 0 insertions, 0 deletions
