Re: [PATCH] powerpc: Implement dma_mmap_coherent()

2011-03-31 Thread Benjamin Herrenschmidt
On Thu, 2011-03-31 at 22:39 +0200, Gerhard Pircher wrote: > Anyway, it compiles with explicit type casts and I could test it on my > semi-noncoherent AmigaOne. So far it works just fine with the VIA > onboard > sound and a Soundblaster Live PCI card. > > Thanks a lot for the fix! Yes, the version

Re: [PATCH] powerpc: Implement dma_mmap_coherent()

2011-03-31 Thread Gerhard Pircher
Original-Nachricht > Datum: Fri, 25 Mar 2011 17:50:06 +1100 > Von: Benjamin Herrenschmidt > An: linuxppc-dev > CC: Takashi Iwai > Betreff: [PATCH] powerpc: Implement dma_mmap_coherent() > This is used by Alsa to mmap buffers allocated with dma_alloc

Re: [PATCH] powerpc: Implement dma_mmap_coherent()

2011-03-28 Thread Benjamin Herrenschmidt
On Fri, 2011-03-25 at 17:50 +1100, Benjamin Herrenschmidt wrote: > This is used by Alsa to mmap buffers allocated with dma_alloc_coherent() > into userspace. We need a special variant to handle machines with > non-coherent DMAs as those buffers have "special" virt addresses and > require non-cachab

Re: [PATCH] powerpc: Implement dma_mmap_coherent()

2011-03-25 Thread Takashi Iwai
At Fri, 25 Mar 2011 20:11:57 +1100, Benjamin Herrenschmidt wrote: > > On Fri, 2011-03-25 at 09:06 +0100, Takashi Iwai wrote: > > > @@ -52,6 +53,7 @@ extern void __dma_sync_page(struct page *page, > > unsigned long offset, > > > #define __dma_free_coherent(size, addr) ((void)0) > > >

Re: [PATCH] powerpc: Implement dma_mmap_coherent()

2011-03-25 Thread Benjamin Herrenschmidt
On Fri, 2011-03-25 at 09:06 +0100, Takashi Iwai wrote: > > @@ -52,6 +53,7 @@ extern void __dma_sync_page(struct page *page, > unsigned long offset, > > #define __dma_free_coherent(size, addr) ((void)0) > > #define __dma_sync(addr, size, rw) ((void)0) > > #define __dma_sync

Re: [PATCH] powerpc: Implement dma_mmap_coherent()

2011-03-25 Thread Takashi Iwai
At Fri, 25 Mar 2011 17:50:06 +1100, Benjamin Herrenschmidt wrote: > > This is used by Alsa to mmap buffers allocated with dma_alloc_coherent() > into userspace. We need a special variant to handle machines with > non-coherent DMAs as those buffers have "special" virt addresses and > require non-ca

[PATCH] powerpc: Implement dma_mmap_coherent()

2011-03-24 Thread Benjamin Herrenschmidt
This is used by Alsa to mmap buffers allocated with dma_alloc_coherent() into userspace. We need a special variant to handle machines with non-coherent DMAs as those buffers have "special" virt addresses and require non-cachable mappings Signed-off-by: Benjamin Herrenschmidt --- Dunno if anybody