Commit 3dfbb555 authored by Vlastimil Babka's avatar Vlastimil Babka Committed by Andrew Morton

mm, vmscan: remove ISOLATE_UNMAPPED

This isolate_mode_t flag is effectively unused since 89f6c88a ("mm:
__isolate_lru_page_prepare() in isolate_migratepages_block()") as
sc->may_unmap is now checked directly (and only node_reclaim has a mode
that sets it to 0).  The last remaining place is mm_vmscan_lru_isolate
tracepoint for the isolate_mode parameter.  That one was mainly used to
indicate the active/inactive mode, which the trace-vmscan-postprocess.pl
script consumed, but that got silently broken.  After fixing the script by
the previous patch, it does not need the isolate_mode anymore.  So just
remove the parameter and with that the whole ISOLATE_UNMAPPED flag.

Link: https://lkml.kernel.org/r/20230914131637.12204-4-vbabka@suse.czSigned-off-by: default avatarVlastimil Babka <vbabka@suse.cz>
Cc: Hugh Dickins <hughd@google.com>
Cc: Mel Gorman <mgorman@techsingularity.net>
Cc: Vlastimil Babka <vbabka@suse.cz>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent 83121580
...@@ -112,7 +112,7 @@ my $regex_direct_end_default = 'nr_reclaimed=([0-9]*)'; ...@@ -112,7 +112,7 @@ my $regex_direct_end_default = 'nr_reclaimed=([0-9]*)';
my $regex_kswapd_wake_default = 'nid=([0-9]*) order=([0-9]*)'; my $regex_kswapd_wake_default = 'nid=([0-9]*) order=([0-9]*)';
my $regex_kswapd_sleep_default = 'nid=([0-9]*)'; my $regex_kswapd_sleep_default = 'nid=([0-9]*)';
my $regex_wakeup_kswapd_default = 'nid=([0-9]*) order=([0-9]*) gfp_flags=([A-Z_|]*)'; my $regex_wakeup_kswapd_default = 'nid=([0-9]*) order=([0-9]*) gfp_flags=([A-Z_|]*)';
my $regex_lru_isolate_default = 'isolate_mode=([0-9]*) classzone=([0-9]*) order=([0-9]*) nr_requested=([0-9]*) nr_scanned=([0-9]*) nr_skipped=([0-9]*) nr_taken=([0-9]*) lru=([a-z_]*)'; my $regex_lru_isolate_default = 'classzone=([0-9]*) order=([0-9]*) nr_requested=([0-9]*) nr_scanned=([0-9]*) nr_skipped=([0-9]*) nr_taken=([0-9]*) lru=([a-z_]*)';
my $regex_lru_shrink_inactive_default = 'nid=([0-9]*) nr_scanned=([0-9]*) nr_reclaimed=([0-9]*) nr_dirty=([0-9]*) nr_writeback=([0-9]*) nr_congested=([0-9]*) nr_immediate=([0-9]*) nr_activate_anon=([0-9]*) nr_activate_file=([0-9]*) nr_ref_keep=([0-9]*) nr_unmap_fail=([0-9]*) priority=([0-9]*) flags=([A-Z_|]*)'; my $regex_lru_shrink_inactive_default = 'nid=([0-9]*) nr_scanned=([0-9]*) nr_reclaimed=([0-9]*) nr_dirty=([0-9]*) nr_writeback=([0-9]*) nr_congested=([0-9]*) nr_immediate=([0-9]*) nr_activate_anon=([0-9]*) nr_activate_file=([0-9]*) nr_ref_keep=([0-9]*) nr_unmap_fail=([0-9]*) priority=([0-9]*) flags=([A-Z_|]*)';
my $regex_lru_shrink_active_default = 'lru=([A-Z_]*) nr_taken=([0-9]*) nr_active=([0-9]*) nr_deactivated=([0-9]*) nr_referenced=([0-9]*) priority=([0-9]*) flags=([A-Z_|]*)' ; my $regex_lru_shrink_active_default = 'lru=([A-Z_]*) nr_taken=([0-9]*) nr_active=([0-9]*) nr_deactivated=([0-9]*) nr_referenced=([0-9]*) priority=([0-9]*) flags=([A-Z_|]*)' ;
my $regex_writepage_default = 'page=([0-9a-f]*) pfn=([0-9]*) flags=([A-Z_|]*)'; my $regex_writepage_default = 'page=([0-9a-f]*) pfn=([0-9]*) flags=([A-Z_|]*)';
...@@ -204,7 +204,7 @@ $regex_wakeup_kswapd = generate_traceevent_regex( ...@@ -204,7 +204,7 @@ $regex_wakeup_kswapd = generate_traceevent_regex(
$regex_lru_isolate = generate_traceevent_regex( $regex_lru_isolate = generate_traceevent_regex(
"vmscan/mm_vmscan_lru_isolate", "vmscan/mm_vmscan_lru_isolate",
$regex_lru_isolate_default, $regex_lru_isolate_default,
"isolate_mode", classzone", "order", "classzone", "order",
"nr_requested", "nr_scanned", "nr_skipped", "nr_taken", "nr_requested", "nr_scanned", "nr_skipped", "nr_taken",
"lru"); "lru");
$regex_lru_shrink_inactive = generate_traceevent_regex( $regex_lru_shrink_inactive = generate_traceevent_regex(
...@@ -379,8 +379,8 @@ EVENT_PROCESS: ...@@ -379,8 +379,8 @@ EVENT_PROCESS:
print " $regex_lru_isolate/o\n"; print " $regex_lru_isolate/o\n";
next; next;
} }
my $nr_scanned = $5; my $nr_scanned = $4;
my $lru = $8; my $lru = $7;
# To closer match vmstat scanning statistics, only count # To closer match vmstat scanning statistics, only count
# inactive lru as scanning # inactive lru as scanning
......
...@@ -639,8 +639,6 @@ struct lruvec { ...@@ -639,8 +639,6 @@ struct lruvec {
#endif #endif
}; };
/* Isolate unmapped pages */
#define ISOLATE_UNMAPPED ((__force isolate_mode_t)0x2)
/* Isolate for asynchronous migration */ /* Isolate for asynchronous migration */
#define ISOLATE_ASYNC_MIGRATE ((__force isolate_mode_t)0x4) #define ISOLATE_ASYNC_MIGRATE ((__force isolate_mode_t)0x4)
/* Isolate unevictable pages */ /* Isolate unevictable pages */
......
...@@ -285,10 +285,9 @@ TRACE_EVENT(mm_vmscan_lru_isolate, ...@@ -285,10 +285,9 @@ TRACE_EVENT(mm_vmscan_lru_isolate,
unsigned long nr_scanned, unsigned long nr_scanned,
unsigned long nr_skipped, unsigned long nr_skipped,
unsigned long nr_taken, unsigned long nr_taken,
isolate_mode_t isolate_mode,
int lru), int lru),
TP_ARGS(highest_zoneidx, order, nr_requested, nr_scanned, nr_skipped, nr_taken, isolate_mode, lru), TP_ARGS(highest_zoneidx, order, nr_requested, nr_scanned, nr_skipped, nr_taken, lru),
TP_STRUCT__entry( TP_STRUCT__entry(
__field(int, highest_zoneidx) __field(int, highest_zoneidx)
...@@ -297,7 +296,6 @@ TRACE_EVENT(mm_vmscan_lru_isolate, ...@@ -297,7 +296,6 @@ TRACE_EVENT(mm_vmscan_lru_isolate,
__field(unsigned long, nr_scanned) __field(unsigned long, nr_scanned)
__field(unsigned long, nr_skipped) __field(unsigned long, nr_skipped)
__field(unsigned long, nr_taken) __field(unsigned long, nr_taken)
__field(unsigned int, isolate_mode)
__field(int, lru) __field(int, lru)
), ),
...@@ -308,7 +306,6 @@ TRACE_EVENT(mm_vmscan_lru_isolate, ...@@ -308,7 +306,6 @@ TRACE_EVENT(mm_vmscan_lru_isolate,
__entry->nr_scanned = nr_scanned; __entry->nr_scanned = nr_scanned;
__entry->nr_skipped = nr_skipped; __entry->nr_skipped = nr_skipped;
__entry->nr_taken = nr_taken; __entry->nr_taken = nr_taken;
__entry->isolate_mode = (__force unsigned int)isolate_mode;
__entry->lru = lru; __entry->lru = lru;
), ),
...@@ -316,8 +313,7 @@ TRACE_EVENT(mm_vmscan_lru_isolate, ...@@ -316,8 +313,7 @@ TRACE_EVENT(mm_vmscan_lru_isolate,
* classzone is previous name of the highest_zoneidx. * classzone is previous name of the highest_zoneidx.
* Reason not to change it is the ABI requirement of the tracepoint. * Reason not to change it is the ABI requirement of the tracepoint.
*/ */
TP_printk("isolate_mode=%d classzone=%d order=%d nr_requested=%lu nr_scanned=%lu nr_skipped=%lu nr_taken=%lu lru=%s", TP_printk("classzone=%d order=%d nr_requested=%lu nr_scanned=%lu nr_skipped=%lu nr_taken=%lu lru=%s",
__entry->isolate_mode,
__entry->highest_zoneidx, __entry->highest_zoneidx,
__entry->order, __entry->order,
__entry->nr_requested, __entry->nr_requested,
......
...@@ -1689,8 +1689,7 @@ static unsigned long isolate_lru_folios(unsigned long nr_to_scan, ...@@ -1689,8 +1689,7 @@ static unsigned long isolate_lru_folios(unsigned long nr_to_scan,
} }
*nr_scanned = total_scan; *nr_scanned = total_scan;
trace_mm_vmscan_lru_isolate(sc->reclaim_idx, sc->order, nr_to_scan, trace_mm_vmscan_lru_isolate(sc->reclaim_idx, sc->order, nr_to_scan,
total_scan, skipped, nr_taken, total_scan, skipped, nr_taken, lru);
sc->may_unmap ? 0 : ISOLATE_UNMAPPED, lru);
update_lru_sizes(lruvec, lru, nr_zone_taken); update_lru_sizes(lruvec, lru, nr_zone_taken);
return nr_taken; return nr_taken;
} }
......
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