forked from mirrors/linux
		
	mmc: sdio: fully reconfigure oldcard on resume
On resume, let mmc_sdio_init_card go all the way, instead of skipping the reconfiguration of the card's speed and width. This is needed to ensure cards wake up with their clock reconfigured (otherwise it's kept low). This patch also removes the explicit bus width reconfiguration on resume, since now this is part of mmc_sdio_init_card. Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com> Tested-by: Luciano Coelho <luciano.coelho@nokia.com> Signed-off-by: Chris Ball <cjb@laptop.org>
This commit is contained in:
		
							parent
							
								
									1978fda85d
								
							
						
					
					
						commit
						9b966aae64
					
				
					 1 changed files with 0 additions and 9 deletions
				
			
		| 
						 | 
					@ -456,7 +456,6 @@ static int mmc_sdio_init_card(struct mmc_host *host, u32 ocr,
 | 
				
			||||||
			return -ENOENT;
 | 
								return -ENOENT;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		card = oldcard;
 | 
							card = oldcard;
 | 
				
			||||||
		return 0;
 | 
					 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (card->type == MMC_TYPE_SD_COMBO) {
 | 
						if (card->type == MMC_TYPE_SD_COMBO) {
 | 
				
			||||||
| 
						 | 
					@ -614,14 +613,6 @@ static int mmc_sdio_resume(struct mmc_host *host)
 | 
				
			||||||
	mmc_claim_host(host);
 | 
						mmc_claim_host(host);
 | 
				
			||||||
	err = mmc_sdio_init_card(host, host->ocr, host->card,
 | 
						err = mmc_sdio_init_card(host, host->ocr, host->card,
 | 
				
			||||||
				 (host->pm_flags & MMC_PM_KEEP_POWER));
 | 
									 (host->pm_flags & MMC_PM_KEEP_POWER));
 | 
				
			||||||
	if (!err) {
 | 
					 | 
				
			||||||
		/* We may have switched to 1-bit mode during suspend. */
 | 
					 | 
				
			||||||
		err = sdio_enable_4bit_bus(host->card);
 | 
					 | 
				
			||||||
		if (err > 0) {
 | 
					 | 
				
			||||||
			mmc_set_bus_width(host, MMC_BUS_WIDTH_4);
 | 
					 | 
				
			||||||
			err = 0;
 | 
					 | 
				
			||||||
		}
 | 
					 | 
				
			||||||
	}
 | 
					 | 
				
			||||||
	if (!err && host->sdio_irqs)
 | 
						if (!err && host->sdio_irqs)
 | 
				
			||||||
		mmc_signal_sdio_irq(host);
 | 
							mmc_signal_sdio_irq(host);
 | 
				
			||||||
	mmc_release_host(host);
 | 
						mmc_release_host(host);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue