From patchwork Tue Oct 29 16:44:32 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 178038 Delivered-To: patches@linaro.org Received: by 2002:a92:409a:0:0:0:0:0 with SMTP id d26csp51923ill; Tue, 29 Oct 2019 09:44:55 -0700 (PDT) X-Received: by 2002:a19:9116:: with SMTP id t22mr1486415lfd.99.1572367495762; Tue, 29 Oct 2019 09:44:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1572367495; cv=none; d=google.com; s=arc-20160816; b=yfiTdSHtIAVKQDOEHaxZRp4JFCoANM2yDmLrWDSWOGwhmcacsmvDOZR0BAd9OPraba qMaoiRM09EXsyfV8pZzI9XsD/klytYabfscGg0DQNqyauFkdMJGIEqYkiGV+MI5xkOLO RFD//oNpuVT2fqrcSc9bkL2tvWpbGNMLWRWUf6IljQ3goNkktpD2mMrwI8AjwoWlD/W1 rh4XBGkBfgtqHith6K2+xrkgpoDIVwU10NqHyBQeQfUsbk4CNatGbFuKM8yMYK8Igm42 sQV3Wds8Cj/H95BRHaST0Z8L7jFOMlVOoL29keNsvdo4iSmQQDbw5f44VjYBrgEyZFCr COxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=s+efRcFDZJGrl94RZ1Pp04/eQynZO0t/87C0fALcC2Y=; b=pK9YqpVGGfeye4IgXNswEpPQcImu0AAOhDnHMfIuXflCfkYo29o6LUVZFQXM4F3TyY P9ksrVXlyUOfc6qAkIhcdOlcUBxyQ0VIvGYgShixLbPgyjkW2h2P6Lr/RO27D9nRDv26 miCx4UeqMuYsyiNcXbK87gWDmmtnAntirQuvgPohlOdafd453++y4+93JSwL3vXxi9nl VZatZ2GURwqswj3m08yJgjIFbMkffdMSe6LOXoJbhP9Nv/y7+NJOPbDnnBjcVJ/QZsGQ l5KhHwTxDv6FJd42LR73fC0DlfZav6ndfYvAGJwoA0zXryzHnT4sz6Ten2xvTvYqcY6a mKOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=DcR31P7Q; spf=pass (google.com: domain of ulf.hansson@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=ulf.hansson@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id j21sor8221597lja.9.2019.10.29.09.44.55 for (Google Transport Security); Tue, 29 Oct 2019 09:44:55 -0700 (PDT) Received-SPF: pass (google.com: domain of ulf.hansson@linaro.org designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=DcR31P7Q; spf=pass (google.com: domain of ulf.hansson@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=ulf.hansson@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org 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=s+efRcFDZJGrl94RZ1Pp04/eQynZO0t/87C0fALcC2Y=; b=DcR31P7QEhii748OfmlKLxnlgK2iGESy78LkihiAPNRBd1n02OkEbkB6oINN4qv153 TZWIg25uFuJM/ImzEcip1z0+uOBlD2R+kFXXfQp/SHkbrUMWd/e2Zl/onpraTJWE9Ls8 H2Q9VbbXEQZz/wZM7bMZZ8CQwqUSanG0Z8YL+jNcr553bfPAYUvitL4zl1S/7q2X6LJe KOSHCLV4B3XmapDudWjAZFt/kvcUofPfUHzDgFCkZu3gUi4zNcJ3wmT9EKsY1DhYkA/N dclq1M2EoW6vIFjlfsLh1UBG50Wbt0ZgUhFXluw/poNqBez/Afa9SFciz0phawg+sdlH Xmhw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=s+efRcFDZJGrl94RZ1Pp04/eQynZO0t/87C0fALcC2Y=; b=SxVtwuxNFjo60K4rCMNuu47rFF615s8qhiU07rT5ibLXtWefnkOAKABu4Sl55QIpZE btpo6dO5wUSgjQZ36M5MSOwBA/jA64iSvAUFYEBJQVTqAUclGrWwz3A5c9/kHhRqAyyw 8C0g2vkGgywSeZrxLfwwu9SJO81qKpJ6n2iMnsgFiySYIOqBEdRf5ITBC9uh8VGWrLm0 q+tBQaUx5DTwO6Q7JVHX/E3gZY0/T5hEXsEyHFJ8/jBPHS1Snoe/Qa6AhD81p2rM7NLL Pz1J+kU6JGa0bwvlg8rMV2xJEBn5jv1goO1L3d682MSErGpEfoE3vfTCztLgHec37jle Yj/A== X-Gm-Message-State: APjAAAV8kApujkpzz/IuZBEtsb8scPI2O58t7Ymq4pq/Qtyjc1KHoc4Q vQQEuCqcBUe2cTb/Nu03diBScnv7 X-Google-Smtp-Source: APXvYqzCWSq8jiTn+Qd/Sc5a5w9kGIAL/amfp/ZQemIsHNKP8bf8axa786VJsKcOJkE8woFSWOWH7w== X-Received: by 2002:a2e:9a96:: with SMTP id p22mr3274465lji.171.1572367495410; Tue, 29 Oct 2019 09:44:55 -0700 (PDT) Return-Path: Received: from localhost.localdomain (h-158-174-22-210.NA.cust.bahnhof.se. [158.174.22.210]) by smtp.gmail.com with ESMTPSA id f28sm2048161lfh.35.2019.10.29.09.44.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 29 Oct 2019 09:44:54 -0700 (PDT) From: Ulf Hansson To: "Rafael J . Wysocki" , Daniel Lezcano , Sudeep Holla , Lorenzo Pieralisi , Mark Rutland , Lina Iyer , linux-pm@vger.kernel.org Cc: Rob Herring , Vincent Guittot , Stephen Boyd , Andy Gross , Bjorn Andersson , Kevin Hilman , Ulf Hansson , linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org Subject: [PATCH v2 07/13] cpuidle: psci: Support hierarchical CPU idle states Date: Tue, 29 Oct 2019 17:44:32 +0100 Message-Id: <20191029164438.17012-8-ulf.hansson@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20191029164438.17012-1-ulf.hansson@linaro.org> References: <20191029164438.17012-1-ulf.hansson@linaro.org> Currently CPU's idle states are represented using the flattened model. Let's add support for the hierarchical layout, via converting to use of_get_cpu_state_node(). Signed-off-by: Ulf Hansson Reviewed-by: Sudeep Holla --- Changes in v2: - Added tags. --- drivers/cpuidle/cpuidle-psci.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) -- 2.17.1 diff --git a/drivers/cpuidle/cpuidle-psci.c b/drivers/cpuidle/cpuidle-psci.c index 761359be50f2..830995b8a56f 100644 --- a/drivers/cpuidle/cpuidle-psci.c +++ b/drivers/cpuidle/cpuidle-psci.c @@ -86,8 +86,7 @@ static int __init psci_dt_cpu_init_idle(struct device_node *cpu_node, return -ENOMEM; for (i = 1; i < state_count; i++) { - state_node = of_parse_phandle(cpu_node, "cpu-idle-states", - i - 1); + state_node = of_get_cpu_state_node(cpu_node, i - 1); if (!state_node) break;