Skip to content

Commit

Permalink
devcgroup: use list_for_each_entry_rcu()
Browse files Browse the repository at this point in the history
We should use list_for_each_entry_rcu in RCU read site.

Signed-off-by: Lai Jiangshan <[email protected]>
Cc: Paul Menage <[email protected]>
Cc: KAMEZAWA Hiroyuki <[email protected]>
Cc: Pavel Emelyanov <[email protected]>
Cc: Balbir Singh <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Lai Jiangshan authored and torvalds committed Jan 8, 2009
1 parent a47295e commit 116e057
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion security/device_cgroup.c
Original file line number Diff line number Diff line change
Expand Up @@ -517,7 +517,7 @@ int devcgroup_inode_mknod(int mode, dev_t dev)

dev_cgroup = task_devcgroup(current);

list_for_each_entry(wh, &dev_cgroup->whitelist, list) {
list_for_each_entry_rcu(wh, &dev_cgroup->whitelist, list) {
if (wh->type & DEV_ALL)
goto acc_check;
if ((wh->type & DEV_BLOCK) && !S_ISBLK(mode))
Expand Down

0 comments on commit 116e057

Please sign in to comment.