vmscan: cleanup the scan batching code
The vmscan batching logic is twisting. Move it into a standalone function nr_scan_try_batch() and document it. No behavior change. Signed-off-by: Wu Fengguang <fengguang.wu@intel.com> Acked-by: Rik van Riel <riel@redhat.com> Cc: Nick Piggin <npiggin@suse.de> Cc: Christoph Lameter <cl@linux-foundation.org> Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Acked-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:

committed by
Linus Torvalds

parent
56e49d2188
commit
6e08a369ee
@@ -334,9 +334,9 @@ struct zone {
|
||||
|
||||
/* Fields commonly accessed by the page reclaim scanner */
|
||||
spinlock_t lru_lock;
|
||||
struct {
|
||||
struct zone_lru {
|
||||
struct list_head list;
|
||||
unsigned long nr_scan;
|
||||
unsigned long nr_saved_scan; /* accumulated for batching */
|
||||
} lru[NR_LRU_LISTS];
|
||||
|
||||
struct zone_reclaim_stat reclaim_stat;
|
||||
|
Reference in New Issue
Block a user