2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-21 19:53:59 +08:00

MMC: S3C24XX: Ensure host->mrq->data is valid

Fix a crash if host->mrq->data is NULL on ending a transfer.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
This commit is contained in:
Ben Dooks 2008-06-30 22:40:31 +01:00 committed by Pierre Ossman
parent cf0984c8ed
commit 7c14450ed6

View File

@ -353,7 +353,8 @@ static void pio_tasklet(unsigned long data)
(host->pio_active == XFER_READ) ? "read" : "write",
host->pio_count, host->pio_words);
host->mrq->data->error = -EINVAL;
if (host->mrq->data)
host->mrq->data->error = -EINVAL;
}
finalize_request(host);