diff options
author | Maria Yu <[email protected]> | 2022-10-21 18:15:55 +0800 |
---|---|---|
committer | Andrew Morton <[email protected]> | 2022-10-28 13:37:22 -0700 |
commit | fba4eaf93164a6a6eb3cc12a3391b06f6187aa20 (patch) | |
tree | 5c4458b68da7e8a7cd4437812a040e5852bc6c54 | |
parent | bb2282cf01fcae7379314dc026f3b534c83c186c (diff) |
mm/page_isolation: fix clang deadcode warning
When !CONFIG_VM_BUG_ON, there is warning of
clang-analyzer-deadcode.DeadStores:
Value stored to 'mt' during its initialization is never read.
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Maria Yu <[email protected]>
Cc: David Hildenbrand <[email protected]>
Cc: Doug Berger <[email protected]>
Cc: Mike Kravetz <[email protected]>
Cc: Zi Yan <[email protected]>
Cc: Matthew Wilcox <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
-rw-r--r-- | mm/page_isolation.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/page_isolation.c b/mm/page_isolation.c index 04141a9bea70..47fbc1696466 100644 --- a/mm/page_isolation.c +++ b/mm/page_isolation.c @@ -330,7 +330,7 @@ static int isolate_single_pageblock(unsigned long boundary_pfn, int flags, zone->zone_start_pfn); if (skip_isolation) { - int mt = get_pageblock_migratetype(pfn_to_page(isolate_pageblock)); + int mt __maybe_unused = get_pageblock_migratetype(pfn_to_page(isolate_pageblock)); VM_BUG_ON(!is_migrate_isolate(mt)); } else { |