mmc-omap: fix sd response type 6 vs. 1
Ignoring OMAP_MMC_STAT_CARD_ERR, treating it as if the command completed correctly. Signed-off-by: Ragner Magalhaes <ragner.magalhaes@indt.org.br> Signed-off-by: Carlos Eduardo Aguiar <carlos.aguiar@indt.org.br> Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
This commit is contained in:
		
							parent
							
								
									a0e1d1d075
								
							
						
					
					
						commit
						0107a4b32e
					
				@ -522,29 +522,11 @@ static irqreturn_t mmc_omap_irq(int irq, void *dev_id)
 | 
				
			|||||||
		}
 | 
							}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		if (status & OMAP_MMC_STAT_CARD_ERR) {
 | 
							if (status & OMAP_MMC_STAT_CARD_ERR) {
 | 
				
			||||||
			if (host->cmd && host->cmd->opcode == MMC_STOP_TRANSMISSION) {
 | 
								dev_dbg(mmc_dev(host->mmc),
 | 
				
			||||||
				u32 response = OMAP_MMC_READ(host, RSP6)
 | 
									"ignoring card status error (CMD%d)\n",
 | 
				
			||||||
					| (OMAP_MMC_READ(host, RSP7) << 16);
 | 
					 | 
				
			||||||
				/* STOP sometimes sets must-ignore bits */
 | 
					 | 
				
			||||||
				if (!(response & (R1_CC_ERROR
 | 
					 | 
				
			||||||
								| R1_ILLEGAL_COMMAND
 | 
					 | 
				
			||||||
								| R1_COM_CRC_ERROR))) {
 | 
					 | 
				
			||||||
					end_command = 1;
 | 
					 | 
				
			||||||
					continue;
 | 
					 | 
				
			||||||
				}
 | 
					 | 
				
			||||||
			}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
			dev_dbg(mmc_dev(host->mmc), "card status error (CMD%d)\n",
 | 
					 | 
				
			||||||
				host->cmd->opcode);
 | 
									host->cmd->opcode);
 | 
				
			||||||
			if (host->cmd) {
 | 
					 | 
				
			||||||
				host->cmd->error = MMC_ERR_FAILED;
 | 
					 | 
				
			||||||
			end_command = 1;
 | 
								end_command = 1;
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
			if (host->data) {
 | 
					 | 
				
			||||||
				host->data->error = MMC_ERR_FAILED;
 | 
					 | 
				
			||||||
				transfer_error = 1;
 | 
					 | 
				
			||||||
			}
 | 
					 | 
				
			||||||
		}
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
		/*
 | 
							/*
 | 
				
			||||||
		 * NOTE: On 1610 the END_OF_CMD may come too early when
 | 
							 * NOTE: On 1610 the END_OF_CMD may come too early when
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user