On Wed, 10 Jan 2007 14:29:35 +1100 Neil Brown <[EMAIL PROTECTED]> wrote:
> > > > It would be better if we can avoid creating the second global variable. Is > > it not possible to remove dirty_ratio? Make everything work off > > vm_dirty_kb and do arithmetricks at the /proc/sys/vm/dirty_ratio interface? > > Uhmmm... not sure what you are thinking. > I guess we could teach vm.dirty_ratio to take a floating point number > (but does sysctl understand that?) so we could set it to 0.01 or > similar, but that is missing the point in a way. We don't really want > to set a small ratio. We want to set a small maximum number. I mean remove the kernel-internal dirty_ratio variable and use /proc/sys/vm/dirty_ratio as an accessor to `long vm_dirty_kb', with appropriate conversions when /proc/sys/vm/dirty_ratio is written to and read from. > It could make lots of sense to have two numbers. A ratio that wins on > a small memory machine and a fixed number that wins on a large memory > machine. Different trade offs are more significant in the different > cases. hm. > > > > We should perform the same conversion to dirty_background_ratio, I suspect. > > > > I didn't add a fixed limit for dirty_background_ratio as it seemed > reasonable to assume that (dirty_background_ratio / dirty_ratio) was a > meaningful value, and just multiplied the final 'dirty' figure by this > ration to get the 'background' figure. Sounds complex. Better, I think, to create (and recommend) vm_dirty_kb and vm_dirty_background_kb and deprecate the old knobs. > > And these guys should be `long', not `int'. Otherwise things will go > > pearshaped at 2 tabbybytes. > > I don't think so. You would need to have blindingly fast storage > before there would be any interest in vm_dirty_kb getting anything > close to t*bytes. But I guess we can make it 'unsigned long' if it > helps. > A 16TB machine would overflow that int by default. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/