On Tue, Jan 24, 2012 at 06:10:40PM +0200, Pekka Enberg wrote: > On Tue, 2012-01-24 at 13:38 -0200, Marcelo Tosatti wrote: > > Having userspace specify the "sample period" for low memory notification > > makes no sense. The frequency of notifications is a function of the > > memory pressure. > > Sure, it makes sense to autotune sample period. I don't see the problem > with letting userspace decide it for themselves if they want to. > > Pekka Application polls on a file descriptor waiting for asynchronous events, particular conditions of memory reclaim upon which an action is necessary. These signalled conditions are not simply percentages of free memory, but depend on the amount of freeable cache available, etc. Otherwise applications could monitor /proc/mem_info and act on that. What is the point of sampling in the interface as you have it? Application can read() from the file descriptor to retrieve the current status, if it wishes. The objective in this argument is to make the API as simple and easy to use as possible. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/ Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>