diff options
| author | Oleg Nesterov <[email protected]> | 2014-01-23 15:55:53 -0800 | 
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2014-01-23 16:37:02 -0800 | 
| commit | 185ee40ee7fd1ecfc6575e8cefa2331218d1eca2 (patch) | |
| tree | 093d2616894ebc7e31970b3040615f0e0dd8d283 /fs/proc/array.c | |
| parent | 98611e4e6a2b4a03fd2d4750cce8e4455a995c8d (diff) | |
fs/proc/array.c: change do_task_stat() to use while_each_thread()
Change the remaining next_thread (ab)users to use while_each_thread().
The last user which should be changed is next_tid(), but we can't do this
now.
__exit_signal() and complete_signal() are fine, they actually need
next_thread() logic.
This patch (of 3):
do_task_stat() can use while_each_thread(), no changes in
the compiled code.
Signed-off-by: Oleg Nesterov <[email protected]>
Cc: KOSAKI Motohiro <[email protected]>
Cc: Al Viro <[email protected]>
Cc: Kees Cook <[email protected]>
Reviewed-by: Sameer Nanda <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'fs/proc/array.c')
| -rw-r--r-- | fs/proc/array.c | 3 | 
1 files changed, 1 insertions, 2 deletions
| diff --git a/fs/proc/array.c b/fs/proc/array.c index 554a0b229ac2..656e401794de 100644 --- a/fs/proc/array.c +++ b/fs/proc/array.c @@ -444,8 +444,7 @@ static int do_task_stat(struct seq_file *m, struct pid_namespace *ns,  				min_flt += t->min_flt;  				maj_flt += t->maj_flt;  				gtime += task_gtime(t); -				t = next_thread(t); -			} while (t != task); +			} while_each_thread(task, t);  			min_flt += sig->min_flt;  			maj_flt += sig->maj_flt; |