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:
ef2b02d
)
kernel/user.c: Use list_for_each_entry instead of list_for_each
author
Matthias Kaehlcke
<
[email protected]
>
Wed, 19 Sep 2007 05:46:43 +0000
(22:46 -0700)
committer
Linus Torvalds
<
[email protected]
>
Wed, 19 Sep 2007 18:24:18 +0000
(11:24 -0700)
kernel/user.c: Convert list_for_each to list_for_each_entry in
uid_hash_find()
Signed-off-by: Matthias Kaehlcke <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
kernel/user.c
patch
|
blob
|
history
diff --git
a/kernel/user.c
b/kernel/user.c
index e7d11cef6998fdb378506d72232c4041738dce2f..e080ba863ae33167ebaf8aecd0b9588a2a9b6acf 100644
(file)
--- a/
kernel/user.c
+++ b/
kernel/user.c
@@
-67,13
+67,9
@@
static inline void uid_hash_remove(struct user_struct *up)
static inline struct user_struct *uid_hash_find(uid_t uid, struct list_head *hashent)
{
- struct list_head *up;
-
- list_for_each(up, hashent) {
- struct user_struct *user;
-
- user = list_entry(up, struct user_struct, uidhash_list);
+ struct user_struct *user;
+ list_for_each_entry(user, hashent, uidhash_list) {
if(user->uid == uid) {
atomic_inc(&user->__count);
return user;