From f1933a6dd8c813d5f7482f4fc48dd343003a10de Mon Sep 17 00:00:00 2001 From: Andrew Morton Date: Mon, 19 Jan 2004 05:11:34 -0800 Subject: [PATCH] vmscan: initialize zone->{prev,temp}_priority From: Nikita Danilov This patch initializes zone->{prev,temp}_priority to DEF_PRIORITY. Otherwise they are left zeroed, and first run of VM scanner thinks that zones are under enormous stress. --- include/linux/mmzone.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include') diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 9fa4ffb2675c..66cbaa36d878 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h @@ -165,6 +165,13 @@ struct zone { #define GFP_ZONEMASK 0x03 +/* + * The "priority" of VM scanning is how much of the queues we will scan in one + * go. A value of 12 for DEF_PRIORITY implies that we will scan 1/4096th of the + * queues ("queue_length >> 12") during an aging round. + */ +#define DEF_PRIORITY 12 + /* * One allocation request operates on a zonelist. A zonelist * is a list of zones, the first one is the 'goal' of the -- cgit v1.2.3