Re: [PATCH 1/3] mmc: omap_hsmmc: NULL pointer upon DTO after CC.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tuesday 20 November 2012 03:12 AM, Andreas Fenkart wrote:
Signed-off-by: Andreas Fenkart <andreas.fenkart@xxxxxxxxxxxxxxxxxxx>
---
  drivers/mmc/host/omap_hsmmc.c |    7 +++++--
  1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c
index 21ca331..13ef4a0 100644
--- a/drivers/mmc/host/omap_hsmmc.c
+++ b/drivers/mmc/host/omap_hsmmc.c
@@ -991,9 +991,12 @@ static inline void omap_hsmmc_reset_controller_fsm(struct omap_hsmmc_host *host,
  static void hsmmc_command_incomplete(struct omap_hsmmc_host *host, int err)
  {
  	omap_hsmmc_reset_controller_fsm(host, SRC);
-	host->cmd->error = err;
+
+	if (host->cmd)
+		host->cmd->error = err;
if (host->data) {
+		host->data->error = err;
  		omap_hsmmc_reset_controller_fsm(host, SRD);
  		omap_hsmmc_dma_cleanup(host, err);
  	}
@@ -1022,7 +1025,7 @@ static void omap_hsmmc_do_irq(struct omap_hsmmc_host *host, int status)
  		}
  	}
- if (end_cmd || ((status & CC) && host->cmd))
+	if ((end_cmd || (status & CC)) && host->cmd)
  		omap_hsmmc_cmd_done(host, host->cmd);
  	if ((end_trans || (status & TC)) && host->mrq)
  		omap_hsmmc_xfer_done(host, data);
Hi Andreas,
Thanks for this, but it's been fixed already with Balaji's patches which I reposted a few hours ago.
Can you please check if it fixes your issues ?
~V
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux