From patchwork Mon Aug 9 16:58:18 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mathieu Poirier X-Patchwork-Id: 61293 X-Patchwork-Delegate: leann.ogasawara@canonical.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from chlorine.canonical.com (chlorine.canonical.com [91.189.94.204]) by ozlabs.org (Postfix) with ESMTP id 167C7B6F06 for ; Tue, 10 Aug 2010 02:58:34 +1000 (EST) Received: from localhost ([127.0.0.1] helo=chlorine.canonical.com) by chlorine.canonical.com with esmtp (Exim 4.69) (envelope-from ) id 1OiVg6-0003Lx-A1; Mon, 09 Aug 2010 17:58:22 +0100 Received: from adelie.canonical.com ([91.189.90.139]) by chlorine.canonical.com with esmtp (Exim 4.69) (envelope-from ) id 1OiVg5-0003LS-2m for kernel-team@lists.ubuntu.com; Mon, 09 Aug 2010 17:58:21 +0100 Received: from hutte.canonical.com ([91.189.90.181]) by adelie.canonical.com with esmtp (Exim 4.69 #1 (Debian)) id 1OiVg5-0001xg-0I for ; Mon, 09 Aug 2010 17:58:21 +0100 Received: from s0106002369de4dac.cg.shawcable.net ([70.73.24.112] helo=[192.168.1.100]) by hutte.canonical.com with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1OiVg4-00035Q-Kj for kernel-team@lists.ubuntu.com; Mon, 09 Aug 2010 17:58:20 +0100 Subject: [Maverick] [PATCH] UBUNTU - ARM: Reverting patch that break mmc init From: Mathieu Poirier To: kernel-team@lists.ubuntu.com Date: Mon, 09 Aug 2010 10:58:18 -0600 Message-ID: <1281373098.32137.26.camel@black> Mime-Version: 1.0 X-Mailer: Evolution 2.28.3 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.9 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kernel-team-bounces@lists.ubuntu.com Errors-To: kernel-team-bounces@lists.ubuntu.com >From 7b666254b3b52989749916094629f3efc8d50a7b Mon Sep 17 00:00:00 2001 From: Mathieu J. Poirier Date: Mon, 9 Aug 2010 12:49:51 -0400 Subject: [PATCH] UBUNTU - ARM: Reverting patch that break mmc init This patch breaks mmc initialisation when the following flags are set: CONFIG_PREEMPT_VOLUNTARY CONFIG_CPU_FREQ CONFIG_CPU_IDLE CONFIG_SND_SOC. The power management subsystem will skip the card initialisation when power_mode is equal to "MMC_POWER_OFF", something that was done in the second portion of the patch. BugLink: https://bugs/launchpad.net/bugs/591941 Signed-off-by: Mathieu Poirier Revert "omap_hsmmc: Ensure regulator enable / disable are paired" This reverts commit 6da20c89af64b75302399369a90b9d50c1a87665. --- drivers/mmc/host/omap_hsmmc.c | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c index b032828..1c37d0d 100644 --- a/drivers/mmc/host/omap_hsmmc.c +++ b/drivers/mmc/host/omap_hsmmc.c @@ -297,8 +297,11 @@ static int omap_hsmmc_23_set_power(struct device *dev, int slot, int power_on, ret = mmc_regulator_set_ocr(host->vcc, 0); } } else { - if (host->vcc_aux) - ret = regulator_disable(host->vcc_aux); + if (host->vcc_aux) { + ret = regulator_is_enabled(host->vcc_aux); + if (ret > 0) + ret = regulator_disable(host->vcc_aux); + } if (ret == 0) ret = mmc_regulator_set_ocr(host->vcc, 0); } @@ -2010,7 +2013,7 @@ static int __init omap_hsmmc_probe(struct platform_device *pdev) host->slot_id = 0; host->mapbase = res->start; host->base = ioremap(host->mapbase, SZ_4K); - host->power_mode = MMC_POWER_OFF; + host->power_mode = -1; platform_set_drvdata(pdev, host); INIT_WORK(&host->mmc_carddetect_work, omap_hsmmc_detect);