diff options
Diffstat (limited to 'fs/proc/array.c')
| -rw-r--r-- | fs/proc/array.c | 13 | 
1 files changed, 5 insertions, 8 deletions
| diff --git a/fs/proc/array.c b/fs/proc/array.c index 49be8c8ef555..ff869a66b34e 100644 --- a/fs/proc/array.c +++ b/fs/proc/array.c @@ -408,9 +408,9 @@ static void task_cpus_allowed(struct seq_file *m, struct task_struct *task)  		   cpumask_pr_args(&task->cpus_mask));  } -static inline void task_core_dumping(struct seq_file *m, struct mm_struct *mm) +static inline void task_core_dumping(struct seq_file *m, struct task_struct *task)  { -	seq_put_decimal_ull(m, "CoreDumping:\t", !!mm->core_state); +	seq_put_decimal_ull(m, "CoreDumping:\t", !!task->signal->core_state);  	seq_putc(m, '\n');  } @@ -436,7 +436,7 @@ int proc_pid_status(struct seq_file *m, struct pid_namespace *ns,  	if (mm) {  		task_mem(m, mm); -		task_core_dumping(m, mm); +		task_core_dumping(m, task);  		task_thp_status(m, mm);  		mmput(mm);  	} @@ -541,7 +541,7 @@ static int do_task_stat(struct seq_file *m, struct pid_namespace *ns,  	}  	if (permitted && (!whole || num_threads < 2)) -		wchan = get_wchan(task); +		wchan = !task_is_running(task);  	if (!whole) {  		min_flt = task->min_flt;  		maj_flt = task->maj_flt; @@ -606,10 +606,7 @@ static int do_task_stat(struct seq_file *m, struct pid_namespace *ns,  	 *  	 * This works with older implementations of procps as well.  	 */ -	if (wchan) -		seq_puts(m, " 1"); -	else -		seq_puts(m, " 0"); +	seq_put_decimal_ull(m, " ", wchan);  	seq_put_decimal_ull(m, " ", 0);  	seq_put_decimal_ull(m, " ", 0); |