[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-32fb480e0a2cf1f71e4174d6477198c94dbc746c@git.kernel.org>
Date: Thu, 23 May 2019 02:26:55 -0700
From: tip-bot for Zhang Rui <tipbot@...or.com>
To: linux-tip-commits@...r.kernel.org
Cc: peterz@...radead.org, rafael.j.wysocki@...el.com, hpa@...or.com,
rui.zhang@...el.com, tglx@...utronix.de, mingo@...nel.org,
linux-kernel@...r.kernel.org, len.brown@...el.com
Subject: [tip:x86/topology] powercap/intel_rapl: Support multi-die/package
Commit-ID: 32fb480e0a2cf1f71e4174d6477198c94dbc746c
Gitweb: https://git.kernel.org/tip/32fb480e0a2cf1f71e4174d6477198c94dbc746c
Author: Zhang Rui <rui.zhang@...el.com>
AuthorDate: Mon, 13 May 2019 13:58:51 -0400
Committer: Thomas Gleixner <tglx@...utronix.de>
CommitDate: Thu, 23 May 2019 10:08:32 +0200
powercap/intel_rapl: Support multi-die/package
RAPL "package" domains are actually implemented in hardware per-die.
Thus, the new multi-die/package systems have mulitple domains
within each physical package.
Update the intel_rapl driver to be "die aware" -- exporting multiple
domains within a single package, when present. No change on single
die/package systems.
Signed-off-by: Zhang Rui <rui.zhang@...el.com>
Signed-off-by: Len Brown <len.brown@...el.com>
Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
Reviewed-by: Ingo Molnar <mingo@...nel.org>
Acked-by: Rafael J. Wysocki <rafael.j.wysocki@...el.com>
Acked-by: Peter Zijlstra (Intel) <peterz@...radead.org>
Cc: linux-pm@...r.kernel.org
Link: https://lkml.kernel.org/r/9fcb4719aeb7efccf3bc75ed8dd559e46121649f.1557769318.git.len.brown@intel.com
---
drivers/powercap/intel_rapl.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/powercap/intel_rapl.c b/drivers/powercap/intel_rapl.c
index 3c3c0c23180b..9202dbcef96d 100644
--- a/drivers/powercap/intel_rapl.c
+++ b/drivers/powercap/intel_rapl.c
@@ -266,7 +266,7 @@ static struct rapl_domain *platform_rapl_domain; /* Platform (PSys) domain */
/* caller to ensure CPU hotplug lock is held */
static struct rapl_package *rapl_find_package_domain(int cpu)
{
- int id = topology_physical_package_id(cpu);
+ int id = topology_logical_die_id(cpu);
struct rapl_package *rp;
list_for_each_entry(rp, &rapl_packages, plist) {
@@ -1459,7 +1459,7 @@ static void rapl_remove_package(struct rapl_package *rp)
/* called from CPU hotplug notifier, hotplug lock held */
static struct rapl_package *rapl_add_package(int cpu)
{
- int id = topology_physical_package_id(cpu);
+ int id = topology_logical_die_id(cpu);
struct rapl_package *rp;
int ret;
Powered by blists - more mailing lists