From b9a1871b047ef7b2851533fa0b52d9a693d39861 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Mon, 25 Jan 2010 04:50:43 -0500 Subject: [PATCH] --- yaml --- r: 180042 b: refs/heads/master c: ef52c75e4b1603f6e6102967ad90118205168eae h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/debugfs/inode.c | 11 ++--------- trunk/security/inode.c | 11 ++--------- 3 files changed, 5 insertions(+), 19 deletions(-) diff --git a/[refs] b/[refs] index 41840198606e..0c75e32db648 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 5998649f779b7148a8a0c10c46cfa99e27d34dfe +refs/heads/master: ef52c75e4b1603f6e6102967ad90118205168eae diff --git a/trunk/fs/debugfs/inode.c b/trunk/fs/debugfs/inode.c index b486169f42bf..274ac865bae8 100644 --- a/trunk/fs/debugfs/inode.c +++ b/trunk/fs/debugfs/inode.c @@ -160,15 +160,8 @@ static int debugfs_create_by_name(const char *name, mode_t mode, * block. A pointer to that is in the struct vfsmount that we * have around. */ - if (!parent) { - if (debugfs_mount && debugfs_mount->mnt_sb) { - parent = debugfs_mount->mnt_sb->s_root; - } - } - if (!parent) { - pr_debug("debugfs: Ah! can not find a parent!\n"); - return -EFAULT; - } + if (!parent) + parent = debugfs_mount->mnt_sb->s_root; *dentry = NULL; mutex_lock(&parent->d_inode->i_mutex); diff --git a/trunk/security/inode.c b/trunk/security/inode.c index f7496c6a022b..c3a793881d04 100644 --- a/trunk/security/inode.c +++ b/trunk/security/inode.c @@ -156,15 +156,8 @@ static int create_by_name(const char *name, mode_t mode, * block. A pointer to that is in the struct vfsmount that we * have around. */ - if (!parent ) { - if (mount && mount->mnt_sb) { - parent = mount->mnt_sb->s_root; - } - } - if (!parent) { - pr_debug("securityfs: Ah! can not find a parent!\n"); - return -EFAULT; - } + if (!parent) + parent = mount->mnt_sb->s_root; mutex_lock(&parent->d_inode->i_mutex); *dentry = lookup_one_len(name, parent, strlen(name));