Re: [PATCH 4/4] dmapool: Improve memory usage for devices which can't cross boundaries

2007-09-26 Thread David Miller
From: Matthew Wilcox <[EMAIL PROTECTED]> Date: Wed, 26 Sep 2007 15:01:19 -0400 > 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 >

Re: [PATCH 4/4] dmapool: Improve memory usage for devices which can't cross boundaries

2007-09-26 Thread roel
Matthew Wilcox wrote: [...] > @@ -142,14 +144,13 @@ struct dma_pool *dma_pool_create(const char *name, > struct device *dev, > if ((size % align) != 0) > size = ALIGN(size, align); > > - if (allocation == 0) { > - if (PAGE_SIZE < size) > -

[PATCH 4/4] dmapool: Improve memory usage for devices which can't cross boundaries

2007-09-26 Thread Matthew Wilcox
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

[PATCH 4/4] dmapool: Improve memory usage for devices which can't cross boundaries

2007-09-26 Thread Matthew Wilcox
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

Re: [PATCH 4/4] dmapool: Improve memory usage for devices which can't cross boundaries

2007-09-26 Thread roel
Matthew Wilcox wrote: [...] @@ -142,14 +144,13 @@ struct dma_pool *dma_pool_create(const char *name, struct device *dev, if ((size % align) != 0) size = ALIGN(size, align); - if (allocation == 0) { - if (PAGE_SIZE size) -

Re: [PATCH 4/4] dmapool: Improve memory usage for devices which can't cross boundaries

2007-09-26 Thread David Miller
From: Matthew Wilcox [EMAIL PROTECTED] Date: Wed, 26 Sep 2007 15:01:19 -0400 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