sched: eas: add sched-energy support for gxm [1/1]

PD#SWPL-4651

Problem:
Kernel 32bit Support for S912(kernel 4.9)

Solution:
add arm/arm64 sched-energy dts

Verify:
q201

Change-Id: I13077632b730d5f2b1427b3d9bee9ff24031cfcd
Signed-off-by: Hanjie Lin <hanjie.lin@amlogic.com>
This commit is contained in:
Hanjie Lin
2019-01-31 10:58:01 +08:00
committed by Luke Go
parent 5ff594cf61
commit 9ded2ff78d
4 changed files with 170 additions and 0 deletions

View File

@@ -0,0 +1,68 @@
/ {
energy-costs {
CPU_COST_A53_HS: core-cost0 {
busy-cost-data = <
33 4
83 23
166 41
221 54
332 78
399 92
503 135
>;
idle-cost-data = <
3
0
0
>;
};
CPU_COST_A53: core-cost1 {
busy-cost-data = <
33 4
83 23
166 41
221 54
332 78
>;
idle-cost-data = <
3
0
0
>;
};
CLUSTER_COST_A53_HS: cluster-cost0 {
busy-cost-data = <
33 7
83 8
166 9
221 10
332 13
399 15
503 23
>;
idle-cost-data = <
6
6
0
>;
};
CLUSTER_COST_A53: cluster-cost1 {
busy-cost-data = <
33 7
83 8
166 9
221 10
332 13
>;
idle-cost-data = <
6
6
0
>;
};
};
};

View File

@@ -26,6 +26,7 @@
#include <dt-bindings/pwm/pwm.h>
#include <dt-bindings/pwm/meson.h>
#include "mesongxm-gpu-t82x.dtsi"
#include "gxm-sched-energy.dtsi"
/ {
cpus:cpus {
#address-cells = <1>;
@@ -69,6 +70,8 @@
clocks = <&scpi_dvfs 0>;
clock-names = "cpu-cluster.0";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53_HS
&CLUSTER_COST_A53_HS>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -83,6 +86,8 @@
clocks = <&scpi_dvfs 0>;
clock-names = "cpu-cluster.0";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53_HS
&CLUSTER_COST_A53_HS>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -97,6 +102,8 @@
clocks = <&scpi_dvfs 0>;
clock-names = "cpu-cluster.0";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53_HS
&CLUSTER_COST_A53_HS>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -111,6 +118,8 @@
clocks = <&scpi_dvfs 0>;
clock-names = "cpu-cluster.0";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53_HS
&CLUSTER_COST_A53_HS>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -125,6 +134,8 @@
clocks = <&scpi_dvfs 1>;
clock-names = "cpu-cluster.1";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53
&CLUSTER_COST_A53>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -139,6 +150,8 @@
clocks = <&scpi_dvfs 1>;
clock-names = "cpu-cluster.1";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53
&CLUSTER_COST_A53>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -152,6 +165,8 @@
clocks = <&scpi_dvfs 1>;
clock-names = "cpu-cluster.1";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53
&CLUSTER_COST_A53>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -166,6 +181,8 @@
clocks = <&scpi_dvfs 1>;
clock-names = "cpu-cluster.1";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53
&CLUSTER_COST_A53>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;

View File

@@ -0,0 +1,68 @@
/ {
energy-costs {
CPU_COST_A53_HS: core-cost0 {
busy-cost-data = <
33 4
83 23
166 41
221 54
332 78
399 92
503 135
>;
idle-cost-data = <
3
0
0
>;
};
CPU_COST_A53: core-cost1 {
busy-cost-data = <
33 4
83 23
166 41
221 54
332 78
>;
idle-cost-data = <
3
0
0
>;
};
CLUSTER_COST_A53_HS: cluster-cost0 {
busy-cost-data = <
33 7
83 8
166 9
221 10
332 13
399 15
503 23
>;
idle-cost-data = <
6
6
0
>;
};
CLUSTER_COST_A53: cluster-cost1 {
busy-cost-data = <
33 7
83 8
166 9
221 10
332 13
>;
idle-cost-data = <
6
6
0
>;
};
};
};

View File

@@ -26,6 +26,7 @@
#include <dt-bindings/pwm/pwm.h>
#include <dt-bindings/pwm/meson.h>
#include "mesongxm-gpu-t82x.dtsi"
#include "gxm-sched-energy.dtsi"
/ {
cpus:cpus {
#address-cells = <2>;
@@ -69,6 +70,8 @@
clocks = <&scpi_dvfs 0>;
clock-names = "cpu-cluster.0";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53_HS
&CLUSTER_COST_A53_HS>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -83,6 +86,8 @@
clocks = <&scpi_dvfs 0>;
clock-names = "cpu-cluster.0";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53_HS
&CLUSTER_COST_A53_HS>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -97,6 +102,8 @@
clocks = <&scpi_dvfs 0>;
clock-names = "cpu-cluster.0";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53_HS
&CLUSTER_COST_A53_HS>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -111,6 +118,8 @@
clocks = <&scpi_dvfs 0>;
clock-names = "cpu-cluster.0";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53_HS
&CLUSTER_COST_A53_HS>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -125,6 +134,8 @@
clocks = <&scpi_dvfs 1>;
clock-names = "cpu-cluster.1";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53
&CLUSTER_COST_A53>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -139,6 +150,8 @@
clocks = <&scpi_dvfs 1>;
clock-names = "cpu-cluster.1";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53
&CLUSTER_COST_A53>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -152,6 +165,8 @@
clocks = <&scpi_dvfs 1>;
clock-names = "cpu-cluster.1";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53
&CLUSTER_COST_A53>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;
@@ -166,6 +181,8 @@
clocks = <&scpi_dvfs 1>;
clock-names = "cpu-cluster.1";
cpu-idle-states = <&SYSTEM_SLEEP_0>;
sched-energy-costs = <&CPU_COST_A53
&CLUSTER_COST_A53>;
/*
* cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0
* &SYSTEM_SLEEP_0>;