Skip to content

Commit 333505a

Browse files
committed
Merge tag 'qcom-drivers-for-5.6' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux into arm/drivers
Qualcomm driver updates for v5.6 * SCM major refactoring and cleanup * Properly flag active only power domains as active only * Add SC7180 and SM8150 RPMH power domains * Return EPROBE_DEFER from QMI if packet family is not yet available * tag 'qcom-drivers-for-5.6' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux: (27 commits) firmware: qcom_scm: Dynamically support SMCCC and legacy conventions firmware: qcom_scm: Remove thin wrappers firmware: qcom_scm: Order functions, definitions by service/command firmware: qcom_scm-32: Add device argument to atomic calls firmware: qcom_scm-32: Create common legacy atomic call firmware: qcom_scm-32: Move SMCCC register filling to qcom_scm_call firmware: qcom_scm-32: Use qcom_scm_desc in non-atomic calls firmware: qcom_scm-32: Add funcnum IDs firmware: qcom_scm-32: Use SMC arch wrappers firmware: qcom_scm-64: Improve SMC convention detection firmware: qcom_scm-64: Move SMC register filling to qcom_scm_call_smccc firmware: qcom_scm-64: Add SCM results struct firmware: qcom_scm-64: Move svc/cmd/owner into qcom_scm_desc firmware: qcom_scm-64: Make SMC macros less magical firmware: qcom_scm: Remove unused qcom_scm_get_version firmware: qcom_scm: Apply consistent naming scheme to command IDs firmware: qcom_scm: Rename macros and structures soc: qcom: rpmhpd: Set 'active_only' for active only power domains firmware: scm: Add stubs for OCMEM and restore_sec_cfg_available dt-bindings: power: rpmpd: Convert rpmpd bindings to yaml ... Link: https://lore.kernel.org/r/20200113204405.GD3325@yoga Signed-off-by: Olof Johansson <[email protected]>
2 parents a9e3e12 + 9a434ce commit 333505a

File tree

16 files changed

+1504
-1741
lines changed

16 files changed

+1504
-1741
lines changed

