ANDROID: mm: compaction: fix isolate_and_split_free_page() redefinition
Guard isolate_and_split_free_page() with CONFIG_COMPACTION. This fixes the follwoing build error as the function collides with its inline stub from the header file: mm/compaction.c:766:15: error: redefinition of ‘isolate_and_split_free_page’ 766 | unsigned long isolate_and_split_free_page(struct page *page, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from mm/compaction.c:14: ./include/linux/compaction.h:241:29: note: previous definition of ‘isolate_and_split_free_page’ was here 241 | static inline unsigned long isolate_and_split_free_page(struct page *page, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ Bug: 201263307 Fixes: 8cd9aa93b726 ("ANDROID: implement wrapper for reverse migration") Reported-by: kernelci.org bot <bot@kernelci.org> Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Carlos Llamas <cmllamas@google.com> Change-Id: Ie8f3fedcc9d4af5cfdcfd5829377671745ab77d6
This commit is contained in:
parent
93ad5b8123
commit
061e34c52e
|
@ -758,6 +758,7 @@ isolate_freepages_range(struct compact_control *cc,
|
|||
return pfn;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_COMPACTION
|
||||
unsigned long isolate_and_split_free_page(struct page *page,
|
||||
struct list_head *list)
|
||||
{
|
||||
|
@ -780,6 +781,7 @@ unsigned long isolate_and_split_free_page(struct page *page,
|
|||
return isolated;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(isolate_and_split_free_page);
|
||||
#endif
|
||||
|
||||
/* Similar to reclaim, but different enough that they don't share logic */
|
||||
static bool too_many_isolated(pg_data_t *pgdat)
|
||||
|
|
Loading…
Reference in New Issue