Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-06-03 Thread Russell King
On Wed, May 23, 2007 at 09:03:02PM -0700, Christoph Lameter wrote: > On Thu, 24 May 2007, Paul Mackerras wrote: > > Also there is the problem that some drivers use ZONE_DMA allocations > > because their device can only generate addresses below some limit, but > > on a platform with an IOMMU there i

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-24 Thread Alan Cox
> Also there is the problem that some drivers use ZONE_DMA allocations > because their device can only generate addresses below some limit, but > on a platform with an IOMMU there is in fact no restriction on what > memory the device can access. Bzt - have to call your bluff on that one The I

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-24 Thread Russell King
On Wed, May 23, 2007 at 04:07:12PM -0700, Christoph Lameter wrote: > On Wed, 23 May 2007, Russell King wrote: > > At the end of the day, it is _far_ simpler from an architectural point > > of view for memory to live in the DMA zone and disable the normal and > > highmem zones than it is to selectiv

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-23 Thread Christoph Lameter
On Thu, 24 May 2007, Paul Mackerras wrote: > That is (presumably) true today, but is in fact a redefinition of what > ZONE_DMA historically was for. I do not know too much about the history but when I tried to correlate all the different ways that arches use the zone this definition was the most

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-23 Thread Paul Mackerras
Christoph Lameter writes: > > The DMA zone is for memory allocations _for_ _DMA_. If all your memory > > is DMA-able then it belongs in the DMA zone. > > Nope. The DMA zone is for crappy DMA devices that can only use a portion > of memory. That is (presumably) true today, but is in fact a rede

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-23 Thread Christoph Lameter
On Wed, 23 May 2007, Russell King wrote: > > GFP_DMA allocations are an exception and that exception can be removed > > from the core VM by not defining ZONE_DMA. You cannot switch off the > > NORMAL zone. > > I'd like to be able to switch off the normal and highmem zones and leave > just the D

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-23 Thread Russell King
On Wed, May 23, 2007 at 10:15:10AM -0700, Christoph Lameter wrote: > On Wed, 23 May 2007, Russell King wrote: > > > > That is wrong. ppc should have ZONE_NORMAL and no ZONE_DMA. > > > Otherwise you cannot switch off ZONE_DMA and you cannot switch off > > > bounce. ZONE_DMA is a zone for exception

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-23 Thread Christoph Lameter
On Wed, 23 May 2007, Russell King wrote: > > That is wrong. ppc should have ZONE_NORMAL and no ZONE_DMA. > > Otherwise you cannot switch off ZONE_DMA and you cannot switch off > > bounce. ZONE_DMA is a zone for exceptional allocs. If you do not have > > those then you only have normal allocs ->

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-23 Thread Russell King
On Mon, May 21, 2007 at 10:27:16PM -0700, Christoph Lameter wrote: > On Tue, 22 May 2007, KAMEZAWA Hiroyuki wrote: > > > > +config BOUNCE > > > + def_bool y > > > + depends on BLOCK && MMU && (ZONE_DMA || HIGHMEM) > > > + > > > > AFAIK, ppc has only ZONE_DMA and it never needs bounce. > > Is this

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-22 Thread Jens Axboe
On Mon, May 21 2007, Christoph Lameter wrote: > The bounce buffer logic is included on systems that do not need it. > If a system does not have zones like ZONE_DMA and ZONE_HIGHMEM that > can lead to the use of bounce buffers then there is no need to reserve > memory pools etc etc. This is true f.

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-21 Thread Christoph Lameter
On Tue, 22 May 2007, KAMEZAWA Hiroyuki wrote: > > +config BOUNCE > > + def_bool y > > + depends on BLOCK && MMU && (ZONE_DMA || HIGHMEM) > > + > > AFAIK, ppc has only ZONE_DMA and it never needs bounce. > Is this ok ? That is wrong. ppc should have ZONE_NORMAL and no ZONE_DMA. Otherwise you

Re: Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-21 Thread KAMEZAWA Hiroyuki
On Mon, 21 May 2007 21:03:40 -0700 (PDT) Christoph Lameter <[EMAIL PROTECTED]> wrote: > The bounce buffer logic is included on systems that do not need it. > If a system does not have zones like ZONE_DMA and ZONE_HIGHMEM that > can lead to the use of bounce buffers then there is no need to reserve

Define CONFIG_BOUNCE to avoid useless inclusion of bounce buffer logic.

2007-05-21 Thread Christoph Lameter
The bounce buffer logic is included on systems that do not need it. If a system does not have zones like ZONE_DMA and ZONE_HIGHMEM that can lead to the use of bounce buffers then there is no need to reserve memory pools etc etc. This is true f.e. for SGI Altix. Also nicifies the Makefile and gets