[Patch v8 2/7] sched/topology: Add hook to read per cpu thermal pressure.
From: Thara Gopinath
Date: Tue Jan 14 2020 - 14:57:53 EST
Introduce arch_cpu_thermal_pressure to retrieve per cpu thermal
pressure.
Signed-off-by: Thara Gopinath <thara.gopinath@xxxxxxxxxx>
---
include/linux/sched/topology.h | 8 ++++++++
1 file changed, 8 insertions(+)
v6->v7:
- Renamed arch_scale_thermal_capacity to arch_cpu_thermal_pressure
as per review comments from Peter, Dietmar and Ionela.
diff --git a/include/linux/sched/topology.h b/include/linux/sched/topology.h
index f341163..850b3bf 100644
--- a/include/linux/sched/topology.h
+++ b/include/linux/sched/topology.h
@@ -225,6 +225,14 @@ unsigned long arch_scale_cpu_capacity(int cpu)
}
#endif
+#ifndef arch_cpu_thermal_pressure
+static __always_inline
+unsigned long arch_cpu_thermal_pressure(int cpu)
+{
+ return 0;
+}
+#endif
+
static inline int task_node(const struct task_struct *p)
{
return cpu_to_node(task_cpu(p));
--
2.1.4