ANDROID: mm: page_alloc: skip dump pages for freeable page
We have seen following dumps from alloc_contig_dump_pages. 05-20 20:04:41.847 1000 503 503 W page : 00000000691ab336 refcount:1 mapcount:0 mapping:0000000000000000 index:0x72aa2d7 pfn:0x9e912e 05-20 20:04:41.847 1000 503 503 W anon flags: 0x8000000000080004(uptodate|swapbacked) 05-20 20:04:41.847 1000 503 503 W raw : 8000000000080004 ffffffff25844b48 ffffffff25844bc8 ffffff89824e46c1 05-20 20:04:41.847 1000 503 503 W raw : 00000000072aa2d7 0000000000000000 00000001ffffffff 0000000000000000 05-20 20:04:41.847 1000 503 503 W : page dumped because: migration failure 05-20 20:04:41.847 1000 503 503 F : page_pinner info is not present (never set?) 05-20 20:04:41.847 1000 503 503 W page : 0000000099d95f64 refcount:1 mapcount:0 mapping:0000000000000000 index:0x72aa2d6 pfn:0x9e912d 05-20 20:04:41.847 1000 503 503 W anon flags: 0x8000000000080004(uptodate|swapbacked) 05-20 20:04:41.847 1000 503 503 W raw : 8000000000080004 ffffffff25844b08 ffffffff25844b88 ffffff89824e46c1 05-20 20:04:41.847 1000 503 503 W raw : 00000000072aa2d6 0000000000000000 00000001ffffffff 0000000000000000 05-20 20:04:41.847 1000 503 503 W : page dumped because: migration failure 05-20 20:04:41.847 1000 503 503 F : page_pinner info is not present (never set?) 05-20 20:04:41.847 1000 503 503 W page : 000000009af39924 refcount:1 mapcount:0 mapping:0000000000000000 index:0x72aa2d5 pfn:0x9e912c 05-20 20:04:41.847 1000 503 503 W anon flags: 0x8000000000080004(uptodate|swapbacked) 05-20 20:04:41.847 1000 503 503 W raw : 8000000000080004 ffffffff25844ac8 ffffffff25844b48 ffffff89824e46c1 05-20 20:04:41.847 1000 503 503 W raw : 00000000072aa2d5 0000000000000000 00000001ffffffff 0000000000000000 05-20 20:04:41.847 1000 503 503 W : page dumped because: migration failure .. .. It means those pages would be temporarily pinnned during migration so the migration failed but putback_movable_pages will end up freeing them since their page refcount are 1 now. Thus, it doesn't deserve to dump them for the debugging aid. Bug: 188908895 Signed-off-by: Minchan Kim <minchan@google.com> Change-Id: I24092f0e53a3154443b9d6786413c4714ae853e8
This commit is contained in:
@@ -8546,11 +8546,21 @@ static void alloc_contig_dump_pages(struct list_head *page_list)
|
||||
|
||||
if (DYNAMIC_DEBUG_BRANCH(descriptor)) {
|
||||
struct page *page;
|
||||
unsigned long nr_skip = 0;
|
||||
unsigned long nr_pages = 0;
|
||||
|
||||
dump_stack();
|
||||
list_for_each_entry(page, page_list, lru)
|
||||
list_for_each_entry(page, page_list, lru) {
|
||||
nr_pages++;
|
||||
/* The page will be freed by putback_movable_pages soon */
|
||||
if (page_count(page) == 1) {
|
||||
nr_skip++;
|
||||
continue;
|
||||
}
|
||||
dump_page(page, "migration failure");
|
||||
}
|
||||
pr_warn("total dump_pages %u skipping %u\n", nr_pages, nr_skip);
|
||||
}
|
||||
}
|
||||
#else
|
||||
static inline void alloc_contig_dump_pages(struct list_head *page_list)
|
||||
|
Reference in New Issue
Block a user