aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mempolicy.h
diff options
context:
space:
mode:
authorStephen Wilson <wilsons@start.ca>2011-05-24 20:12:46 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-05-25 11:39:34 -0400
commit13057efb0a0063eb8042d99093ec88a52c4f1593 (patch)
treeeceba328fb1401c8a5bf2a863916a0c8cd0c69cb /include/linux/mempolicy.h
parent9840e37239183a947a15d617c67e418c6e505dd8 (diff)
mm: declare mpol_to_str() when CONFIG_TMPFS=n
When CONFIG_TMPFS=n mpol_to_str() is not declared in mempolicy.h. However, in the NUMA case, the definition is always compiled. Since it is not strictly true that tmpfs is the only client, and since the symbol was always lurking around anyways, export mpol_to_str() unconditionally. Furthermore, this will allow us to move show_numa_map() out of mempolicy.c and into the procfs subsystem. Signed-off-by: Stephen Wilson <wilsons@start.ca> Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Cc: Hugh Dickins <hughd@google.com> Cc: David Rientjes <rientjes@google.com> Cc: Lee Schermerhorn <lee.schermerhorn@hp.com> Cc: Alexey Dobriyan <adobriyan@gmail.com> Cc: Christoph Lameter <cl@linux-foundation.org> Cc: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/mempolicy.h')
-rw-r--r--include/linux/mempolicy.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/mempolicy.h b/include/linux/mempolicy.h
index c2f603218fbc..7978eec1b7d9 100644
--- a/include/linux/mempolicy.h
+++ b/include/linux/mempolicy.h
@@ -231,10 +231,10 @@ int do_migrate_pages(struct mm_struct *mm,
231 231
232#ifdef CONFIG_TMPFS 232#ifdef CONFIG_TMPFS
233extern int mpol_parse_str(char *str, struct mempolicy **mpol, int no_context); 233extern int mpol_parse_str(char *str, struct mempolicy **mpol, int no_context);
234#endif
234 235
235extern int mpol_to_str(char *buffer, int maxlen, struct mempolicy *pol, 236extern int mpol_to_str(char *buffer, int maxlen, struct mempolicy *pol,
236 int no_context); 237 int no_context);
237#endif
238 238
239/* Check if a vma is migratable */ 239/* Check if a vma is migratable */
240static inline int vma_migratable(struct vm_area_struct *vma) 240static inline int vma_migratable(struct vm_area_struct *vma)
@@ -371,13 +371,13 @@ static inline int mpol_parse_str(char *str, struct mempolicy **mpol,
371{ 371{
372 return 1; /* error */ 372 return 1; /* error */
373} 373}
374#endif
374 375
375static inline int mpol_to_str(char *buffer, int maxlen, struct mempolicy *pol, 376static inline int mpol_to_str(char *buffer, int maxlen, struct mempolicy *pol,
376 int no_context) 377 int no_context)
377{ 378{
378 return 0; 379 return 0;
379} 380}
380#endif
381 381
382#endif /* CONFIG_NUMA */ 382#endif /* CONFIG_NUMA */
383#endif /* __KERNEL__ */ 383#endif /* __KERNEL__ */