Commit 5548f98c46538d1da04eff179a52e50537d11465

Authored by Mika Westerberg
Committed by Mark Brown
1 parent 7d13205581

spi/pxa2xx: use GFP_ATOMIC in sg table allocation

pxa2xx_spi_map_dma_buffer() gets called in tasklet context so we can't
sleep when we allocate a new sg table. Use GFP_ATOMIC here instead.

Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
Cc: stable@vger.kernel.org

Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff

drivers/spi/spi-pxa2xx-dma.c
... ... @@ -59,7 +59,7 @@
59 59 int ret;
60 60  
61 61 sg_free_table(sgt);
62   - ret = sg_alloc_table(sgt, nents, GFP_KERNEL);
  62 + ret = sg_alloc_table(sgt, nents, GFP_ATOMIC);
63 63 if (ret)
64 64 return ret;
65 65 }