public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mm: fix potential build error in compaction.h
@ 2019-02-08  8:04 Yu Zhao
  2019-02-12 12:03 ` Michal Hocko
  0 siblings, 1 reply; 4+ messages in thread
From: Yu Zhao @ 2019-02-08  8:04 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux-kernel, Yu Zhao

Declaration of struct node is required regardless. On UMA system,
including compaction.h without proceeding node.h shouldn't cause
build error.

Signed-off-by: Yu Zhao <yuzhao@google.com>
---
 include/linux/compaction.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/compaction.h b/include/linux/compaction.h
index 68250a57aace..be165b220996 100644
--- a/include/linux/compaction.h
+++ b/include/linux/compaction.h
@@ -220,22 +220,22 @@ static inline int kcompactd_run(int nid)
 static inline void kcompactd_stop(int nid)
 {
 }
 
 static inline void wakeup_kcompactd(pg_data_t *pgdat, int order, int classzone_idx)
 {
 }
 
 #endif /* CONFIG_COMPACTION */
 
-#if defined(CONFIG_COMPACTION) && defined(CONFIG_SYSFS) && defined(CONFIG_NUMA)
 struct node;
+#if defined(CONFIG_COMPACTION) && defined(CONFIG_SYSFS) && defined(CONFIG_NUMA)
 extern int compaction_register_node(struct node *node);
 extern void compaction_unregister_node(struct node *node);
 
 #else
 
 static inline int compaction_register_node(struct node *node)
 {
 	return 0;
 }
 
-- 
2.20.1.791.gb4d0f1c61a-goog


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-02-13 13:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-08  8:04 [PATCH] mm: fix potential build error in compaction.h Yu Zhao
2019-02-12 12:03 ` Michal Hocko
2019-02-12 23:38   ` Yu Zhao
2019-02-13 13:00     ` Michal Hocko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox