History

mm/page_ext: remove pgdat_page_ext_init()

pgdat_page_ext_init() sets pgdat->node_page_ext to NULL only on FLATMEM. FLATMEM depends on !NUMA, so the pgdat is always the zero-initialized contig_page_data and the store has no effect. So remove the call site, the unused function and its declaration. No functional change.

Sang-Heon Jeon committed 3 months ago

Commit 0ddb8bb1 parent 34568003 files · +0 −15Browse files

Unified · Split

3 files
  1. include/linux/page_ext.h +0 −5
  2. mm/mm_init.c +0 −1
  3. mm/page_ext.c +0 −9
include/linux/page_ext.h+0−5
@@ -55,7 +55,6 @@ struct page_ext { · 54 unmodified lines
5555
5656 extern bool early_page_ext;
5757 extern unsigned long page_ext_size;
58−extern void pgdat_page_ext_init(struct pglist_data *pgdat);
5958
6059 static inline bool early_page_ext_enabled(void)
6160 {
@@ -202,10 +201,6 @@ static inline bool early_page_ext_enabled(void) · 140 unmodified lines
202201 return false;
203202 }
204203
205−static inline void pgdat_page_ext_init(struct pglist_data *pgdat)
206−{
207−}
208−
209204 static inline void page_ext_init(void)
210205 {
211206 }
mm/mm_init.c+0−1
@@ -1394,7 +1394,6 @@ static void __meminit pgdat_init_internals(struct pglist_data *pgdat) · 1393 unmodified lines
13941394 for (i = 0; i < NR_VMSCAN_THROTTLE; i++)
13951395 init_waitqueue_head(&pgdat->reclaim_wait[i]);
13961396
1397− pgdat_page_ext_init(pgdat);
13981397 lruvec_init(&pgdat->__lruvec);
13991398 }
14001399
mm/page_ext.c+0−9
@@ -164,11 +164,6 @@ void __init page_ext_init_flatmem_late(void) · 163 unmodified lines
164164 invoke_init_callbacks();
165165 }
166166
167−void __meminit pgdat_page_ext_init(struct pglist_data *pgdat)
168−{
169− pgdat->node_page_ext = NULL;
170−}
171−
172167 static struct page_ext *lookup_page_ext(const struct page *page)
173168 {
174169 unsigned long pfn = page_to_pfn(page);
@@ -494,10 +489,6 @@ oom: · 319 unmodified lines
494489 panic("Out of memory");
495490 }
496491
497−void __meminit pgdat_page_ext_init(struct pglist_data *pgdat)
498−{
499−}
500−
501492 #endif
502493
503494 /**