summaryrefslogtreecommitdiffstats
path: root/fs/ncpfs/dir.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2014-10-21 15:20:42 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2014-10-31 17:48:54 -0400
commita7400222e3eb7d5ce3820d2234905bbeafabd171 (patch)
treef630c4138ceb3889e08c5cd0029d2f07ec47dd0a /fs/ncpfs/dir.c
parentac7576f4b1da8c9c6bc1ae026c2b9e86ae617ba5 (diff)
downloadblackbird-op-linux-a7400222e3eb7d5ce3820d2234905bbeafabd171.tar.gz
blackbird-op-linux-a7400222e3eb7d5ce3820d2234905bbeafabd171.zip
new helper: is_root_inode()
replace open-coded instances Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/ncpfs/dir.c')
-rw-r--r--fs/ncpfs/dir.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/ncpfs/dir.c b/fs/ncpfs/dir.c
index 7cb751dfbeef..461f6be5df20 100644
--- a/fs/ncpfs/dir.c
+++ b/fs/ncpfs/dir.c
@@ -198,8 +198,8 @@ ncp_single_volume(struct ncp_server *server)
static inline int ncp_is_server_root(struct inode *inode)
{
- return (!ncp_single_volume(NCP_SERVER(inode)) &&
- inode == inode->i_sb->s_root->d_inode);
+ return !ncp_single_volume(NCP_SERVER(inode)) &&
+ is_root_inode(inode);
}
OpenPOWER on IntegriCloud