linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mm: fix task_nommu build regressions
@ 2012-03-05 16:37 Paul Gortmaker
  0 siblings, 0 replies; only message in thread
From: Paul Gortmaker @ 2012-03-05 16:37 UTC (permalink / raw)
  To: siddhesh.poyarekar, akpm; +Cc: linux-next, linux-kernel, Paul Gortmaker

Commit a69b756788619171e65c4d7081e9e3b8fbc4646a (linux-next)

  "procfs: mark thread stack correctly in proc/<pid>/maps"

introduced this failure on ARM's at91x40_defconfig:

In file included from fs/proc/task_nommu.c:3:
include/linux/mm.h: In function 'vm_is_stack_for_task':
include/linux/mm.h:1048: error: implicit declaration of function 'task_stack_page'
fs/proc/task_nommu.c: In function 'nommu_vma_show':
fs/proc/task_nommu.c:178: warning: no return statement in function returning non-void
fs/proc/task_nommu.c: At top level:
fs/proc/task_nommu.c:180: error: expected ')' before '\xa'
fs/proc/task_nommu.c:181: error: expected identifier or '(' before 'return'
fs/proc/task_nommu.c:182: error: expected identifier or '(' before '}' token

There are two reasons for the failure.  1) sched.h is needed for
task_stack_page, which is used by the newly added KSTK_ESP calls.
2) The above commit clearly left off an opening "{" in the line
"if (...) {" that it was altering.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>

diff --git a/fs/proc/task_nommu.c b/fs/proc/task_nommu.c
index bdfff69..239fbd4 100644
--- a/fs/proc/task_nommu.c
+++ b/fs/proc/task_nommu.c
@@ -1,4 +1,5 @@
 
+#include <linux/sched.h>
 #include <linux/mm.h>
 #include <linux/file.h>
 #include <linux/fdtable.h>
@@ -170,7 +171,7 @@ static int nommu_vma_show(struct seq_file *m, struct vm_area_struct *vma,
 		pad_len_spaces(m, len);
 		seq_path(m, &file->f_path, "");
 	} else if (mm) {
-		if (vm_is_stack(priv->task, vma, is_pid))
+		if (vm_is_stack(priv->task, vma, is_pid)) {
 			pad_len_spaces(m, len);
 			seq_puts(m, "[stack]");
 		}
-- 
1.7.9.1

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2012-03-05 16:38 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-05 16:37 [PATCH] mm: fix task_nommu build regressions Paul Gortmaker

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).