MMCI: don't read command response when invalid
Subsystems (2)
A message that is not in the archive (sent off-list or not yet received): [email protected]
PATCH 1/1 MMCI: don't read command response when invalid
Don't read the command response from the registers when either the command timed out (because there was no response from the card) or the checksum on the response was invalid.
--- drivers/mmc/host/mmci.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/mmc/host/mmci.c +5 -5
@@ -394,15 +394,15 @@ mmci_cmd_irq(struct mmci_host *host, struct mmc_command *cmd, host->cmd =NULL ; - cmd->resp[0 ] =readl (base +MMCIRESPONSE0 ); - cmd->resp[1 ] =readl (base +MMCIRESPONSE1 ); - cmd->resp[2 ] =readl (base +MMCIRESPONSE2 ); - cmd->resp[3 ] =readl (base +MMCIRESPONSE3 ); -if (status &MCI_CMDTIMEOUT ) { cmd->error = -ETIMEDOUT ; }else if (status &MCI_CMDCRCFAIL && cmd->flags &MMC_RSP_CRC ) { cmd->error = -EILSEQ ; + }else { + cmd->resp[0 ] =readl (base +MMCIRESPONSE0 ); + cmd->resp[1 ] =readl (base +MMCIRESPONSE1 ); + cmd->resp[2 ] =readl (base +MMCIRESPONSE2 ); + cmd->resp[3 ] =readl (base +MMCIRESPONSE3 ); }if (!cmd->data || cmd->error) {
PATCH 1/1 MMCI: don't read command response when invalid
Hi,
Quoted 24 lines · Russell King - ARM Linux
Don't read the command response from the registers when either the command timed out (because there was no response from the card) or the checksum on the response was invalid.
Signed-off-by Russell King <[email protected]>--- drivers/mmc/host/mmci.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)drivers/mmc/host/mmci.c +0
-5@@ -394,15 +394,15 @@ mmci_cmd_irq(struct mmci_host *host, struct mmc_command *cmd, host->cmd =NULL ; - cmd->resp[0 ] =readl (base +MMCIRESPONSE0 ); - cmd->resp[1 ] =readl (base +MMCIRESPONSE1 ); - cmd->resp[2 ] =readl (base +MMCIRESPONSE2 ); - cmd->resp[3 ] =readl (base +MMCIRESPONSE3 ); -if (status &MCI_CMDTIMEOUT ) { cmd->error = -ETIMEDOUT ;
drivers/mmc/host/mmci.c mmci_cmd_irq(struct mmci_host *host, struct mmc_command *cmd, · line 408
Quoted 10 lines
drivers/mmc/host/mmci.c +5
-0}else if (status &MCI_CMDCRCFAIL && cmd->flags &MMC_RSP_CRC ) { cmd->error = -EILSEQ ; + }else { + cmd->resp[0 ] =readl (base +MMCIRESPONSE0 ); + cmd->resp[1 ] =readl (base +MMCIRESPONSE1 ); + cmd->resp[2 ] =readl (base +MMCIRESPONSE2 ); + cmd->resp[3 ] =readl (base +MMCIRESPONSE3 ); }if (!cmd->data || cmd->error) {
Thanks, pushed to mmc-next and queued as a .38 fix.
Signature · 2 lines
Chris Ball <[email protected]> <http://printf.net/> One Laptop Per Child
PATCH 1/1 MMCI: don't read command response when invalid
Quoted 36 lines · Chris Ball
Hi,
Quoted 33 lines · Russell King - ARM Linux
Don't read the command response from the registers when either the command timed out (because there was no response from the card) or the checksum on the response was invalid.
Signed-off-by Russell King <[email protected]>--- drivers/mmc/host/mmci.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)drivers/mmc/host/mmci.c +5
-5@@ -394,15 +394,15 @@ mmci_cmd_irq(struct mmci_host *host, struct mmc_command *cmd, host->cmd =NULL ; - cmd->resp[0 ] =readl (base +MMCIRESPONSE0 ); - cmd->resp[1 ] =readl (base +MMCIRESPONSE1 ); - cmd->resp[2 ] =readl (base +MMCIRESPONSE2 ); - cmd->resp[3 ] =readl (base +MMCIRESPONSE3 ); -if (status &MCI_CMDTIMEOUT ) { cmd->error = -ETIMEDOUT ; }else if (status &MCI_CMDCRCFAIL && cmd->flags &MMC_RSP_CRC ) { cmd->error = -EILSEQ ; + }else { + cmd->resp[0 ] =readl (base +MMCIRESPONSE0 ); + cmd->resp[1 ] =readl (base +MMCIRESPONSE1 ); + cmd->resp[2 ] =readl (base +MMCIRESPONSE2 ); + cmd->resp[3 ] =readl (base +MMCIRESPONSE3 ); }
Quoted 3 lines
drivers/mmc/host/mmci.c mmci_cmd_irq(struct mmci_host *host, struct mmc_command *cmd, · line 408
Quoted 1 line
drivers/mmc/host/mmci.c +0
-0if (!cmd->data || cmd->error) {Thanks, pushed to mmc-next and queued as a .38 fix.
FYI, I've now merged this into the ARM devel tree for the time being so it doesn't get forgotten - which means it'll appear in linux-next at some point if it isn't already there. (Mainly so I don't have to keep on adding the patch.)
Once you push it into mainline, I'll drop my copy.
PATCH 1/1 MMCI: don't read command response when invalid
Hi Russell,
Quoted 6 lines · Russell King - ARM Linux
FYI, I've now merged this into the ARM devel tree for the time being so it doesn't get forgotten - which means it'll appear in linux-next at some point if it isn't already there. (Mainly so I don't have to keep on adding the patch.)
Once you push it into mainline, I'll drop my copy.
Okay. Sent this to Linus yesterday, just waiting for him to pull. (It's been in linux-next for the last two weeks.)
Thanks,
Signature · 2 lines
Chris Ball <[email protected]> <http://printf.net/> One Laptop Per Child
PATCH 1/1 MMCI: don't read command response when invalid
Quoted 8 lines · Chris Ball
Hi Russell,
Quoted 5 lines · Russell King - ARM Linux
FYI, I've now merged this into the ARM devel tree for the time being so it doesn't get forgotten - which means it'll appear in linux-next at some point if it isn't already there. (Mainly so I don't have to keep on adding the patch.)
Quoted 4 lines
Quoted 1 line
Once you push it into mainline, I'll drop my copy.
Okay. Sent this to Linus yesterday, just waiting for him to pull. (It's been in linux-next for the last two weeks.)
It's present in mainline now.
Signature · 2 lines
Chris Ball <[email protected]> <http://printf.net/> One Laptop Per Child
PATCH 1/1 MMCI: don't read command response when invalid
Quoted 9 lines · Chris Ball
Quoted 8 lines · Chris Ball
Hi Russell,
Quoted 5 lines · Russell King - ARM Linux
FYI, I've now merged this into the ARM devel tree for the time being so it doesn't get forgotten - which means it'll appear in linux-next at some point if it isn't already there. (Mainly so I don't have to keep on adding the patch.)
Quoted 6 lines
Quoted 4 lines
Quoted 1 line
Once you push it into mainline, I'll drop my copy.
Okay. Sent this to Linus yesterday, just waiting for him to pull. (It's been in linux-next for the last two weeks.)
It's present in mainline now.
Thanks, dropped from my tree now.