mm/page_alloc: simplify update of pgdat in wake_all_kswapds
authorChen Wandun <chenwandun@huawei.com>
Fri, 29 Apr 2022 21:36:59 +0000 (14:36 -0700)
committerakpm <akpm@linux-foundation.org>
Fri, 29 Apr 2022 21:36:59 +0000 (14:36 -0700)
commitd137a7cb9b2ab8155184b2da9a304afff8f84d36
tree716f3ffba0c6812ec54ac533410815a254a23d1b
parentec2a0f9c8b50865a11720651c9c536f20c578def
mm/page_alloc: simplify update of pgdat in wake_all_kswapds

There is no need to update last_pgdat for each zone, only update
last_pgdat when iterating the first zone of a node.

Link: https://lkml.kernel.org/r/20220322115635.2708989-1-chenwandun@huawei.com
Signed-off-by: Chen Wandun <chenwandun@huawei.com>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Cc: Mel Gorman <mgorman@techsingularity.net>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/page_alloc.c