mmc: fix null pointer use in mmc_blk_remove_req
authorFranck Jullien <franck.jullien@gmail.com>
Wed, 24 Jul 2013 13:17:48 +0000 (15:17 +0200)
committerlintao <lintao@rock-chips.com>
Fri, 7 Mar 2014 11:54:14 +0000 (19:54 +0800)
commitfce56ca9963a694e3720385c74d79ecf9b578c0e
tree9476b9ca295c7b9263d65a68164f75d0d14c3e80
parenta96f0611079cfea124840fc0820609174d731dfa
mmc: fix null pointer use in mmc_blk_remove_req

A previous commit (fdfa20c1631210d0) reordered the shutdown sequence
in mmc_blk_remove_req. However, mmc_cleanup_queue is now called before
we get the card pointer, and mmc_cleanup_queue sets mq->card to NULL.

This patch moves the card pointer assignment before mmc_cleanup_queue.

Signed-off-by: Franck Jullien <franck.jullien@gmail.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
drivers/mmc/card/block.c