]> err.no Git - linux-2.6/commitdiff
MMC: S3C24XX: Ensure host->mrq->data is valid
authorBen Dooks <ben-linux@fluff.org>
Mon, 30 Jun 2008 21:40:31 +0000 (22:40 +0100)
committerPierre Ossman <drzeus@drzeus.cx>
Tue, 15 Jul 2008 12:14:47 +0000 (14:14 +0200)
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>
drivers/mmc/host/s3cmci.c

index 4fd11d8864ebc186dcc99ce2bab315f7b0626aa4..ffd9269a187448f95496a356baab16c21e9ac13d 100644 (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);