Documentation/devicetree/bindings/arm/msm/qcom,llcc.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ examples:
4747
- |
4848
#include <dt-bindings/interrupt-controller/arm-gic.h>
4949
50-
cache-controller@1100000 {
50+
system-cache-controller@1100000 {
5151
compatible = "qcom,sdm845-llcc";
5252
reg = <0x1100000 0x200000>, <0x1300000 0x50000> ;
5353
reg-names = "llcc_base", "llcc_broadcast_base";

Documentation/devicetree/bindings/power/qcom,rpmpd.txt

Lines changed: 0 additions & 148 deletions
This file was deleted.
Lines changed: 170 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,170 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/power/qcom,rpmpd.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: Qualcomm RPM/RPMh Power domains
8+
9+
maintainers:
10+
- Rajendra Nayak <[email protected]>
11+
12+
description:
13+
For RPM/RPMh Power domains, we communicate a performance state to RPM/RPMh
14+
which then translates it into a corresponding voltage on a rail.
15+
16+
properties:
17+
compatible:
18+
enum:
19+
- qcom,msm8976-rpmpd
20+
- qcom,msm8996-rpmpd
21+
- qcom,msm8998-rpmpd
22+
- qcom,qcs404-rpmpd
23+
- qcom,sc7180-rpmhpd
24+
- qcom,sdm845-rpmhpd
25+
- qcom,sm8150-rpmhpd
26+
27+
'#power-domain-cells':
28+
const: 1
29+
30+
operating-points-v2: true
31+
32+
opp-table:
33+
type: object
34+
35+
required:
36+
- compatible
37+
- '#power-domain-cells'
38+
- operating-points-v2
39+
40+
additionalProperties: false
41+
42+
examples:
43+
- |
44+
45+
// Example 1 (rpmh power domain controller and OPP table):
46+
47+
#include <dt-bindings/power/qcom-rpmpd.h>
48+
49+
rpmhpd: power-controller {
50+
compatible = "qcom,sdm845-rpmhpd";
51+
#power-domain-cells = <1>;
52+
operating-points-v2 = <&rpmhpd_opp_table>;
53+
54+
rpmhpd_opp_table: opp-table {
55+
compatible = "operating-points-v2";
56+
57+
rpmhpd_opp_ret: opp1 {
58+
opp-level = <RPMH_REGULATOR_LEVEL_RETENTION>;
59+
};
60+
61+
rpmhpd_opp_min_svs: opp2 {
62+
opp-level = <RPMH_REGULATOR_LEVEL_MIN_SVS>;
63+
};
64+
65+
rpmhpd_opp_low_svs: opp3 {
66+
opp-level = <RPMH_REGULATOR_LEVEL_LOW_SVS>;
67+
};
68+
69+
rpmhpd_opp_svs: opp4 {
70+
opp-level = <RPMH_REGULATOR_LEVEL_SVS>;
71+
};
72+
73+
rpmhpd_opp_svs_l1: opp5 {
74+
opp-level = <RPMH_REGULATOR_LEVEL_SVS_L1>;
75+
};
76+
77+
rpmhpd_opp_nom: opp6 {
78+
opp-level = <RPMH_REGULATOR_LEVEL_NOM>;
79+
};
80+
81+
rpmhpd_opp_nom_l1: opp7 {
82+
opp-level = <RPMH_REGULATOR_LEVEL_NOM_L1>;
83+
};
84+
85+
rpmhpd_opp_nom_l2: opp8 {
86+
opp-level = <RPMH_REGULATOR_LEVEL_NOM_L2>;
87+
};
88+
89+
rpmhpd_opp_turbo: opp9 {
90+
opp-level = <RPMH_REGULATOR_LEVEL_TURBO>;
91+
};
92+
93+
rpmhpd_opp_turbo_l1: opp10 {
94+
opp-level = <RPMH_REGULATOR_LEVEL_TURBO_L1>;
95+
};
96+
};
97+
};
98+
99+
- |
100+
101+
// Example 2 (rpm power domain controller and OPP table):
102+
103+
rpmpd: power-controller {
104+
compatible = "qcom,msm8996-rpmpd";
105+
#power-domain-cells = <1>;
106+
operating-points-v2 = <&rpmpd_opp_table>;
107+
108+
rpmpd_opp_table: opp-table {
109+
compatible = "operating-points-v2";
110+
111+
rpmpd_opp_low: opp1 {
112+
opp-level = <1>;
113+
};
114+
115+
rpmpd_opp_ret: opp2 {
116+
opp-level = <2>;
117+
};
118+
119+
rpmpd_opp_svs: opp3 {
120+
opp-level = <3>;
121+
};
122+
123+
rpmpd_opp_normal: opp4 {
124+
opp-level = <4>;
125+
};
126+
127+
rpmpd_opp_high: opp5 {
128+
opp-level = <5>;
129+
};
130+
131+
rpmpd_opp_turbo: opp6 {
132+
opp-level = <6>;
133+
};
134+
};
135+
};
136+
137+
- |
138+
139+
// Example 3 (Client/Consumer device using OPP table):
140+
141+
leaky-device0@12350000 {
142+
compatible = "foo,i-leak-current";
143+
reg = <0x12350000 0x1000>;
144+
power-domains = <&rpmhpd 0>;
145+
operating-points-v2 = <&leaky_opp_table>;
146+
};
147+
148+
leaky_opp_table: opp-table {
149+
compatible = "operating-points-v2";
150+
opp1 {
151+
opp-hz = /bits/ 64 <144000>;
152+
required-opps = <&rpmhpd_opp_low>;
153+
};
154+
155+
opp2 {
156+
opp-hz = /bits/ 64 <400000>;
157+
required-opps = <&rpmhpd_opp_ret>;
158+
};
159+
160+
opp3 {
161+
opp-hz = /bits/ 64 <20000000>;
162+
required-opps = <&rpmpd_opp_svs>;
163+
};
164+
165+
opp4 {
166+
opp-hz = /bits/ 64 <25000000>;
167+
required-opps = <&rpmpd_opp_normal>;
168+
};
169+
};
170+
...

drivers/firmware/Kconfig

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -239,14 +239,6 @@ config QCOM_SCM
239239
depends on ARM || ARM64
240240
select RESET_CONTROLLER
241241

242-
config QCOM_SCM_32
243-
def_bool y
244-
depends on QCOM_SCM && ARM
245-
246-
config QCOM_SCM_64
247-
def_bool y
248-
depends on QCOM_SCM && ARM64
249-
250242
config QCOM_SCM_DOWNLOAD_MODE_DEFAULT
251243
bool "Qualcomm download mode enabled by default"
252244
depends on QCOM_SCM

drivers/firmware/Makefile

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,7 @@ obj-$(CONFIG_ISCSI_IBFT) += iscsi_ibft.o
1717
obj-$(CONFIG_FIRMWARE_MEMMAP) += memmap.o
1818
obj-$(CONFIG_RASPBERRYPI_FIRMWARE) += raspberrypi.o
1919
obj-$(CONFIG_FW_CFG_SYSFS) += qemu_fw_cfg.o
20-
obj-$(CONFIG_QCOM_SCM) += qcom_scm.o
21-
obj-$(CONFIG_QCOM_SCM_64) += qcom_scm-64.o
22-
obj-$(CONFIG_QCOM_SCM_32) += qcom_scm-32.o
23-
CFLAGS_qcom_scm-32.o :=$(call as-instr,.arch armv7-a\n.arch_extension sec,-DREQUIRES_SEC=1) -march=armv7-a
20+
obj-$(CONFIG_QCOM_SCM) += qcom_scm.o qcom_scm-smc.o qcom_scm-legacy.o
2421
obj-$(CONFIG_TI_SCI_PROTOCOL) += ti_sci.o
2522
obj-$(CONFIG_TRUSTED_FOUNDATIONS) += trusted_foundations.o
2623
obj-$(CONFIG_TURRIS_MOX_RWTM) += turris-mox-rwtm.o

0 commit comments

Comments
 (0)