qemu-e2k/hw/sd
Michael Olbrich 8573378e62 hw/sd: fix out-of-bounds check for multi block reads
The current code checks if the next block exceeds the size of the card.
This generates an error while reading the last block of the card.
Do the out-of-bounds check when starting to read a new block to fix this.

This issue became visible with increased error checking in Linux 4.13.

Cc: qemu-stable@nongnu.org
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Reviewed-by: Alistair Francis <alistair.francis@xilinx.com>
Message-id: 20170916091611.10241-1-m.olbrich@pengutronix.de
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2017-10-06 16:46:47 +01:00
..
bcm2835_sdhost.c
core.c
Makefile.objs
milkymist-memcard.c qdev: Replace cannot_instantiate_with_device_add_yet with !user_creatable 2017-05-17 10:37:00 -03:00
omap_mmc.c
pl181.c qdev: Replace cannot_instantiate_with_device_add_yet with !user_creatable 2017-05-17 10:37:00 -03:00
pxa2xx_mmci.c
sd.c hw/sd: fix out-of-bounds check for multi block reads 2017-10-06 16:46:47 +01:00
sdhci-internal.h
sdhci.c generic-sdhci: Remove user_creatable flag 2017-05-17 10:37:01 -03:00
ssi-sd.c
trace-events trace-events: fix code style: print 0x before hex numbers 2017-08-01 12:13:07 +01:00