diff options
author | Christoph Hellwig <hch@lst.de> | 2008-02-08 13:20:26 +0100 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-08 18:22:34 +0100 |
commit | 8b88b0998e35d239e74446cc30f354bdab86df89 (patch) | |
tree | c13773b744cf12b1e30ec9336a4acaf21e46c6d9 /include | |
parent | Nuke duplicate header from sysctl.c (diff) | |
download | linux-8b88b0998e35d239e74446cc30f354bdab86df89.tar.xz linux-8b88b0998e35d239e74446cc30f354bdab86df89.zip |
libfs: allow error return from simple attributes
Sometimes simple attributes might need to return an error, e.g. for
acquiring a mutex interruptibly. In fact we have that situation in
spufs already which is the original user of the simple attributes. This
patch merged the temporarily forked attributes in spufs back into the
main ones and allows to return errors.
[akpm@linux-foundation.org: build fix]
Signed-off-by: Christoph Hellwig <hch@lst.de>
Cc: <stefano.brivio@polimi.it>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Greg KH <greg@kroah.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/fs.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h index 36b7abefacbe..ebe996ac2589 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h @@ -2068,7 +2068,7 @@ __simple_attr_check_format(const char *fmt, ...) } int simple_attr_open(struct inode *inode, struct file *file, - u64 (*get)(void *), void (*set)(void *, u64), + int (*get)(void *, u64 *), int (*set)(void *, u64), const char *fmt); int simple_attr_close(struct inode *inode, struct file *file); ssize_t simple_attr_read(struct file *file, char __user *buf, |