From patchwork Tue Dec 7 23:27:30 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Walmsley X-Patchwork-Id: 384642 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id oB7NNTdr003652 for ; Tue, 7 Dec 2010 23:27:32 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753412Ab0LGX1c (ORCPT ); Tue, 7 Dec 2010 18:27:32 -0500 Received: from utopia.booyaka.com ([72.9.107.138]:43882 "EHLO utopia.booyaka.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752964Ab0LGX1b (ORCPT ); Tue, 7 Dec 2010 18:27:31 -0500 Received: (qmail 20907 invoked by uid 1019); 7 Dec 2010 23:27:30 -0000 Date: Tue, 7 Dec 2010 16:27:30 -0700 (MST) From: Paul Walmsley To: Madhusudhan Chikkature Rajashekar , Adrian Hunter , linux-mmc@vger.kernel.org cc: Kishore Kadiyala , Tero Kristo , linux-omap@vger.kernel.org Subject: [PATCH] MMC: omap_hsmmc: enable interface clock before calling mmc_host_enable() Message-ID: User-Agent: Alpine 2.00 (DEB 1167 2008-08-23) MIME-Version: 1.0 Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Tue, 07 Dec 2010 23:27:32 +0000 (UTC) diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c index 5d46021..58a2c5e 100644 --- a/drivers/mmc/host/omap_hsmmc.c +++ b/drivers/mmc/host/omap_hsmmc.c @@ -2101,14 +2101,14 @@ static int __init omap_hsmmc_probe(struct platform_device *pdev) /* we start off in DISABLED state */ host->dpm_state = DISABLED; - if (mmc_host_enable(host->mmc) != 0) { + if (clk_enable(host->iclk) != 0) { clk_put(host->iclk); clk_put(host->fclk); goto err1; } - if (clk_enable(host->iclk) != 0) { - mmc_host_disable(host->mmc); + if (mmc_host_enable(host->mmc) != 0) { + clk_disable(host->iclk); clk_put(host->iclk); clk_put(host->fclk); goto err1;