mmc_block: fix probe error cleanup bug
authorJarkko Lavinen <jarkko.lavinen@nokia.com>
Fri, 8 Jan 2010 22:42:59 +0000 (14:42 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Mon, 11 Jan 2010 17:34:06 +0000 (09:34 -0800)
If mmc_blk_set_blksize() fails mmc_blk_probe() the request queue and its
thread have been set up and they need to be shut down properly before
putting the disk.

Signed-off-by: Jarkko Lavinen <jarkko.lavinen@nokia.com>
Signed-off-by: Adrian Hunter <adrian.hunter@nokia.com>
Cc: <linux-mmc@vger.kernel.org>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/mmc/card/block.c

index 5988573bb843b64b7fd828dcc1b8e2b50a98b9f4..ee879117017f021ed898a309e7eda99658d04b30 100644 (file)
@@ -618,6 +618,7 @@ static int mmc_blk_probe(struct mmc_card *card)
        return 0;
 
  out:
+       mmc_cleanup_queue(&md->queue);
        mmc_blk_put(md);
 
        return err;