Re: [PATCH] dma-mapping: fix false positivse warnings in dma_common_free_remap()

2019-10-07 Thread Geert Uytterhoeven
On Sat, Oct 5, 2019 at 10:25 AM Christoph Hellwig wrote: > thanks for the patch. I think it would be much easier to just > use the original open coded check in dma_common_free_remap instead > of adding a new helper. What do you think of the version below? > > --- > From 2cf2aa6a69db0b17b39791442

Re: [PATCH] dma-mapping: fix false positivse warnings in dma_common_free_remap()

2019-10-05 Thread Andrey Smirnov
On Sat, Oct 5, 2019 at 1:25 AM Christoph Hellwig wrote: > > Hi Andrey, > > thanks for the patch. I think it would be much easier to just > use the original open coded check in dma_common_free_remap instead > of adding a new helper. What do you think of the version below? > Looks good to me. I a

[PATCH] dma-mapping: fix false positivse warnings in dma_common_free_remap()

2019-10-05 Thread Andrey Smirnov
Commit 5cf4537975bb ("dma-mapping: introduce a dma_common_find_pages helper") changed invalid input check in dma_common_free_remap() from: if (!area || !area->flags != VM_DMA_COHERENT) to if (!area || !area->flags != VM_DMA_COHERENT || !area->pages) which seem to produce false positives

Re: [PATCH] dma-mapping: fix false positivse warnings in dma_common_free_remap()

2019-10-05 Thread Christoph Hellwig
Hi Andrey, thanks for the patch. I think it would be much easier to just use the original open coded check in dma_common_free_remap instead of adding a new helper. What do you think of the version below? --- >From 2cf2aa6a69db0b17b3979144287af8775c1c1534 Mon Sep 17 00:00:00 2001 From: Andrey Sm