Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b5303be2 authored by Matthew Wilcox's avatar Matthew Wilcox Committed by Dominique Martinet
Browse files

9p: Change p9_fid_create calling convention

Return NULL instead of ERR_PTR when we can't allocate a FID.  The ENOSPC
return value was getting all the way back to userspace, and that's
confusing for a userspace program which isn't expecting read() to tell it
there's no space left on the filesystem.  The best error we can return to
indicate a temporary failure caused by lack of client resources is ENOMEM.

Maybe it would be better to sleep until a FID is available, but that's
not a change I'm comfortable making.

Link: http://lkml.kernel.org/r/20180711210225.19730-3-willy@infradead.org


Signed-off-by: default avatarMatthew Wilcox <willy@infradead.org>
Reviewed-by: default avatarJun Piao <piaojun@huawei.com>
Reviewed-by: default avatarGreg Kurz <groug@kaod.org>
Reviewed-by: default avatarYiwen Jiang <jiangyiwen@huwei.com>
Cc: Eric Van Hensbergen <ericvh@gmail.com>
Cc: Ron Minnich <rminnich@sandia.gov>
Cc: Latchesar Ionkov <lucho@ionkov.net>
Signed-off-by: default avatarDominique Martinet <dominique.martinet@cea.fr>
parent 2d58f63f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment