From patchwork Thu Sep 25 15:49:59 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 37926 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f69.google.com (mail-la0-f69.google.com [209.85.215.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 1A7B1202DB for ; Thu, 25 Sep 2014 15:52:28 +0000 (UTC) Received: by mail-la0-f69.google.com with SMTP id q1sf693629lam.8 for ; Thu, 25 Sep 2014 08:52:27 -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:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=7zPXJdTCW0dDNH/BEAFyKa+eti+qGacVj2YV6anvZak=; b=SQAUDRWg5j1wkshkHsn0wMhD7yb1d2egvpar3wITxtmPFvMcpO9fuOQ4+35snV2vJu RMSUktNHlHvgC+Rbc2NXsRRSqlX/Lc7omf+JCAYbvJDQnJhmdvV7lcwdn0JC5kAuplsM PVEFR/a4DEbl7XJ9eCCoX8tzL0LExiHOW+Sbwny4lvUoTbShLsigZvGxlz7Y7F6VCOkZ G4DMyc93C2ETnmhzO/eLRtVfqWlXDAgKsVd4Fx1bWYknflyU4WYU/bgM7Sfpv6Tp0rU9 YmQU0rifnUg6I/6JCKs4wrwFdSpRSiM9VeKHv2o0FAZIMCwjHASXfwVC1pRIq0f+ZjMf 6mdg== X-Gm-Message-State: ALoCoQl6sA9dkvUBdXoie6AA4jO2BZNvzi+B+7mE2uuHohQ6jMRK1EDmkezldA6JPP3P2Iunywyx X-Received: by 10.194.3.19 with SMTP id 19mr40572wjy.5.1411660347834; Thu, 25 Sep 2014 08:52:27 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.42.171 with SMTP id p11ls246421lal.68.gmail; Thu, 25 Sep 2014 08:52:27 -0700 (PDT) X-Received: by 10.112.43.108 with SMTP id v12mr9603157lbl.43.1411660347609; Thu, 25 Sep 2014 08:52:27 -0700 (PDT) Received: from mail-lb0-f179.google.com (mail-lb0-f179.google.com [209.85.217.179]) by mx.google.com with ESMTPS id u14si3575024lal.70.2014.09.25.08.52.27 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 25 Sep 2014 08:52:27 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.179 as permitted sender) client-ip=209.85.217.179; Received: by mail-lb0-f179.google.com with SMTP id 10so12390907lbg.10 for ; Thu, 25 Sep 2014 08:52:27 -0700 (PDT) X-Received: by 10.152.204.231 with SMTP id lb7mr14139256lac.44.1411660347547; Thu, 25 Sep 2014 08:52:27 -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.112.130.169 with SMTP id of9csp775042lbb; Thu, 25 Sep 2014 08:52:27 -0700 (PDT) X-Received: by 10.180.211.197 with SMTP id ne5mr20529314wic.29.1411660346970; Thu, 25 Sep 2014 08:52:26 -0700 (PDT) Received: from mail-we0-f171.google.com (mail-we0-f171.google.com [74.125.82.171]) by mx.google.com with ESMTPS id br6si3134536wjc.156.2014.09.25.08.52.26 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 25 Sep 2014 08:52:26 -0700 (PDT) Received-SPF: pass (google.com: domain of ulf.hansson@linaro.org designates 74.125.82.171 as permitted sender) client-ip=74.125.82.171; Received: by mail-we0-f171.google.com with SMTP id k48so8240967wev.16 for ; Thu, 25 Sep 2014 08:52:26 -0700 (PDT) X-Received: by 10.180.98.227 with SMTP id el3mr20560747wib.13.1411660346692; Thu, 25 Sep 2014 08:52:26 -0700 (PDT) Received: from localhost.localdomain ([85.235.11.236]) by mx.google.com with ESMTPSA id f7sm3572256wix.22.2014.09.25.08.52.25 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 25 Sep 2014 08:52:25 -0700 (PDT) From: Ulf Hansson To: "Rafael J. Wysocki" , Len Brown , Pavel Machek , linux-pm@vger.kernel.org Cc: Geert Uytterhoeven , Kevin Hilman , Tomasz Figa , Philipp Zabel , Ulf Hansson Subject: [PATCH] PM / Domains: Remove legacy API for adding devices through DT Date: Thu, 25 Sep 2014 17:49:59 +0200 Message-Id: <1411660199-2022-1-git-send-email-ulf.hansson@linaro.org> X-Mailer: git-send-email 1.9.1 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.217.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: , There are no active clients of the legacy API and we now also have a better way to handle genpd DT support. So let's remove the legacy API. Signed-off-by: Ulf Hansson Acked-by: Geert Uytterhoeven Acked-by: Kevin Hilman --- drivers/base/power/domain.c | 33 --------------------------------- include/linux/pm_domain.h | 17 ----------------- 2 files changed, 50 deletions(-) diff --git a/drivers/base/power/domain.c b/drivers/base/power/domain.c index cd40057..8ba04cd 100644 --- a/drivers/base/power/domain.c +++ b/drivers/base/power/domain.c @@ -1454,39 +1454,6 @@ int __pm_genpd_add_device(struct generic_pm_domain *genpd, struct device *dev, } /** - * __pm_genpd_of_add_device - Add a device to an I/O PM domain. - * @genpd_node: Device tree node pointer representing a PM domain to which the - * the device is added to. - * @dev: Device to be added. - * @td: Set of PM QoS timing parameters to attach to the device. - */ -int __pm_genpd_of_add_device(struct device_node *genpd_node, struct device *dev, - struct gpd_timing_data *td) -{ - struct generic_pm_domain *genpd = NULL, *gpd; - - dev_dbg(dev, "%s()\n", __func__); - - if (IS_ERR_OR_NULL(genpd_node) || IS_ERR_OR_NULL(dev)) - return -EINVAL; - - mutex_lock(&gpd_list_lock); - list_for_each_entry(gpd, &gpd_list, gpd_list_node) { - if (gpd->of_node == genpd_node) { - genpd = gpd; - break; - } - } - mutex_unlock(&gpd_list_lock); - - if (!genpd) - return -EINVAL; - - return __pm_genpd_add_device(genpd, dev, td); -} - - -/** * __pm_genpd_name_add_device - Find I/O PM domain and add a device to it. * @domain_name: Name of the PM domain to add the device to. * @dev: Device to be added. diff --git a/include/linux/pm_domain.h b/include/linux/pm_domain.h index 292079d..c3763a3 100644 --- a/include/linux/pm_domain.h +++ b/include/linux/pm_domain.h @@ -71,7 +71,6 @@ struct generic_pm_domain { s64 max_off_time_ns; /* Maximum allowed "suspended" time. */ bool max_off_time_changed; bool cached_power_down_ok; - struct device_node *of_node; /* Node in device tree */ struct gpd_cpu_data *cpu_data; }; @@ -122,10 +121,6 @@ extern int __pm_genpd_add_device(struct generic_pm_domain *genpd, struct device *dev, struct gpd_timing_data *td); -extern int __pm_genpd_of_add_device(struct device_node *genpd_node, - struct device *dev, - struct gpd_timing_data *td); - extern int __pm_genpd_name_add_device(const char *domain_name, struct device *dev, struct gpd_timing_data *td); @@ -167,12 +162,6 @@ static inline int __pm_genpd_add_device(struct generic_pm_domain *genpd, { return -ENOSYS; } -static inline int __pm_genpd_of_add_device(struct device_node *genpd_node, - struct device *dev, - struct gpd_timing_data *td) -{ - return -ENOSYS; -} static inline int __pm_genpd_name_add_device(const char *domain_name, struct device *dev, struct gpd_timing_data *td) @@ -238,12 +227,6 @@ static inline int pm_genpd_add_device(struct generic_pm_domain *genpd, return __pm_genpd_add_device(genpd, dev, NULL); } -static inline int pm_genpd_of_add_device(struct device_node *genpd_node, - struct device *dev) -{ - return __pm_genpd_of_add_device(genpd_node, dev, NULL); -} - static inline int pm_genpd_name_add_device(const char *domain_name, struct device *dev) {