瀏覽代碼

mmc: sdhci: Avoid STOP cmd triggering warning in sdhci_send_command()

The STOP command is sent in error conditions, even when the command is
not finished. Avoid triggering the warning for that in sdhci_send_command()
by setting host->cmd to NULL first.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Adrian Hunter 9 年之前
父節點
當前提交
8842fd17b6
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      drivers/mmc/host/sdhci.c

+ 2 - 0
drivers/mmc/host/sdhci.c

@@ -1027,6 +1027,8 @@ static void sdhci_finish_data(struct sdhci_host *host)
 			sdhci_do_reset(host, SDHCI_RESET_DATA);
 			sdhci_do_reset(host, SDHCI_RESET_DATA);
 		}
 		}
 
 
+		/* Avoid triggering warning in sdhci_send_command() */
+		host->cmd = NULL;
 		sdhci_send_command(host, data->stop);
 		sdhci_send_command(host, data->stop);
 	} else {
 	} else {
 		sdhci_finish_mrq(host, data->mrq);
 		sdhci_finish_mrq(host, data->mrq);