mirror of
https://github.com/torvalds/linux.git
synced 2026-11-06 21:58:01 +01:00
fuse: return -E2BIG for an oversized SETXATTR over io-uring
fuse_dev_do_read() returns -E2BIG when a SETXATTR does not fit the server's buffer, since the value may legitimately be that large. The io-uring transport fails the copy with -EIO instead. Map it so both transports agree. Assisted-by: Claude:claude-opus-4-8 Reviewed-by: Joanne Koong <joannelkoong@gmail.com> Signed-off-by: Xiang Mei <xmei5@asu.edu> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
This commit is contained in:
parent
c1338aae7b
commit
ab38882862
|
|
@ -893,6 +893,12 @@ static int fuse_uring_args_to_ring(struct fuse_req *req,
|
|||
fuse_copy_finish(&cs);
|
||||
if (err) {
|
||||
pr_info_ratelimited("%s fuse_copy_args failed\n", __func__);
|
||||
/*
|
||||
* fuse-uring does not use pipe buffers, so -EIO here can only
|
||||
* mean the in-args did not fit ent->payload
|
||||
*/
|
||||
if (err == -EIO && args->opcode == FUSE_SETXATTR)
|
||||
err = -E2BIG;
|
||||
return err;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user