]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - fs/proc/task_mmu.c
mm, shmem: add internal shmem resident memory accounting
[mirror_ubuntu-bionic-kernel.git] / fs / proc / task_mmu.c
index 8a03759bda3848c636f8e771cd27c9993b25b505..45eb24145978c661ef8214481c8376be6d13186d 100644 (file)
@@ -83,7 +83,8 @@ unsigned long task_statm(struct mm_struct *mm,
                         unsigned long *shared, unsigned long *text,
                         unsigned long *data, unsigned long *resident)
 {
-       *shared = get_mm_counter(mm, MM_FILEPAGES);
+       *shared = get_mm_counter(mm, MM_FILEPAGES) +
+                       get_mm_counter(mm, MM_SHMEMPAGES);
        *text = (PAGE_ALIGN(mm->end_code) - (mm->start_code & PAGE_MASK))
                                                                >> PAGE_SHIFT;
        *data = mm->total_vm - mm->shared_vm;