From patchwork Wed Oct 2 08:30:46 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 20741 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vc0-f199.google.com (mail-vc0-f199.google.com [209.85.220.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 277D125E05 for ; Wed, 2 Oct 2013 08:31:04 +0000 (UTC) Received: by mail-vc0-f199.google.com with SMTP id lf12sf990751vcb.10 for ; Wed, 02 Oct 2013 01:31:03 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=mime-version:x-gm-message-state:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=JjjLgYq6aGcCgk4AsnQ9NFdJCVPIlvIGdykSwuyz/bM=; b=RNkUE5esJ5zD3i4Vcr/2dht4s3Sl4p4+q5oirHX+MOSYmGs9cxGtY8xP640zNqIyKw RAMHg5vvv/7uA3iyP4qxreg7506890CEMcR7hOYZjE2viD3mViPTafjd3iPHH0y8bRne sjLIC3ML96PtFwQFNcMxk0DndoE+Z4xAE6L6UemlrKm7qRy76KQoCPy+bFPBVq2HGALG 29bRkJ401L5Us2lR5HvUZiLJkIRJ5GBxWo6SrmbE3ocErpJry+b2D0VRKthggFIDuTa8 3V0XnalUAaRhZtP52D/DPFLVMObbyO951SMjHpqYgvuLXVY5MebfdOC+Zn1huCTtXMSD hEIQ== X-Received: by 10.236.116.135 with SMTP id g7mr1052932yhh.53.1380702663672; Wed, 02 Oct 2013 01:31:03 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.99.67 with SMTP id eo3ls380466qeb.41.gmail; Wed, 02 Oct 2013 01:31:03 -0700 (PDT) X-Received: by 10.52.32.37 with SMTP id f5mr745310vdi.17.1380702663502; Wed, 02 Oct 2013 01:31:03 -0700 (PDT) Received: from mail-ve0-f178.google.com (mail-ve0-f178.google.com [209.85.128.178]) by mx.google.com with ESMTPS id 10si93126vcr.78.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 02 Oct 2013 01:31:03 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.178 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.178; Received: by mail-ve0-f178.google.com with SMTP id jw12so312854veb.9 for ; Wed, 02 Oct 2013 01:31:03 -0700 (PDT) X-Gm-Message-State: ALoCoQls8LtjI1FrmUkSUtAqJsAA9JZIKhgLipNKjlZhTwDdAxFmn4cQ0+TBSNxg32KObamMaj5D X-Received: by 10.52.27.243 with SMTP id w19mr728200vdg.3.1380702663399; Wed, 02 Oct 2013 01:31:03 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp79361vcz; Wed, 2 Oct 2013 01:31:02 -0700 (PDT) X-Received: by 10.112.72.229 with SMTP id g5mr1320043lbv.10.1380702662333; Wed, 02 Oct 2013 01:31:02 -0700 (PDT) Received: from mail-lb0-f182.google.com (mail-lb0-f182.google.com [209.85.217.182]) by mx.google.com with ESMTPS id kk3si638555lbc.122.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 02 Oct 2013 01:31:02 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.217.182 is neither permitted nor denied by best guess record for domain of ulf.hansson@linaro.org) client-ip=209.85.217.182; Received: by mail-lb0-f182.google.com with SMTP id c11so453729lbj.41 for ; Wed, 02 Oct 2013 01:31:01 -0700 (PDT) X-Received: by 10.152.170.166 with SMTP id an6mr1000657lac.20.1380702661514; Wed, 02 Oct 2013 01:31:01 -0700 (PDT) Received: from linaro-ulf.lan (90-231-160-185-no158.tbcn.telia.com. [90.231.160.185]) by mx.google.com with ESMTPSA id e4sm890041lba.15.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 02 Oct 2013 01:31:00 -0700 (PDT) From: Ulf Hansson To: linux-mmc@vger.kernel.org, Chris Ball Cc: Ulf Hansson , Guennadi Liakhovetski Subject: [PATCH 2/7] mmc: sh_mmcif: Convert to PM macros when defining dev_pm_ops Date: Wed, 2 Oct 2013 10:30:46 +0200 Message-Id: <1380702651-13389-3-git-send-email-ulf.hansson@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1380702651-13389-1-git-send-email-ulf.hansson@linaro.org> References: <1380702651-13389-1-git-send-email-ulf.hansson@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: ulf.hansson@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.178 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Use SET_SYSTEM_SLEEP_PM_OPS to simplify code. Cc: Guennadi Liakhovetski Signed-off-by: Ulf Hansson --- drivers/mmc/host/sh_mmcif.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/drivers/mmc/host/sh_mmcif.c b/drivers/mmc/host/sh_mmcif.c index 6bffebe..32bc412 100644 --- a/drivers/mmc/host/sh_mmcif.c +++ b/drivers/mmc/host/sh_mmcif.c @@ -1538,7 +1538,7 @@ static int sh_mmcif_remove(struct platform_device *pdev) return 0; } -#ifdef CONFIG_PM +#ifdef CONFIG_PM_SLEEP static int sh_mmcif_suspend(struct device *dev) { struct sh_mmcif_host *host = dev_get_drvdata(dev); @@ -1552,10 +1552,7 @@ static int sh_mmcif_resume(struct device *dev) { return 0; } -#else -#define sh_mmcif_suspend NULL -#define sh_mmcif_resume NULL -#endif /* CONFIG_PM */ +#endif static const struct of_device_id mmcif_of_match[] = { { .compatible = "renesas,sh-mmcif" }, @@ -1564,8 +1561,7 @@ static const struct of_device_id mmcif_of_match[] = { MODULE_DEVICE_TABLE(of, mmcif_of_match); static const struct dev_pm_ops sh_mmcif_dev_pm_ops = { - .suspend = sh_mmcif_suspend, - .resume = sh_mmcif_resume, + SET_SYSTEM_SLEEP_PM_OPS(sh_mmcif_suspend, sh_mmcif_resume) }; static struct platform_driver sh_mmcif_driver = {