Skip to content

Commit

Permalink
zonefs: Fix error message in zonefs_file_dio_append()
Browse files Browse the repository at this point in the history
Since the expected write location in a sequential file is always at the
end of the file (append write), when an invalid write append location is
detected in zonefs_file_dio_append(), print the invalid written location
instead of the expected write location.

Fixes: a608da3 ("zonefs: Detect append writes at invalid locations")
Cc: [email protected]
Signed-off-by: Damien Le Moal <[email protected]>
Reviewed-by: Christoph Hellwig <[email protected]>
Reviewed-by: Johannes Thumshirn <[email protected]>
Reviewed-by: Himanshu Madhani <[email protected]>
  • Loading branch information
Damien Le Moal committed Mar 20, 2023
1 parent d7e673c commit 88b1700
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/zonefs/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,7 @@ static ssize_t zonefs_file_dio_append(struct kiocb *iocb, struct iov_iter *from)
if (bio->bi_iter.bi_sector != wpsector) {
zonefs_warn(inode->i_sb,
"Corrupted write pointer %llu for zone at %llu\n",
wpsector, z->z_sector);
bio->bi_iter.bi_sector, z->z_sector);
ret = -EIO;
}
}
Expand Down

0 comments on commit 88b1700

Please sign in to comment.