From patchwork Thu Sep 26 14:54:33 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 2949041 Return-Path: X-Original-To: patchwork-linux-arm-msm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 3DB99BFF0B for ; Thu, 26 Sep 2013 15:02:00 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 970D6202E6 for ; Thu, 26 Sep 2013 15:01:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3A32320219 for ; Thu, 26 Sep 2013 15:01:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753674Ab3IZPBx (ORCPT ); Thu, 26 Sep 2013 11:01:53 -0400 Received: from mail-ea0-f180.google.com ([209.85.215.180]:64717 "EHLO mail-ea0-f180.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753045Ab3IZOz3 (ORCPT ); Thu, 26 Sep 2013 10:55:29 -0400 Received: by mail-ea0-f180.google.com with SMTP id h10so613352eaj.11 for ; Thu, 26 Sep 2013 07:55:28 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=u8Dx3gscJAwDd7+L7YwNxZPVTbeUajqcSndYbpP7vRM=; b=loyiV6lrq3mRQLo8xiC4jRPnrNe7cU0FUeYibw7PjcJOCw201duGaHJr0NPIZRGa/5 DH0wS1P85QiSVtGXI27aLVktDLmSDXNonFaZcIK/7aX4JE1MPoRijHgCXOOYGED2cIO3 pW4N6HL57zxLGSRtrjeh8x96XjYXpBcCuKie4UQ9iiHU3eRdag3FF1jrTtVxIRTzQSMl oYVN93dCQ8BBOvB89Bzzt9HmyTQhNQaj0QXeT0RW11APm+Wgu/B9UhzOO16qOE0BxrV1 hl68YvUBYXcQ1OgsYyjvP81P3IqnBZnaaKbbHCZHpvmr2ycEBsq2jFXFijAQOj/rF/sp mWrg== X-Gm-Message-State: ALoCoQmNY7wyIvidgwT6m4nM/8DCE4rShSDb/dx/r5XF55tCPn3sOXru/jGVLxMxMYSAqs+IsUIW X-Received: by 10.15.56.72 with SMTP id x48mr1399256eew.62.1380207327768; Thu, 26 Sep 2013 07:55:27 -0700 (PDT) Received: from localhost.localdomain ([85.235.11.236]) by mx.google.com with ESMTPSA id x47sm4813555eea.16.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 26 Sep 2013 07:55:26 -0700 (PDT) From: Ulf Hansson To: linux-kernel@vger.kernel.org, linux-mmc@vger.kernel.org, Chris Ball Cc: Ulf Hansson , David Brown , Daniel Walker , Bryan Huntsman , linux-arm-msm@vger.kernel.org Subject: [PATCH 08/27] mmc: msm_sdcc: Move away from using deprecated APIs Date: Thu, 26 Sep 2013 16:54:33 +0200 Message-Id: <1380207292-16968-9-git-send-email-ulf.hansson@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1380207292-16968-1-git-send-email-ulf.hansson@linaro.org> References: <1380207292-16968-1-git-send-email-ulf.hansson@linaro.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Spam-Status: No, score=-9.3 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Additionally, remove dead code which also used the deprecated APIs. Cc: David Brown Cc: Daniel Walker Cc: Bryan Huntsman Cc: linux-arm-msm@vger.kernel.org Signed-off-by: Ulf Hansson Acked-by: David Brown --- drivers/mmc/host/msm_sdcc.c | 27 ++------------------------- 1 file changed, 2 insertions(+), 25 deletions(-) diff --git a/drivers/mmc/host/msm_sdcc.c b/drivers/mmc/host/msm_sdcc.c index b900de4..9405ecd 100644 --- a/drivers/mmc/host/msm_sdcc.c +++ b/drivers/mmc/host/msm_sdcc.c @@ -1416,28 +1416,10 @@ ioremap_free: } #ifdef CONFIG_PM -#ifdef CONFIG_MMC_MSM7X00A_RESUME_IN_WQ -static void -do_resume_work(struct work_struct *work) -{ - struct msmsdcc_host *host = - container_of(work, struct msmsdcc_host, resume_task); - struct mmc_host *mmc = host->mmc; - - if (mmc) { - mmc_resume_host(mmc); - if (host->stat_irq) - enable_irq(host->stat_irq); - } -} -#endif - - static int msmsdcc_suspend(struct platform_device *dev, pm_message_t state) { struct mmc_host *mmc = mmc_get_drvdata(dev); - int rc = 0; if (mmc) { struct msmsdcc_host *host = mmc_priv(mmc); @@ -1445,14 +1427,11 @@ msmsdcc_suspend(struct platform_device *dev, pm_message_t state) if (host->stat_irq) disable_irq(host->stat_irq); - if (mmc->card && mmc->card->type != MMC_TYPE_SDIO) - rc = mmc_suspend_host(mmc); - if (!rc) - msmsdcc_writel(host, 0, MMCIMASK0); + msmsdcc_writel(host, 0, MMCIMASK0); if (host->clks_on) msmsdcc_disable_clocks(host, 0); } - return rc; + return 0; } static int @@ -1467,8 +1446,6 @@ msmsdcc_resume(struct platform_device *dev) msmsdcc_writel(host, host->saved_irq0mask, MMCIMASK0); - if (mmc->card && mmc->card->type != MMC_TYPE_SDIO) - mmc_resume_host(mmc); if (host->stat_irq) enable_irq(host->stat_irq); #if BUSCLK_PWRSAVE