bcm2835-mmc: Prevent DMA race condition
authorPhil Elwell <phil@raspberrypi.org>
Tue, 18 Jul 2017 14:30:48 +0000 (15:30 +0100)
committerRaspbian kernel package updater <root@raspbian.org>
Sun, 8 Oct 2017 01:08:20 +0000 (01:08 +0000)
commitb74e368aeaed61e74c850bf3227afb3aa3013b98
tree7a825c831ea22353f6151f5e32c1cc5943ef78c9
parentb873dab8b4d22986de6695a547b7cfb4ed7f552d
bcm2835-mmc: Prevent DMA race condition

The end of a read operation is triggered by the completion of the DMA
transfer, but writes are complete when the data IRQ is raised. The
bcm2835-mmc driver contains a race between the handling of the DMA
completion interrupt and the submission of the next request. Fix the
race by deferring the completion of the request until the DMA
transfer finishes.

Signed-off-by: Phil Elwell <phil@raspberrypi.org>
drivers/mmc/host/bcm2835-mmc.c