diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2018-07-09 19:17:52 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2018-07-12 10:04:21 -0400 |
commit | 64e1ac4d46f9f5d8284aefb97e1b550dbb26abe8 (patch) | |
tree | 86fa0a3f2b68d2c39d94faca05bef2b6255fbc61 /fs/open.c | |
parent | 3ec2eef116e900099edc6d31a1a0423166e2906d (diff) | |
download | lwn-64e1ac4d46f9f5d8284aefb97e1b550dbb26abe8.tar.gz lwn-64e1ac4d46f9f5d8284aefb97e1b550dbb26abe8.zip |
->atomic_open(): return 0 in all success cases
FMODE_OPENED can be used to distingusish "successful open" from the
"called finish_no_open(), do it yourself" cases. Since finish_no_open()
has been adjusted, no changes in the instances were actually needed.
The caller has been adjusted.
Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/open.c')
-rw-r--r-- | fs/open.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/open.c b/fs/open.c index dbaac9efc7fc..d98e19239bb7 100644 --- a/fs/open.c +++ b/fs/open.c @@ -863,13 +863,13 @@ EXPORT_SYMBOL(finish_open); * NB: unlike finish_open() this function does consume the dentry reference and * the caller need not dput() it. * - * Returns "1" which must be the return value of ->atomic_open() after having + * Returns "0" which must be the return value of ->atomic_open() after having * called this function. */ int finish_no_open(struct file *file, struct dentry *dentry) { file->f_path.dentry = dentry; - return 1; + return 0; } EXPORT_SYMBOL(finish_no_open); |