]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
pool: Improve memory usage for devices which can't cross boundaries
authorMatthew Wilcox <matthew@wil.cx>
Mon, 3 Dec 2007 19:16:24 +0000 (14:16 -0500)
committerMatthew Wilcox <matthew@wil.cx>
Tue, 4 Dec 2007 15:39:58 +0000 (10:39 -0500)
commite34f44b3517fe545f7fd45a8c2f6ee1e5e4432d3
tree826655b80622dee3cff9ddd0e9aa3ee9908627fe
parenta35a3455142976e3fffdf27027f3082cbaba6e8c
pool: Improve memory usage for devices which can't cross boundaries

The previous implementation simply refused to allocate more than a
boundary's worth of data from an entire page.  Some users didn't know
this, so specified things like SMP_CACHE_BYTES, not realising the
horrible waste of memory that this was.  It's fairly easy to correct
this problem, just by ensuring we don't cross a boundary within a page.
This even helps drivers like EHCI (which can't cross a 4k boundary)
on machines with larger page sizes.

Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
Acked-by: David S. Miller <davem@davemloft.net>
mm/dmapool.c