diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1997-12-06 23:51:34 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 1997-12-06 23:51:34 +0000 |
commit | 230e5ab6a084ed50470f101934782dbf54b0d06b (patch) | |
tree | 5dd821c8d33f450470588e7a543f74bf74306e9e /fs/bad_inode.c | |
parent | c9b1c8a64c6444d189856f1e26bdcb8b4cd0113a (diff) |
Merge with Linux 2.1.67.
Diffstat (limited to 'fs/bad_inode.c')
-rw-r--r-- | fs/bad_inode.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/fs/bad_inode.c b/fs/bad_inode.c index 562a5d8b7..4d17002ab 100644 --- a/fs/bad_inode.c +++ b/fs/bad_inode.c @@ -19,7 +19,7 @@ static struct dentry * bad_follow_link(struct inode * ino, struct dentry *base) return ERR_PTR(-EIO); } -static int return_EIO() +static int return_EIO(void) { return -EIO; } @@ -81,3 +81,12 @@ void make_bad_inode(struct inode * inode) inode->i_op = &bad_inode_ops; } +/* + * This tests whether an inode has been flagged as bad. The test uses + * &bad_inode_ops to cover the case of invalidated inodes as well as + * those created by make_bad_inode() above. + */ +int is_bad_inode(struct inode * inode) +{ + return (inode->i_op == &bad_inode_ops); +} |