Re: [PATCH v2] mtd: onenand: omap2: Disable DMA for HIGHMEM buffers

2018-05-02 Thread Boris Brezillon
On Wed, 2 May 2018 10:06:36 +0200 Ladislav Michl wrote: > Hi Boris, > > (and apologies for delay) > > On Fri, Apr 20, 2018 at 10:01:34PM +0200, Boris Brezillon wrote: > > Hi Ladislav, > > > > On Mon, 16 Apr 2018 08:52:59 +0200 > > Ladislav Michl wrote: > > > > > dma_map_single doesn't get

Re: [PATCH v2] mtd: onenand: omap2: Disable DMA for HIGHMEM buffers

2018-05-02 Thread Ladislav Michl
Hi Boris, (and apologies for delay) On Fri, Apr 20, 2018 at 10:01:34PM +0200, Boris Brezillon wrote: > Hi Ladislav, > > On Mon, 16 Apr 2018 08:52:59 +0200 > Ladislav Michl wrote: > > > dma_map_single doesn't get the proper DMA address for vmalloced area, > > That's not true, it returns the ri

Re: [PATCH v2] mtd: onenand: omap2: Disable DMA for HIGHMEM buffers

2018-04-20 Thread Boris Brezillon
Hi Ladislav, On Mon, 16 Apr 2018 08:52:59 +0200 Ladislav Michl wrote: > dma_map_single doesn't get the proper DMA address for vmalloced area, That's not true, it returns the right DMA (physical) address, it's just that: 1/ the memory location is not necessarily physically contiguous 2/ in case

Re: [PATCH v2] mtd: onenand: omap2: Disable DMA for HIGHMEM buffers

2018-04-16 Thread Ladislav Michl
Hi Péter, On Mon, Apr 16, 2018 at 02:34:54PM +0300, Peter Ujfalusi wrote: > On 2018-04-16 09:52, Ladislav Michl wrote: > > dma_map_single doesn't get the proper DMA address for vmalloced area, > > Which is not a big surprise as vmalloc will allocate contiguous virtual > memory (which might corres

Re: [PATCH v2] mtd: onenand: omap2: Disable DMA for HIGHMEM buffers

2018-04-16 Thread Peter Ujfalusi
On 2018-04-16 09:52, Ladislav Michl wrote: > dma_map_single doesn't get the proper DMA address for vmalloced area, Which is not a big surprise as vmalloc will allocate contiguous virtual memory (which might corresponds to non-contiguous physical memory). Even if you somehow get the physical addr