diff options
author | David S. Miller <davem@davemloft.net> | 2010-02-17 01:09:29 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-17 01:09:29 -0500 |
commit | 2bb4646fce8d09916b351d1a62f98db7cec6fc41 (patch) | |
tree | c1f0d002e69868606eca9d1b919835f422892063 /security/inode.c | |
parent | 6836b9bdd98e3b500cd49512484df68f46e14659 (diff) | |
parent | b0483e78e5c4c9871fc5541875b3bc006846d46b (diff) |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Diffstat (limited to 'security/inode.c')
-rw-r--r-- | security/inode.c | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/security/inode.c b/security/inode.c index f7496c6a022b..c3a793881d04 100644 --- a/security/inode.c +++ b/security/inode.c | |||
@@ -156,15 +156,8 @@ static int create_by_name(const char *name, mode_t mode, | |||
156 | * block. A pointer to that is in the struct vfsmount that we | 156 | * block. A pointer to that is in the struct vfsmount that we |
157 | * have around. | 157 | * have around. |
158 | */ | 158 | */ |
159 | if (!parent ) { | 159 | if (!parent) |
160 | if (mount && mount->mnt_sb) { | 160 | parent = mount->mnt_sb->s_root; |
161 | parent = mount->mnt_sb->s_root; | ||
162 | } | ||
163 | } | ||
164 | if (!parent) { | ||
165 | pr_debug("securityfs: Ah! can not find a parent!\n"); | ||
166 | return -EFAULT; | ||
167 | } | ||
168 | 161 | ||
169 | mutex_lock(&parent->d_inode->i_mutex); | 162 | mutex_lock(&parent->d_inode->i_mutex); |
170 | *dentry = lookup_one_len(name, parent, strlen(name)); | 163 | *dentry = lookup_one_len(name, parent, strlen(name)); |