diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2012-06-22 04:39:14 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-07-14 08:33:35 -0400 |
commit | d95852777bc8ba6b3ad3397d495c5f9dd8ca8383 (patch) | |
tree | 96e9d8b1d33c4f6f7b5ba5be0fa4fd8f77c7a67f /Documentation/filesystems/vfs.txt | |
parent | 3d8a00d2099ebc6d5a6e95fadaf861709d9919a8 (diff) |
make ->atomic_open() return int
Change of calling conventions:
old new
NULL 1
file 0
ERR_PTR(-ve) -ve
Caller *knows* that struct file *; no need to return it.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'Documentation/filesystems/vfs.txt')
-rw-r--r-- | Documentation/filesystems/vfs.txt | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Documentation/filesystems/vfs.txt b/Documentation/filesystems/vfs.txt index d7121051afc..d0d690bbc4c 100644 --- a/Documentation/filesystems/vfs.txt +++ b/Documentation/filesystems/vfs.txt | |||
@@ -364,7 +364,7 @@ struct inode_operations { | |||
364 | ssize_t (*listxattr) (struct dentry *, char *, size_t); | 364 | ssize_t (*listxattr) (struct dentry *, char *, size_t); |
365 | int (*removexattr) (struct dentry *, const char *); | 365 | int (*removexattr) (struct dentry *, const char *); |
366 | void (*update_time)(struct inode *, struct timespec *, int); | 366 | void (*update_time)(struct inode *, struct timespec *, int); |
367 | struct file * (*atomic_open)(struct inode *, struct dentry *, | 367 | int (*atomic_open)(struct inode *, struct dentry *, |
368 | struct opendata *, unsigned open_flag, | 368 | struct opendata *, unsigned open_flag, |
369 | umode_t create_mode, int *opened); | 369 | umode_t create_mode, int *opened); |
370 | }; | 370 | }; |
@@ -482,8 +482,8 @@ otherwise noted. | |||
482 | atomic_open: called on the last component of an open. Using this optional | 482 | atomic_open: called on the last component of an open. Using this optional |
483 | method the filesystem can look up, possibly create and open the file in | 483 | method the filesystem can look up, possibly create and open the file in |
484 | one atomic operation. If it cannot perform this (e.g. the file type | 484 | one atomic operation. If it cannot perform this (e.g. the file type |
485 | turned out to be wrong) it may signal this by returning NULL instead of | 485 | turned out to be wrong) it may signal this by returning 1 instead of |
486 | an open struct file pointer. This method is only called if the last | 486 | usual 0 or -ve . This method is only called if the last |
487 | component is negative or needs lookup. Cached positive dentries are | 487 | component is negative or needs lookup. Cached positive dentries are |
488 | still handled by f_op->open(). | 488 | still handled by f_op->open(). |
489 | 489 | ||