From patchwork Wed Sep 3 10:52:24 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 36553 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ie0-f199.google.com (mail-ie0-f199.google.com [209.85.223.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id DA3892039B for ; Wed, 3 Sep 2014 10:53:08 +0000 (UTC) Received: by mail-ie0-f199.google.com with SMTP id tr6sf43647976ieb.2 for ; Wed, 03 Sep 2014 03:53:08 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version: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=xJn/o3LKN+hYIfOn/5Y9YIJaGHVLM1cNjsuPmSvsHCE=; b=KBqF0wi19+pTT8dD+Lm7Azyyxc7rMON1tIvhhLjFRKb/zyVgqY9nEi98QSw/oxTyAU l5liOPbkn6OvuAvhl7MrXL6TCo8kaaTIYvwPe8n2tjINcT2UNcj4RW/QBtPZVVFpKbhW 2GbrsChE7elRVgKkvJY7J01utXRJ0InW/VITPczQ38goWRr6rpHq0nBBt3w7QsN3Mr6L WN+8ti4v7fZ+Nj9nHo5ozH1PISuhBuD/AGmRMOiER78PLE1+kCppH34mLmb80m5ttha2 wIIVMTrL1Sz2WV97O4KHMd8bSUQTVNux7TV7hYYEnjxTdYY0YDtMqeZiI1ek9EOhwvtg YUMg== X-Gm-Message-State: ALoCoQnxBxVV1Rabx9QnQGYtc5pR2ylh2X8vR2ECy98Pf9IhFytJ7hutneItCYAAHiTlhd9r+Lws X-Received: by 10.42.152.201 with SMTP id j9mr23684238icw.5.1409741588472; Wed, 03 Sep 2014 03:53:08 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.82.75 with SMTP id g69ls2675816qgd.53.gmail; Wed, 03 Sep 2014 03:53:08 -0700 (PDT) X-Received: by 10.52.119.229 with SMTP id kx5mr4264075vdb.40.1409741588368; Wed, 03 Sep 2014 03:53:08 -0700 (PDT) Received: from mail-vc0-f179.google.com (mail-vc0-f179.google.com [209.85.220.179]) by mx.google.com with ESMTPS id s10si674553vdv.68.2014.09.03.03.53.08 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 03 Sep 2014 03:53:08 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.179 as permitted sender) client-ip=209.85.220.179; Received: by mail-vc0-f179.google.com with SMTP id hy4so8641740vcb.10 for ; Wed, 03 Sep 2014 03:53:08 -0700 (PDT) X-Received: by 10.220.182.1 with SMTP id ca1mr34388189vcb.21.1409741588295; Wed, 03 Sep 2014 03:53:08 -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.221.45.67 with SMTP id uj3csp660742vcb; Wed, 3 Sep 2014 03:53:07 -0700 (PDT) X-Received: by 10.194.184.101 with SMTP id et5mr46668549wjc.14.1409741587413; Wed, 03 Sep 2014 03:53:07 -0700 (PDT) Received: from mail-wg0-f43.google.com (mail-wg0-f43.google.com [74.125.82.43]) by mx.google.com with ESMTPS id wi8si9711902wjc.169.2014.09.03.03.53.07 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 03 Sep 2014 03:53:07 -0700 (PDT) Received-SPF: pass (google.com: domain of ulf.hansson@linaro.org designates 74.125.82.43 as permitted sender) client-ip=74.125.82.43; Received: by mail-wg0-f43.google.com with SMTP id a1so8277176wgh.14 for ; Wed, 03 Sep 2014 03:53:07 -0700 (PDT) X-Received: by 10.194.81.37 with SMTP id w5mr46970629wjx.12.1409741586985; Wed, 03 Sep 2014 03:53:06 -0700 (PDT) Received: from localhost.localdomain ([85.235.11.236]) by mx.google.com with ESMTPSA id j7sm3968190wia.9.2014.09.03.03.53.05 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 03 Sep 2014 03:53:06 -0700 (PDT) From: Ulf Hansson To: "Rafael J. Wysocki" , Len Brown , Pavel Machek , linux-pm@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, linux-sh@vger.kernel.org, linux-samsung-soc@vger.kernel.org, Geert Uytterhoeven , Kevin Hilman , Daniel Lezcano , Tomasz Figa , Simon Horman , Magnus Damm , Ben Dooks , Kukjin Kim , Stephen Boyd , Philipp Zabel , Mark Brown , Ulf Hansson Subject: [PATCH 08/15] PM / Domains: Remove pm_genpd_syscore_switch() API Date: Wed, 3 Sep 2014 12:52:24 +0200 Message-Id: <1409741551-16437-9-git-send-email-ulf.hansson@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1409741551-16437-1-git-send-email-ulf.hansson@linaro.org> References: <1409741551-16437-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=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.179 as permitted sender) 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: , The pm_genpd_syscore_poweroff() API and pm_genpd_syscore_poweron() API makes the pm_genpd_syscore_switch() API redundant. Moreover, since there are no active users, let's just remove it. Signed-off-by: Ulf Hansson --- drivers/base/power/domain.c | 17 ++++++++++++++--- include/linux/pm_domain.h | 16 ++++------------ 2 files changed, 18 insertions(+), 15 deletions(-) diff --git a/drivers/base/power/domain.c b/drivers/base/power/domain.c index b910d0f..601e35b 100644 --- a/drivers/base/power/domain.c +++ b/drivers/base/power/domain.c @@ -1292,13 +1292,13 @@ static void pm_genpd_complete(struct device *dev) } /** - * pm_genpd_syscore_switch - Switch power during system core suspend or resume. + * genpd_syscore_switch - Switch power during system core suspend or resume. * @dev: Device that normally is marked as "always on" to switch power for. * * This routine may only be called during the system core (syscore) suspend or * resume phase for devices whose "always on" flags are set. */ -void pm_genpd_syscore_switch(struct device *dev, bool suspend) +static void genpd_syscore_switch(struct device *dev, bool suspend) { struct generic_pm_domain *genpd; @@ -1314,7 +1314,18 @@ void pm_genpd_syscore_switch(struct device *dev, bool suspend) genpd->suspended_count--; } } -EXPORT_SYMBOL_GPL(pm_genpd_syscore_switch); + +void pm_genpd_syscore_poweroff(struct device *dev) +{ + genpd_syscore_switch(dev, true); +} +EXPORT_SYMBOL_GPL(pm_genpd_syscore_poweroff); + +void pm_genpd_syscore_poweron(struct device *dev) +{ + genpd_syscore_switch(dev, false); +} +EXPORT_SYMBOL_GPL(pm_genpd_syscore_poweron); #else diff --git a/include/linux/pm_domain.h b/include/linux/pm_domain.h index f2545a8..eeba1a4 100644 --- a/include/linux/pm_domain.h +++ b/include/linux/pm_domain.h @@ -266,19 +266,11 @@ static inline void pm_genpd_poweroff_unused(void) {} #endif #ifdef CONFIG_PM_GENERIC_DOMAINS_SLEEP -extern void pm_genpd_syscore_switch(struct device *dev, bool suspend); +extern void pm_genpd_syscore_poweroff(struct device *dev); +extern void pm_genpd_syscore_poweron(struct device *dev); #else -static inline void pm_genpd_syscore_switch(struct device *dev, bool suspend) {} +static inline void pm_genpd_syscore_poweroff(struct device *dev) {} +static inline void pm_genpd_syscore_poweron(struct device *dev) {} #endif -static inline void pm_genpd_syscore_poweroff(struct device *dev) -{ - pm_genpd_syscore_switch(dev, true); -} - -static inline void pm_genpd_syscore_poweron(struct device *dev) -{ - pm_genpd_syscore_switch(dev, false); -} - #endif /* _LINUX_PM_DOMAIN_H */