aboutsummaryrefslogtreecommitdiff
path: root/drivers/staging/mt7621-mmc
diff options
context:
space:
mode:
authorChristian Lütke-Stetzkamp <christian@lkamp.de>2018-04-29 19:32:34 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-05-06 19:08:06 -0700
commiteafda89222e103212f98888667fe0c5475d011ec (patch)
tree80ab6900f25fd189c83b05bc16122851fe05406e /drivers/staging/mt7621-mmc
parentec7375d1f50ef1092e1feaf9e9bf5ca3d862d7f2 (diff)
staging: mt7621-mmc: Do not BUG() if mrq set in msdc_ops_request
Currently the code BUG()'s, if host->mrq is set at the beginning of msdc_ops_request. This shoould normally not happen, but it is not that critical, because the critical sections are protected by a spin lock and in the worst case, some commands to the card are lost, so it is sufficient to just WARN_ON(). Signed-off-by: Christian Lütke-Stetzkamp <christian@lkamp.de> Reviewed-by: NeilBrown <neil@brown.name> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/mt7621-mmc')
-rw-r--r--drivers/staging/mt7621-mmc/sd.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/staging/mt7621-mmc/sd.c b/drivers/staging/mt7621-mmc/sd.c
index 7a6101e62891..7549ef40ac17 100644
--- a/drivers/staging/mt7621-mmc/sd.c
+++ b/drivers/staging/mt7621-mmc/sd.c
@@ -1716,10 +1716,7 @@ static void msdc_ops_request(struct mmc_host *mmc, struct mmc_request *mrq)
u32 ticks = 0, opcode = 0, sizes = 0, bRx = 0;
#endif /* end of --- */
- if (host->mrq) {
- ERR_MSG("XXX host->mrq<0x%.8x>", (int)host->mrq);
- BUG();
- }
+ WARN_ON(host->mrq);
if (!is_card_present(host) || host->power_mode == MMC_POWER_OFF) {
ERR_MSG("cmd<%d> card<%d> power<%d>", mrq->cmd->opcode, is_card_present(host), host->power_mode);