diff options
| -rw-r--r-- | fs/binfmt_elf_fdpic.c | 19 |
1 files changed, 7 insertions, 12 deletions
diff --git a/fs/binfmt_elf_fdpic.c b/fs/binfmt_elf_fdpic.c index 0e8367c54624..5b5424cb3391 100644 --- a/fs/binfmt_elf_fdpic.c +++ b/fs/binfmt_elf_fdpic.c | |||
| @@ -1390,20 +1390,15 @@ static void fill_prstatus(struct elf_prstatus *prstatus, | |||
| 1390 | prstatus->pr_pgrp = task_pgrp_vnr(p); | 1390 | prstatus->pr_pgrp = task_pgrp_vnr(p); |
| 1391 | prstatus->pr_sid = task_session_vnr(p); | 1391 | prstatus->pr_sid = task_session_vnr(p); |
| 1392 | if (thread_group_leader(p)) { | 1392 | if (thread_group_leader(p)) { |
| 1393 | struct task_cputime cputime; | ||
| 1394 | |||
| 1393 | /* | 1395 | /* |
| 1394 | * This is the record for the group leader. Add in the | 1396 | * This is the record for the group leader. It shows the |
| 1395 | * cumulative times of previous dead threads. This total | 1397 | * group-wide total, not its individual thread total. |
| 1396 | * won't include the time of each live thread whose state | ||
| 1397 | * is included in the core dump. The final total reported | ||
| 1398 | * to our parent process when it calls wait4 will include | ||
| 1399 | * those sums as well as the little bit more time it takes | ||
| 1400 | * this and each other thread to finish dying after the | ||
| 1401 | * core dump synchronization phase. | ||
| 1402 | */ | 1398 | */ |
| 1403 | cputime_to_timeval(cputime_add(p->utime, p->signal->utime), | 1399 | thread_group_cputime(p, &cputime); |
| 1404 | &prstatus->pr_utime); | 1400 | cputime_to_timeval(cputime.utime, &prstatus->pr_utime); |
| 1405 | cputime_to_timeval(cputime_add(p->stime, p->signal->stime), | 1401 | cputime_to_timeval(cputime.stime, &prstatus->pr_stime); |
| 1406 | &prstatus->pr_stime); | ||
| 1407 | } else { | 1402 | } else { |
| 1408 | cputime_to_timeval(p->utime, &prstatus->pr_utime); | 1403 | cputime_to_timeval(p->utime, &prstatus->pr_utime); |
| 1409 | cputime_to_timeval(p->stime, &prstatus->pr_stime); | 1404 | cputime_to_timeval(p->stime, &prstatus->pr_stime); |
