aboutsummaryrefslogtreecommitdiffstats
path: root/fs/affs
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2016-07-29 18:22:49 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2016-07-29 18:22:49 -0400
commite0b3f595d13b3e9ce9cdf53935e7f304c04b5b2b (patch)
tree5146778c032b7b73b7adeae3cf4743d16c5216e8 /fs/affs
parent15d3c589f6305c50a705572dbb33620c5cba416c (diff)
affs ->d_compare(): don't bother with ->d_inode
Use ->d_sb directly. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/affs')
-rw-r--r--fs/affs/amigaffs.c4
-rw-r--r--fs/affs/namei.c4
2 files changed, 3 insertions, 5 deletions
diff --git a/fs/affs/amigaffs.c b/fs/affs/amigaffs.c
index d6c7a51c93e4..d8f217c711d3 100644
--- a/fs/affs/amigaffs.c
+++ b/fs/affs/amigaffs.c
@@ -472,9 +472,7 @@ affs_warning(struct super_block *sb, const char *function, const char *fmt, ...)
472bool 472bool
473affs_nofilenametruncate(const struct dentry *dentry) 473affs_nofilenametruncate(const struct dentry *dentry)
474{ 474{
475 struct inode *inode = d_inode(dentry); 475 return affs_test_opt(AFFS_SB(dentry->d_sb)->s_flags, SF_NO_TRUNCATE);
476
477 return affs_test_opt(AFFS_SB(inode->i_sb)->s_flags, SF_NO_TRUNCATE);
478} 476}
479 477
480/* Check if the name is valid for a affs object. */ 478/* Check if the name is valid for a affs object. */
diff --git a/fs/affs/namei.c b/fs/affs/namei.c
index eb32029bc776..27ca732680d9 100644
--- a/fs/affs/namei.c
+++ b/fs/affs/namei.c
@@ -136,7 +136,7 @@ affs_compare_dentry(const struct dentry *parent, const struct dentry *dentry,
136{ 136{
137 137
138 return __affs_compare_dentry(len, str, name, affs_toupper, 138 return __affs_compare_dentry(len, str, name, affs_toupper,
139 affs_nofilenametruncate(parent)); 139 affs_nofilenametruncate(dentry));
140} 140}
141 141
142static int 142static int
@@ -144,7 +144,7 @@ affs_intl_compare_dentry(const struct dentry *parent, const struct dentry *dentr
144 unsigned int len, const char *str, const struct qstr *name) 144 unsigned int len, const char *str, const struct qstr *name)
145{ 145{
146 return __affs_compare_dentry(len, str, name, affs_intl_toupper, 146 return __affs_compare_dentry(len, str, name, affs_intl_toupper,
147 affs_nofilenametruncate(parent)); 147 affs_nofilenametruncate(dentry));
148 148
149} 149}
150 150