diff options
author | Raphael S.Carvalho <raphael.scarv@gmail.com> | 2013-02-27 13:32:09 -0500 |
---|---|---|
committer | Eric W. Biederman <ebiederm@xmission.com> | 2013-08-26 20:45:56 -0400 |
commit | 21e851943e31022731cd5fad386ca8fb552dbe64 (patch) | |
tree | 53509f2b4aa5ec07fb89d616880b0d78b1555242 /kernel | |
parent | aee1c13dd0f6c2fc56e0e492b349ee8ac655880f (diff) |
kernel/nsproxy.c: Improving a snippet of code.
It seems GCC generates a better code in that way, so I changed that statement.
Btw, they have the same semantic, so I'm sending this patch due to performance issues.
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com>
Signed-off-by: Raphael S.Carvalho <raphael.scarv@gmail.com>
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/nsproxy.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/nsproxy.c b/kernel/nsproxy.c index 364ceab15f0c..d9afd256318f 100644 --- a/kernel/nsproxy.c +++ b/kernel/nsproxy.c | |||
@@ -148,7 +148,8 @@ int copy_namespaces(unsigned long flags, struct task_struct *tsk) | |||
148 | * means share undolist with parent, so we must forbid using | 148 | * means share undolist with parent, so we must forbid using |
149 | * it along with CLONE_NEWIPC. | 149 | * it along with CLONE_NEWIPC. |
150 | */ | 150 | */ |
151 | if ((flags & CLONE_NEWIPC) && (flags & CLONE_SYSVSEM)) { | 151 | if ((flags & (CLONE_NEWIPC | CLONE_SYSVSEM)) == |
152 | (CLONE_NEWIPC | CLONE_SYSVSEM)) { | ||
152 | err = -EINVAL; | 153 | err = -EINVAL; |
153 | goto out; | 154 | goto out; |
154 | } | 155 | } |