diff options
Diffstat (limited to 'fs/proc/task_mmu.c')
-rw-r--r-- | fs/proc/task_mmu.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c index 994612bc72d0..bccee7cf9ccd 100644 --- a/fs/proc/task_mmu.c +++ b/fs/proc/task_mmu.c | |||
@@ -29,7 +29,7 @@ char *task_mem(struct mm_struct *mm, char *buffer) | |||
29 | "VmPTE:\t%8lu kB\n", | 29 | "VmPTE:\t%8lu kB\n", |
30 | (mm->total_vm - mm->reserved_vm) << (PAGE_SHIFT-10), | 30 | (mm->total_vm - mm->reserved_vm) << (PAGE_SHIFT-10), |
31 | mm->locked_vm << (PAGE_SHIFT-10), | 31 | mm->locked_vm << (PAGE_SHIFT-10), |
32 | get_mm_counter(mm, rss) << (PAGE_SHIFT-10), | 32 | get_mm_rss(mm) << (PAGE_SHIFT-10), |
33 | data << (PAGE_SHIFT-10), | 33 | data << (PAGE_SHIFT-10), |
34 | mm->stack_vm << (PAGE_SHIFT-10), text, lib, | 34 | mm->stack_vm << (PAGE_SHIFT-10), text, lib, |
35 | (PTRS_PER_PTE*sizeof(pte_t)*mm->nr_ptes) >> 10); | 35 | (PTRS_PER_PTE*sizeof(pte_t)*mm->nr_ptes) >> 10); |
@@ -44,13 +44,11 @@ unsigned long task_vsize(struct mm_struct *mm) | |||
44 | int task_statm(struct mm_struct *mm, int *shared, int *text, | 44 | int task_statm(struct mm_struct *mm, int *shared, int *text, |
45 | int *data, int *resident) | 45 | int *data, int *resident) |
46 | { | 46 | { |
47 | int rss = get_mm_counter(mm, rss); | 47 | *shared = get_mm_counter(mm, file_rss); |
48 | |||
49 | *shared = rss - get_mm_counter(mm, anon_rss); | ||
50 | *text = (PAGE_ALIGN(mm->end_code) - (mm->start_code & PAGE_MASK)) | 48 | *text = (PAGE_ALIGN(mm->end_code) - (mm->start_code & PAGE_MASK)) |
51 | >> PAGE_SHIFT; | 49 | >> PAGE_SHIFT; |
52 | *data = mm->total_vm - mm->shared_vm; | 50 | *data = mm->total_vm - mm->shared_vm; |
53 | *resident = rss; | 51 | *resident = *shared + get_mm_counter(mm, anon_rss); |
54 | return mm->total_vm; | 52 | return mm->total_vm; |
55 | } | 53 | } |
56 | 54 | ||