From: Alex Shi Date: Tue, 20 Sep 2016 07:18:54 +0000 (+0800) Subject: Merge branch 'linux-linaro-lsk-v4.4' into linux-linaro-lsk-v4.4-android X-Git-Tag: firefly_0821_release~176^2~179 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=5f87c475f82a75e10bc6e249b7471349f1ef1636;p=firefly-linux-kernel-4.4.55.git Merge branch 'linux-linaro-lsk-v4.4' into linux-linaro-lsk-v4.4-android Conflicts: in fs/proc/task_mmu.c: looks like vma_get_anon_name() want have a name for anonymous vma when there is no name used in vma. commit: 586278d78bf The name show is after any other names, so it maybe covered. but anyway, it just a show here. --- 5f87c475f82a75e10bc6e249b7471349f1ef1636 diff --cc Documentation/filesystems/proc.txt index 1c425191574c,6716413c17ba..fea4777a5695 --- a/Documentation/filesystems/proc.txt +++ b/Documentation/filesystems/proc.txt @@@ -379,11 -378,8 +379,10 @@@ is not associated with a file [heap] = the heap of the program [stack] = the stack of the main process - [stack:1001] = the stack of the thread with tid 1001 [vdso] = the "virtual dynamic shared object", the kernel system call handler + [anon:] = an anonymous mapping that has been + named by userspace or if empty, the mapping is anonymous. diff --cc fs/proc/task_mmu.c index 3e97da37b67c,d598b9c809c1..200e3b29aa22 --- a/fs/proc/task_mmu.c +++ b/fs/proc/task_mmu.c @@@ -387,27 -341,8 +391,14 @@@ show_map_vma(struct seq_file *m, struc goto done; } - tid = pid_of_stack(priv, vma, is_pid); - if (tid != 0) { - /* - * Thread stack in /proc/PID/task/TID/maps or - * the main process stack. - */ - if (!is_pid || (vma->vm_start <= mm->start_stack && - vma->vm_end >= mm->start_stack)) { - name = "[stack]"; - } else { - /* Thread stack in /proc/PID/maps */ - seq_pad(m, ' '); - seq_printf(m, "[stack:%d]", tid); - } - if (is_stack(priv, vma, is_pid)) ++ if (is_stack(priv, vma, is_pid)) { + name = "[stack]"; + goto done; + } - + if (vma_get_anon_name(vma)) { + seq_pad(m, ' '); + seq_print_vma_name(m, vma); + } } done: