From patchwork Fri Oct 7 22:36:57 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lina Iyer X-Patchwork-Id: 77363 Delivered-To: patch@linaro.org Received: by 10.140.97.247 with SMTP id m110csp438607qge; Fri, 7 Oct 2016 15:37:20 -0700 (PDT) X-Received: by 10.98.93.25 with SMTP id r25mr39873528pfb.119.1475879840667; Fri, 07 Oct 2016 15:37:20 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j23si10235837pfj.74.2016.10.07.15.37.20; Fri, 07 Oct 2016 15:37:20 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-pm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of linux-pm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-pm-owner@vger.kernel.org; dmarc=fail (p=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754476AbcJGWhT (ORCPT + 14 others); Fri, 7 Oct 2016 18:37:19 -0400 Received: from mail-pf0-f170.google.com ([209.85.192.170]:32854 "EHLO mail-pf0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753735AbcJGWhS (ORCPT ); Fri, 7 Oct 2016 18:37:18 -0400 Received: by mail-pf0-f170.google.com with SMTP id 190so29408003pfv.0 for ; Fri, 07 Oct 2016 15:37:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=XeNeHiIb8YlGRtSaCapfJW2tnTVAOayY4SR0HnnvKJw=; b=f19fw2X1E/r/b0mBhgOPseY469o8M1fvT8B9faNUOi5tkwoIanxm60DU+l3Fyn2k9v 2eg9+mokBihIXVSv0te8Meh89+dCM2jEd616Umnn1PEjHlkDMB/VIRGshgSgiNDOnRsJ KBg/Jzh+Hsi3T92T22sgumRBpkDyb6Mas4jcU= 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=XeNeHiIb8YlGRtSaCapfJW2tnTVAOayY4SR0HnnvKJw=; b=dY9d4G16/+o21tRJq/FZoGtH/FWr7DRn8Db4Pt21K7TYlLpHGlIw94DWcbAFZZgiu9 1gZ5ErJz2wqCrDb6zVqoS4DTMLA3Ue/LCCLJDwVkjUf2BA133QdzWyzh2o6MvvdG14YX OEQuYg+h3B0gtHO715kAjWLnVjDc7qmcNxgPylC5CrVp636lU62W2jnu3iWh1hrDVCz8 Ke+Kc7YO17nxP5FLuojWzISALkLwpVwOOn7EfYPvmbBIxdmvjGmvQycbxicHkWP+ZraQ E6WCrPFLOCHg9i2N63t6haV1+uFXA4PNtljhZTLoBYWNRbzpWs+7+c88J1iF2ZxRUt24 rjYQ== X-Gm-Message-State: AA6/9RmSQrEL+ktOoF/jpPhSun0zDdSKEDgIFZlbw6T8ECOIhE6D94noRNIlVTlNMLyZF/Vn X-Received: by 10.98.2.215 with SMTP id 206mr31700158pfc.89.1475879837681; Fri, 07 Oct 2016 15:37:17 -0700 (PDT) Received: from ubuntu.localdomain (i-global254.qualcomm.com. [199.106.103.254]) by smtp.gmail.com with ESMTPSA id 4sm16409203pfw.90.2016.10.07.15.37.15 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 07 Oct 2016 15:37:16 -0700 (PDT) From: Lina Iyer To: ulf.hansson@linaro.org, khilman@kernel.org, rjw@rjwysocki.net, linux-pm@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: andy.gross@linaro.org, sboyd@codeaurora.org, linux-arm-msm@vger.kernel.org, brendan.jackman@arm.com, lorenzo.pieralisi@arm.com, sudeep.holla@arm.com, Juri.Lelli@arm.com, Lina Iyer Subject: [PATCH v2 4/8] PM / Domains: Save the fwnode in genpd_power_state Date: Fri, 7 Oct 2016 15:36:57 -0700 Message-Id: <1475879821-8035-5-git-send-email-lina.iyer@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1475879821-8035-1-git-send-email-lina.iyer@linaro.org> References: <1475879821-8035-1-git-send-email-lina.iyer@linaro.org> Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org Save the fwnode for the genpd state in the state node. PM Domain clients may use the fwnode to read in the platform specific domain state properties and associate them with the state. Signed-off-by: Lina Iyer --- drivers/base/power/domain.c | 1 + include/linux/pm_domain.h | 1 + 2 files changed, 2 insertions(+) -- 2.7.4 -- To unsubscribe from this list: send the line "unsubscribe linux-pm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/base/power/domain.c b/drivers/base/power/domain.c index 4208b67..e0f31fe 100644 --- a/drivers/base/power/domain.c +++ b/drivers/base/power/domain.c @@ -1957,6 +1957,7 @@ static int genpd_parse_state(struct genpd_power_state *genpd_state, genpd_state->power_on_latency_ns = 1000 * exit_latency; genpd_state->power_off_latency_ns = 1000 * entry_latency; + genpd_state->fwnode = &state_node->fwnode; return 0; } diff --git a/include/linux/pm_domain.h b/include/linux/pm_domain.h index b489496..6a89881 100644 --- a/include/linux/pm_domain.h +++ b/include/linux/pm_domain.h @@ -39,6 +39,7 @@ struct genpd_power_state { s64 power_off_latency_ns; s64 power_on_latency_ns; s64 residency_ns; + struct fwnode_handle *fwnode; }; struct generic_pm_domain {