projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5089a97
)
keyctl_session_to_parent(): use thread_group_empty() to check singlethreadness
author
Oleg Nesterov
<
[email protected]
>
Wed, 26 May 2010 21:43:23 +0000
(14:43 -0700)
committer
Linus Torvalds
<
[email protected]
>
Thu, 27 May 2010 16:12:47 +0000
(09:12 -0700)
No functional changes.
keyctl_session_to_parent() is the only user of signal->count which needs
the correct value. Change it to use thread_group_empty() instead, this
must be strictly equivalent under tasklist, and imho looks better.
Signed-off-by: Oleg Nesterov <
[email protected]
>
Acked-by: David Howells <
[email protected]
>
Cc: Peter Zijlstra <
[email protected]
>
Acked-by: Roland McGrath <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
security/keys/keyctl.c
patch
|
blob
|
history
diff --git
a/security/keys/keyctl.c
b/security/keys/keyctl.c
index 8f4dce1987c492c59a9e2a6870b1bebaeaac09a8..13074b4547433ab20929fa493114b507c9e4389f 100644
(file)
--- a/
security/keys/keyctl.c
+++ b/
security/keys/keyctl.c
@@
-1269,7
+1269,7
@@
long keyctl_session_to_parent(void)
goto not_permitted;
/* the parent must be single threaded */
- if (
atomic_read(&parent->signal->count) != 1
)
+ if (
!thread_group_empty(parent)
)
goto not_permitted;
/* the parent and the child must have different session keyrings or