Subject: Pagedeamon -- uvmexp.freemin
To: None <tech-kern@netbsd.org>
From: Juergen Hannken-Illjes <hannken@eis.cs.tu-bs.de>
List: tech-kern
Date: 03/09/2004 16:57:17
Is it right that the pagedaemon starts working when less than uvmexp.freemin
pages are free?

From sys/uvm/uvm_pdaemon.c::uvmpd_tune(void)

	uvmexp.freemin = uvmexp.npages / 20;

	/* between 16k and 256k */
	/* XXX:  what are these values good for? */
	uvmexp.freemin = MAX(uvmexp.freemin, (16*1024) >> PAGE_SHIFT);
	uvmexp.freemin = MIN(uvmexp.freemin, (256*1024) >> PAGE_SHIFT);

What is the reasoning behind these two constants?

uvmexp.npages = (16k >> PAGE_SHIFT) * 20 becomes 320k for a pagesize less
than 16k. Do we really support a machine with less ram than my first PC?

So I suppose uvmexp.freemin will always be 256k. Why is it clipped so low?

-- 
Juergen Hannken-Illjes - hannken@eis.cs.tu-bs.de - TU Braunschweig (Germany)