mirror of
git://git.yoctoproject.org/linux-yocto.git
synced 2025-07-05 13:25:20 +02:00
dmaengine: bcm2835: Avoid GFP_KERNEL in device_prep_slave_sg
[ Upstream commitf147384774
] The commitaf19b7ce76
("mmc: bcm2835: Avoid possible races on data requests") introduces a possible circular locking dependency, which is triggered by swapping to the sdhost interface. So instead of reintroduce the race condition again, we could also avoid this situation by using GFP_NOWAIT for the allocation of the DMA buffer descriptors. Reported-by: Aaro Koskinen <aaro.koskinen@iki.fi> Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com> Fixes:af19b7ce76
("mmc: bcm2835: Avoid possible races on data requests") Link: http://lists.infradead.org/pipermail/linux-rpi-kernel/2019-March/008615.html Signed-off-by: Vinod Koul <vkoul@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
d4dc7d99b1
commit
d0f8faa2f5
|
@ -674,7 +674,7 @@ static struct dma_async_tx_descriptor *bcm2835_dma_prep_slave_sg(
|
||||||
d = bcm2835_dma_create_cb_chain(chan, direction, false,
|
d = bcm2835_dma_create_cb_chain(chan, direction, false,
|
||||||
info, extra,
|
info, extra,
|
||||||
frames, src, dst, 0, 0,
|
frames, src, dst, 0, 0,
|
||||||
GFP_KERNEL);
|
GFP_NOWAIT);
|
||||||
if (!d)
|
if (!d)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user