Commit 57ed7b43 authored by Weizhao Ouyang's avatar Weizhao Ouyang Committed by Linus Torvalds

mm/debug: sync up latest migrate_reason to migrate_reason_names

Sync up MR_DEMOTION to migrate_reason_names and add a synch prompt.

Link: https://lkml.kernel.org/r/20210921064553.293905-3-o451686892@gmail.com
Fixes: 26aa2d19 ("mm/migrate: demote pages during reclaim")
Signed-off-by: default avatarWeizhao Ouyang <o451686892@gmail.com>
Reviewed-by: default avatar"Huang, Ying" <ying.huang@intel.com>
Reviewed-by: default avatarJohn Hubbard <jhubbard@nvidia.com>
Cc: Anshuman Khandual <khandual@linux.vnet.ibm.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Pavel Tatashin <pasha.tatashin@soleen.com>
Cc: Yang Shi <yang.shi@linux.alibaba.com>
Cc: Zi Yan <ziy@nvidia.com>
Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: Minchan Kim <minchan@kernel.org>
Cc: Mina Almasry <almasrymina@google.com>
Cc: "Matthew Wilcox (Oracle)" <willy@infradead.org>
Cc: Oscar Salvador <osalvador@suse.de>
Cc: Wei Xu <weixugc@google.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent a4ce7391
...@@ -19,6 +19,11 @@ struct migration_target_control; ...@@ -19,6 +19,11 @@ struct migration_target_control;
*/ */
#define MIGRATEPAGE_SUCCESS 0 #define MIGRATEPAGE_SUCCESS 0
/*
* Keep sync with:
* - macro MIGRATE_REASON in include/trace/events/migrate.h
* - migrate_reason_names[MR_TYPES] in mm/debug.c
*/
enum migrate_reason { enum migrate_reason {
MR_COMPACTION, MR_COMPACTION,
MR_MEMORY_FAILURE, MR_MEMORY_FAILURE,
...@@ -32,7 +37,6 @@ enum migrate_reason { ...@@ -32,7 +37,6 @@ enum migrate_reason {
MR_TYPES MR_TYPES
}; };
/* In mm/debug.c; also keep sync with include/trace/events/migrate.h */
extern const char *migrate_reason_names[MR_TYPES]; extern const char *migrate_reason_names[MR_TYPES];
#ifdef CONFIG_MIGRATION #ifdef CONFIG_MIGRATION
......
...@@ -26,6 +26,7 @@ const char *migrate_reason_names[MR_TYPES] = { ...@@ -26,6 +26,7 @@ const char *migrate_reason_names[MR_TYPES] = {
"numa_misplaced", "numa_misplaced",
"contig_range", "contig_range",
"longterm_pin", "longterm_pin",
"demotion",
}; };
const struct trace_print_flags pageflag_names[] = { const struct trace_print_flags pageflag_names[] = {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment