All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/14] msm8992 DTS updates, peripheral enablement
@ 2020-05-31 17:27 Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 01/14] arm64: dts: Add a proper CPU map for MSM8992 Konrad Dybcio
                   ` (13 more replies)
  0 siblings, 14 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This patch series adds support for PMU, PSCI, SPMI
and SCM, as well as all six cores on msm8992.

Please note though, that due to the lack of a core 
cluster interconnect driver, it is only recommended 
to use one cluster (as in set NR_CPUS to 4) for now.
The other two technically work, but in practice slow
down the platform by a LOT.

Hopefully with a proper MMCC driver this platform can be
brought up to speed with other Qualcomm SoCs.

Konrad Dybcio (14):
  arm64: dts: Add a proper CPU map for MSM8992
  arm64: dts: msm8992: Place clock nodes in clocks{}
  arm64: dts: msm8992: Add a SCM node
  firmware: qcom_scm: Add msm8992 compatible
  Documentation: Document msm8992 qcom_scm compatible
  arm64: dts: msm8992: Add a spmi_bus node
  arm64: dts: msm8992: Add BLSP2 UART2 node
  arm64: dts: msm8992: Add a BLSP I2C2 node
  arm64: dts: msm8992: Add a BLSP I2C6 node
  arm64: dts: msm8992: Add PMU node
  arm64: dts: msm8992: Add PSCI support.
  arm64: dts: qcom: Update msm8992 pin configuration
  arm64: dts: qcom: Fix msm8992 SDHCI
  arm64: dts: qcom: Add a label to the msm8992 rpm-requests node

 .../devicetree/bindings/firmware/qcom,scm.txt |   1 +
 arch/arm64/boot/dts/qcom/msm8992-pins.dtsi    | 149 ++++++++++++----
 arch/arm64/boot/dts/qcom/msm8992.dtsi         | 167 ++++++++++++++++--
 drivers/firmware/qcom_scm.c                   |   1 +
 4 files changed, 275 insertions(+), 43 deletions(-)

-- 
2.26.2


^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 01/14] arm64: dts: Add a proper CPU map for MSM8992
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
@ 2020-05-31 17:27 ` Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 02/14] arm64: dts: msm8992: Place clock nodes in clocks{} Konrad Dybcio
                   ` (12 subsequent siblings)
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This commit adds cpu nodes for all 6 cores
present on this SoC and the cpu-map.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 68 +++++++++++++++++++++++++++
 1 file changed, 68 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index 2021795c99ad..900c9445e0ba 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -20,11 +20,34 @@ / {
 	cpus {
 		#address-cells = <2>;
 		#size-cells = <0>;
+
 		cpu-map {
 			cluster0 {
 				core0 {
 					cpu = <&CPU0>;
 				};
+
+				core1 {
+					cpu = <&CPU1>;
+				};
+
+				core2 {
+					cpu = <&CPU2>;
+				};
+
+				core3 {
+					cpu = <&CPU3>;
+				};
+			};
+
+			cluster1 {
+				core0 {
+					cpu = <&CPU4>;
+				};
+
+				core1 {
+					cpu = <&CPU5>;
+				};
 			};
 		};
 
@@ -33,11 +56,56 @@ CPU0: cpu@0 {
 			compatible = "arm,cortex-a53";
 			reg = <0x0 0x0>;
 			next-level-cache = <&L2_0>;
+			enable-method = "psci";
 			L2_0: l2-cache {
 				compatible = "cache";
 				cache-level = <2>;
 			};
 		};
+
+		CPU1: cpu@1 {
+			device_type = "cpu";
+			compatible = "arm,cortex-a53";
+			reg = <0x0 0x1>;
+			next-level-cache = <&L2_0>;
+			enable-method = "psci";
+		};
+
+		CPU2: cpu@2 {
+			device_type = "cpu";
+			compatible = "arm,cortex-a53";
+			reg = <0x0 0x2>;
+			next-level-cache = <&L2_0>;
+			enable-method = "psci";
+		};
+
+		CPU3: cpu@3 {
+			device_type = "cpu";
+			compatible = "arm,cortex-a53";
+			reg = <0x0 0x3>;
+			next-level-cache = <&L2_0>;
+			enable-method = "psci";
+		};
+
+		CPU4: cpu@100 {
+			device_type = "cpu";
+			compatible = "arm,cortex-a57";
+			reg = <0x0 0x100>;
+			next-level-cache = <&L2_1>;
+			enable-method = "psci";
+			L2_1: l2-cache {
+				compatible = "cache";
+				cache-level = <2>;
+			};
+		};
+
+		CPU5: cpu@101 {
+			device_type = "cpu";
+			compatible = "arm,cortex-a57";
+			reg = <0x0 0x101>;
+			next-level-cache = <&L2_1>;
+			enable-method = "psci";
+		};
 	};
 
 	timer {
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 02/14] arm64: dts: msm8992: Place clock nodes in clocks{}
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 01/14] arm64: dts: Add a proper CPU map for MSM8992 Konrad Dybcio
@ 2020-05-31 17:27 ` Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 03/14] arm64: dts: msm8992: Add a SCM node Konrad Dybcio
                   ` (11 subsequent siblings)
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This commits brings no changes
functionality-wise, but aligns the DTS
with the style used in newer ones.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 20 +++++++++++---------
 1 file changed, 11 insertions(+), 9 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index 900c9445e0ba..e255b577af37 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -116,16 +116,18 @@ timer {
 			     <GIC_PPI 1 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;
 	};
 
-	xo_board: xo_board {
-		compatible = "fixed-clock";
-		#clock-cells = <0>;
-		clock-frequency = <19200000>;
-	};
+	clocks {
+		xo_board: xo_board {
+			compatible = "fixed-clock";
+			#clock-cells = <0>;
+			clock-frequency = <19200000>;
+		};
 
-	sleep_clk: sleep_clk {
-		compatible = "fixed-clock";
-		#clock-cells = <0>;
-		clock-frequency = <32768>;
+		sleep_clk: sleep_clk {
+			compatible = "fixed-clock";
+			#clock-cells = <0>;
+			clock-frequency = <32768>;
+		};
 	};
 
 	vreg_vph_pwr: vreg-vph-pwr {
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 03/14] arm64: dts: msm8992: Add a SCM node
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 01/14] arm64: dts: Add a proper CPU map for MSM8992 Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 02/14] arm64: dts: msm8992: Place clock nodes in clocks{} Konrad Dybcio
@ 2020-05-31 17:27 ` Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 04/14] firmware: qcom_scm: Add msm8992 compatible Konrad Dybcio
                   ` (10 subsequent siblings)
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index e255b577af37..535be60521d8 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -154,6 +154,12 @@ smem {
 		hwlocks = <&sfpb_mutex 3>;
 	};
 
+	firmware {
+		scm {
+			compatible = "qcom,scm-msm8992";
+		};
+	};
+
 	soc {
 		#address-cells = <1>;
 		#size-cells = <1>;
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 04/14] firmware: qcom_scm: Add msm8992 compatible
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (2 preceding siblings ...)
  2020-05-31 17:27 ` [PATCH 03/14] arm64: dts: msm8992: Add a SCM node Konrad Dybcio
@ 2020-05-31 17:27 ` Konrad Dybcio
  2020-06-23 23:20   ` Bjorn Andersson
  2020-05-31 17:27 ` [PATCH 05/14] Documentation: Document msm8992 qcom_scm compatible Konrad Dybcio
                   ` (9 subsequent siblings)
  13 siblings, 1 reply; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This change adds a compatible for msm8992,
which requires no additional clocks for
scm to probe correctly.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 drivers/firmware/qcom_scm.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/firmware/qcom_scm.c b/drivers/firmware/qcom_scm.c
index 059bb0fbae9e..4ee94c2ff5c0 100644
--- a/drivers/firmware/qcom_scm.c
+++ b/drivers/firmware/qcom_scm.c
@@ -1154,6 +1154,7 @@ static const struct of_device_id qcom_scm_dt_match[] = {
 							     SCM_HAS_IFACE_CLK |
 							     SCM_HAS_BUS_CLK)
 	},
+	{ .compatible = "qcom,scm-msm8992" },
 	{ .compatible = "qcom,scm-msm8996" },
 	{ .compatible = "qcom,scm" },
 	{}
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 05/14] Documentation: Document msm8992 qcom_scm compatible
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (3 preceding siblings ...)
  2020-05-31 17:27 ` [PATCH 04/14] firmware: qcom_scm: Add msm8992 compatible Konrad Dybcio
@ 2020-05-31 17:27 ` Konrad Dybcio
  2020-06-09 22:16   ` Rob Herring
  2020-05-31 17:27 ` [PATCH 06/14] arm64: dts: msm8992: Add a spmi_bus node Konrad Dybcio
                   ` (8 subsequent siblings)
  13 siblings, 1 reply; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 Documentation/devicetree/bindings/firmware/qcom,scm.txt | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/firmware/qcom,scm.txt b/Documentation/devicetree/bindings/firmware/qcom,scm.txt
index 354b448fc0c3..fd7e1aff9cdc 100644
--- a/Documentation/devicetree/bindings/firmware/qcom,scm.txt
+++ b/Documentation/devicetree/bindings/firmware/qcom,scm.txt
@@ -15,6 +15,7 @@ Required properties:
  * "qcom,scm-msm8916"
  * "qcom,scm-msm8960"
  * "qcom,scm-msm8974"
+ * "qcom,scm-msm8992"
  * "qcom,scm-msm8996"
  * "qcom,scm-msm8998"
  * "qcom,scm-sc7180"
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 06/14] arm64: dts: msm8992: Add a spmi_bus node
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (4 preceding siblings ...)
  2020-05-31 17:27 ` [PATCH 05/14] Documentation: Document msm8992 qcom_scm compatible Konrad Dybcio
@ 2020-05-31 17:27 ` Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 07/14] arm64: dts: msm8992: Add BLSP2 UART2 node Konrad Dybcio
                   ` (7 subsequent siblings)
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This change adds a SPMI bus node so as to
enable PMIC and PMIC peripherals interaction.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index 535be60521d8..8f7cdf2b9a1f 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -253,6 +253,22 @@ msmgpio: pinctrl@fd510000 {
 			#interrupt-cells = <2>;
 		};
 
+		spmi_bus: qcom,spmi@fc4c0000 {
+			compatible = "qcom,spmi-pmic-arb";
+			reg = <0xfc4cf000 0x1000>,
+			      <0xfc4cb000 0x1000>,
+			      <0xfc4ca000 0x1000>;
+			reg-names = "core", "intr", "cnfg";
+			interrupt-names = "periph_irq";
+			interrupts = <GIC_SPI 190 IRQ_TYPE_LEVEL_HIGH>;
+			qcom,ee = <0>;
+			qcom,channel = <0>;
+			#address-cells = <2>;
+			#size-cells = <0>;
+			interrupt-controller;
+			#interrupt-cells = <4>;
+		};
+
 		blsp1_uart2: serial@f991e000 {
 			compatible = "qcom,msm-uartdm-v1.4", "qcom,msm-uartdm";
 			reg = <0xf991e000 0x1000>;
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 07/14] arm64: dts: msm8992: Add BLSP2 UART2 node
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (5 preceding siblings ...)
  2020-05-31 17:27 ` [PATCH 06/14] arm64: dts: msm8992: Add a spmi_bus node Konrad Dybcio
@ 2020-05-31 17:27 ` Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 08/14] arm64: dts: msm8992: Add a BLSP I2C2 node Konrad Dybcio
                   ` (6 subsequent siblings)
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This commit enables the usage of a second
UART interface.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index 8f7cdf2b9a1f..ff745905525c 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -279,6 +279,16 @@ blsp1_uart2: serial@f991e000 {
 				<&clock_gcc GCC_BLSP1_AHB_CLK>;
 		};
 
+		blsp2_uart2: serial@f995e000 {
+			compatible = "qcom,msm-uartdm-v1.4", "qcom,msm-uartdm";
+			reg = <0xf995e000 0x1000>;
+			interrupt = <GIC_SPI 146 IRQ_TYPE_LEVEL_LOW>;
+			status = "disabled";
+			clock-names = "core", "iface";
+			clocks = <&gcc GCC_BLSP2_UART2_APPS_CLK>,
+				<&gcc GCC_BLSP2_AHB_CLK>;
+		};
+
 		clock_gcc: clock-controller@fc400000 {
 			compatible = "qcom,gcc-msm8994";
 			#clock-cells = <1>;
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 08/14] arm64: dts: msm8992: Add a BLSP I2C2 node
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (6 preceding siblings ...)
  2020-05-31 17:27 ` [PATCH 07/14] arm64: dts: msm8992: Add BLSP2 UART2 node Konrad Dybcio
@ 2020-05-31 17:27 ` Konrad Dybcio
  2020-05-31 17:27 ` [PATCH 09/14] arm64: dts: msm8992: Add a BLSP I2C6 node Konrad Dybcio
                   ` (5 subsequent siblings)
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This commit adds support for the second I2C interface
on msm8992 which seems to be used mostly for touchscreen
devices.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index ff745905525c..395f4c325c2f 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -333,6 +333,21 @@ sfpb_mutex_regs: syscon@fd484000 {
 			compatible = "syscon";
 			reg = <0xfd484000 0x400>;
 		};
+
+		blsp_i2c2: i2c@f9924000 {
+			compatible = "qcom,i2c-qup-v2.2.1";
+			reg = <0xf9924000 0x500>;
+			interrupts = <GIC_SPI 96 IRQ_TYPE_LEVEL_HIGH>;
+			clocks = <&gcc GCC_BLSP1_AHB_CLK>,
+				 <&gcc GCC_BLSP1_QUP2_I2C_APPS_CLK>;
+			clock-names = "iface", "core";
+			pinctrl-names = "default", "sleep";
+			pinctrl-0 = <&i2c2_default>;
+			pinctrl-1 = <&i2c2_sleep>;
+			#address-cells = <1>;
+			#size-cells = <0>;
+			status = "disabled";
+		};
 	};
 
 	memory {
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 09/14] arm64: dts: msm8992: Add a BLSP I2C6 node
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (7 preceding siblings ...)
  2020-05-31 17:27 ` [PATCH 08/14] arm64: dts: msm8992: Add a BLSP I2C2 node Konrad Dybcio
@ 2020-05-31 17:27 ` Konrad Dybcio
  2020-05-31 17:28 ` [PATCH 10/14] arm64: dts: msm8992: Add PMU node Konrad Dybcio
                   ` (4 subsequent siblings)
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:27 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This commit adds support for the sixth I2C interface
on msm8992.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index 395f4c325c2f..ef95f5ee83db 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -348,6 +348,21 @@ blsp_i2c2: i2c@f9924000 {
 			#size-cells = <0>;
 			status = "disabled";
 		};
+
+		blsp_i2c6: i2c@f9928000 {
+			compatible = "qcom,i2c-qup-v2.2.1";
+			reg = <0xf9928000 0x500>;
+			interrupts = <GIC_SPI 100 IRQ_TYPE_LEVEL_HIGH>;
+			clocks = <&gcc GCC_BLSP1_AHB_CLK>,
+				 <&gcc GCC_BLSP1_QUP6_I2C_APPS_CLK>;
+			clock-names = "iface", "core";
+			pinctrl-names = "default", "sleep";
+			pinctrl-0 = <&i2c6_default>;
+			pinctrl-1 = <&i2c6_sleep>;
+			#address-cells = <1>;
+			#size-cells = <0>;
+			status = "ok";
+		};
 	};
 
 	memory {
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 10/14] arm64: dts: msm8992: Add PMU node
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (8 preceding siblings ...)
  2020-05-31 17:27 ` [PATCH 09/14] arm64: dts: msm8992: Add a BLSP I2C6 node Konrad Dybcio
@ 2020-05-31 17:28 ` Konrad Dybcio
  2020-05-31 17:28 ` [PATCH 11/14] arm64: dts: msm8992: Add PSCI support Konrad Dybcio
                   ` (3 subsequent siblings)
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:28 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

Add the PMU so we can get proper perf event support on this SoC.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index ef95f5ee83db..b86fcfb6f463 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -381,6 +381,11 @@ smem_region: smem@6a00000 {
 		};
 	};
 
+	pmu {
+		compatible = "arm,cortex-a53-pmu";
+		interrupts = <GIC_PPI 7 (GIC_CPU_MASK_SIMPLE(4)| IRQ_TYPE_LEVEL_HIGH)>;
+	};
+
 	smd_rpm: smd {
 		compatible = "qcom,smd";
 		rpm {
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 11/14] arm64: dts: msm8992: Add PSCI support.
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (9 preceding siblings ...)
  2020-05-31 17:28 ` [PATCH 10/14] arm64: dts: msm8992: Add PMU node Konrad Dybcio
@ 2020-05-31 17:28 ` Konrad Dybcio
  2020-05-31 17:28 ` [PATCH 12/14] arm64: dts: qcom: Update msm8992 pin configuration Konrad Dybcio
                   ` (2 subsequent siblings)
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:28 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This SoC's firmware does not fully support the PSCI
spec, but it's good enough to bring the cores up.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index b86fcfb6f463..e7354826d701 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -386,6 +386,11 @@ pmu {
 		interrupts = <GIC_PPI 7 (GIC_CPU_MASK_SIMPLE(4)| IRQ_TYPE_LEVEL_HIGH)>;
 	};
 
+	psci {
+		compatible = "arm,psci-0.2";
+		method = "hvc";
+	};
+
 	smd_rpm: smd {
 		compatible = "qcom,smd";
 		rpm {
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 12/14] arm64: dts: qcom: Update msm8992 pin configuration
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (10 preceding siblings ...)
  2020-05-31 17:28 ` [PATCH 11/14] arm64: dts: msm8992: Add PSCI support Konrad Dybcio
@ 2020-05-31 17:28 ` Konrad Dybcio
  2020-05-31 17:28 ` [PATCH 13/14] arm64: dts: qcom: Fix msm8992 SDHCI Konrad Dybcio
  2020-05-31 17:28 ` [PATCH 14/14] arm64: dts: qcom: Add a label to the msm8992 rpm-requests node Konrad Dybcio
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:28 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

Add support for i2c2 and i2c6 interfaces, wrap up
SDC pins into pmx_sdc groups (following msm8916).

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992-pins.dtsi | 149 ++++++++++++++++-----
 1 file changed, 118 insertions(+), 31 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/msm8992-pins.dtsi b/arch/arm64/boot/dts/qcom/msm8992-pins.dtsi
index c543c718c22d..17c9e048e414 100644
--- a/arch/arm64/boot/dts/qcom/msm8992-pins.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992-pins.dtsi
@@ -32,59 +32,146 @@ pinconf {
 	/* Order of pins */
 	/* SDC1: CLK -> 0, CMD -> 1, DATA -> 2, RCLK -> 3 */
 	/* SDC2: CLK -> 4, CMD -> 5, DATA -> 6 */
-	sdc1_clk_on: clk-on {
-		pinconf {
-			pins = "sdc1_clk";
-			bias-disable = <0>; /* No pull */
-			drive-strength = <16>; /* 16mA */
+
+	pmx_sdc1_clk {
+		sdc1_clk_on: clk-on {
+			pinmux {
+				pins = "sdc1_clk";
+			};
+			pinconf {
+				pins = "sdc1_clk";
+				bias-disable; /* No pull */
+				drive-strength = <6>; 
+			};
+		};
+
+		sdc1_clk_off: clk-off {
+			pinmux {
+				pins = "sdc1_clk";
+			};
+			pinconf {
+				pins = "sdc1_clk";
+				bias-disable; /* No pull */
+				drive-strength = <2>; 
+			};
 		};
 	};
 
-	sdc1_clk_off: clk-off {
-		pinconf {
-			pins = "sdc1_clk";
-			bias-disable = <0>; /* No pull */
-			drive-strength = <2>; /* 2mA */
+	pmx_sdc1_cmd {
+		sdc1_cmd_on: cmd-on {
+			pinmux {
+				pins = "sdc1_cmd";
+			};
+			pinconf {
+				pins = "sdc1_cmd";
+				bias-pull-up;
+				drive-strength = <6>;
+			};
+		};
+
+		sdc1_cmd_off: cmd-off {
+			pinmux {
+				pins = "sdc1_cmd";
+			};
+			pinconf {
+				pins = "sdc1_cmd";
+				bias-pull-up;
+				drive-strength = <2>;
+			};
 		};
 	};
 
-	sdc1_cmd_on: cmd-on {
-		pinconf {
-			pins = "sdc1_cmd";
-			bias-pull-up;
-			drive-strength = <8>;
+	pmx_sdc1_data {
+		sdc1_data_on: data-on {
+			pinmux {
+				pins = "sdc1_data";
+			};
+			pinconf {
+				pins = "sdc1_data";
+				bias-pull-up;
+				drive-strength = <6>;
+			};
+		};
+
+		sdc1_data_off: data-off {
+			pinmux {
+				pins = "sdc1_data";
+			};
+			pinconf {
+				pins = "sdc1_data";
+				bias-pull-up;
+				drive-strength = <2>;
+			};
 		};
 	};
 
-	sdc1_cmd_off: cmd-off {
-		pinconf {
-			pins = "sdc1_cmd";
-			bias-pull-up = <0x3>; /* same as 3.10 ?? */
-			drive-strength = <2>; /* 2mA */
+	pmx_sdc1_rclk {
+		sdc1_rclk_on: rclk-on {
+			pinmux {
+				pins = "sdc1_rclk";
+			};
+			pinconf {
+				pins = "sdc1_rclk";
+				bias-pull-down; /* pull down */
+			};
+		};
+
+		sdc1_rclk_off: rclk-off {
+			pinmux {
+				pins = "sdc1_rclk";
+			};
+			pinconf {
+				pins = "sdc1_rclk";
+				bias-pull-down; /* pull down */
+			};
 		};
 	};
 
-	sdc1_data_on: data-on {
+	i2c2_default: i2c2_default {
+		pinmux {
+			function = "blsp_i2c2";
+			pins = "gpio6", "gpio7";
+		};
 		pinconf {
-			pins = "sdc1_data";
-			bias-pull-up;
-			drive-strength = <8>; /* 8mA */
+			pins = "gpio6", "gpio7";
+			drive-strength = <2>;
+			bias-disable;
 		};
 	};
 
-	sdc1_data_off: data-off {
+	i2c2_sleep: i2c2_sleep {
+		pinmux {
+			function = "gpio";
+			pins = "gpio6", "gpio7";
+		};
 		pinconf {
-			pins = "sdc1_data";
-			bias-pull-up;
+			pins = "gpio6", "gpio7";
 			drive-strength = <2>;
+			bias-disable;
 		};
 	};
 
-	sdc1_rclk_on: rclk-on {
-		bias-pull-down; /* pull down */
+	i2c6_default: i2c6_default {
+		pinmux {
+			function = "blsp_i2c6";
+			pins = "gpio28", "gpio27";
+		};
+		pinconf {
+			pins = "gpio28", "gpio27";
+			drive-strength = <2>;
+			bias-disable;
+		};
 	};
 
-	sdc1_rclk_off: rclk-off {
-		bias-pull-down; /* pull down */
+	i2c6_sleep: i2c6_sleep {
+		pinmux {
+			function = "gpio";
+			pins = "gpio28", "gpio27";
+		};
+		pinconf {
+			pins = "gpio28", "gpio27";
+			drive-strength = <2>;
+			bias-disable;
+		};
 	};
 };
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 13/14] arm64: dts: qcom: Fix msm8992 SDHCI
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (11 preceding siblings ...)
  2020-05-31 17:28 ` [PATCH 12/14] arm64: dts: qcom: Update msm8992 pin configuration Konrad Dybcio
@ 2020-05-31 17:28 ` Konrad Dybcio
  2020-05-31 17:28 ` [PATCH 14/14] arm64: dts: qcom: Add a label to the msm8992 rpm-requests node Konrad Dybcio
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:28 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This commit adds correct IRQ settings and adds
the non-removable property to the msm8992 sdhci
node.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index e7354826d701..b5bd73205a55 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -302,8 +302,8 @@ sdhci1: mmc@f9824900 {
 			reg = <0xf9824900 0x1a0>, <0xf9824000 0x800>;
 			reg-names = "hc_mem", "core_mem";
 
-			interrupts = <GIC_SPI 123 IRQ_TYPE_NONE>,
-					<GIC_SPI 138 IRQ_TYPE_NONE>;
+			interrupts = <GIC_SPI 123 IRQ_TYPE_LEVEL_HIGH>,
+					<GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>;
 			interrupt-names = "hc_irq", "pwr_irq";
 
 			clocks = <&clock_gcc GCC_SDCC1_APPS_CLK>,
@@ -319,6 +319,7 @@ sdhci1: mmc@f9824900 {
 			regulator-always-on;
 			bus-width = <8>;
 			mmc-hs400-1_8v;
+			non-removable;
 			status = "okay";
 		};
 
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* [PATCH 14/14] arm64: dts: qcom: Add a label to the msm8992 rpm-requests node
  2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
                   ` (12 preceding siblings ...)
  2020-05-31 17:28 ` [PATCH 13/14] arm64: dts: qcom: Fix msm8992 SDHCI Konrad Dybcio
@ 2020-05-31 17:28 ` Konrad Dybcio
  13 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-05-31 17:28 UTC (permalink / raw)
  Cc: Konrad Dybcio, Andy Gross, Bjorn Andersson, Rob Herring,
	linux-arm-msm, devicetree, linux-kernel

This enables the node to be referenced in other device trees.

Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8992.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/msm8992.dtsi b/arch/arm64/boot/dts/qcom/msm8992.dtsi
index b5bd73205a55..81fed16fcee6 100644
--- a/arch/arm64/boot/dts/qcom/msm8992.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8992.dtsi
@@ -401,7 +401,7 @@ rpm {
 			qcom,local-pid = <0>;
 			qcom,remote-pid = <6>;
 
-			rpm-requests {
+			rpm_requests: rpm-requests {
 				compatible = "qcom,rpm-msm8994";
 				qcom,smd-channels = "rpm_requests";
 
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 18+ messages in thread

* Re: [PATCH 05/14] Documentation: Document msm8992 qcom_scm compatible
  2020-05-31 17:27 ` [PATCH 05/14] Documentation: Document msm8992 qcom_scm compatible Konrad Dybcio
@ 2020-06-09 22:16   ` Rob Herring
  0 siblings, 0 replies; 18+ messages in thread
From: Rob Herring @ 2020-06-09 22:16 UTC (permalink / raw)
  To: Konrad Dybcio
  Cc: devicetree, Andy Gross, linux-kernel, Rob Herring, linux-arm-msm,
	Bjorn Andersson

On Sun, 31 May 2020 19:27:55 +0200, Konrad Dybcio wrote:
> Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
> ---
>  Documentation/devicetree/bindings/firmware/qcom,scm.txt | 1 +
>  1 file changed, 1 insertion(+)
> 

Acked-by: Rob Herring <robh@kernel.org>

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 04/14] firmware: qcom_scm: Add msm8992 compatible
  2020-05-31 17:27 ` [PATCH 04/14] firmware: qcom_scm: Add msm8992 compatible Konrad Dybcio
@ 2020-06-23 23:20   ` Bjorn Andersson
  2020-06-23 23:37     ` Konrad Dybcio
  0 siblings, 1 reply; 18+ messages in thread
From: Bjorn Andersson @ 2020-06-23 23:20 UTC (permalink / raw)
  To: Konrad Dybcio; +Cc: Andy Gross, Rob Herring, linux-arm-msm, devicetree, lkml

On Sun, May 31, 2020 at 10:28 AM Konrad Dybcio <konradybcio@gmail.com> wrote:
>
> This change adds a compatible for msm8992,
> which requires no additional clocks for
> scm to probe correctly.
>
> Signed-off-by: Konrad Dybcio <konradybcio@gmail.com>
> ---
>  drivers/firmware/qcom_scm.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/drivers/firmware/qcom_scm.c b/drivers/firmware/qcom_scm.c
> index 059bb0fbae9e..4ee94c2ff5c0 100644
> --- a/drivers/firmware/qcom_scm.c
> +++ b/drivers/firmware/qcom_scm.c
> @@ -1154,6 +1154,7 @@ static const struct of_device_id qcom_scm_dt_match[] = {
>                                                              SCM_HAS_IFACE_CLK |
>                                                              SCM_HAS_BUS_CLK)
>         },
> +       { .compatible = "qcom,scm-msm8992" },

As this is equivalent to "qcom,scm" use the form:
compatible = "qcom,scm-msm8992", "qcom,scm";

I do however believe you still need to post a patch for the DT
binding, to allow the checkers to accept "qcom,scm-msm8992".

Regards,
Bjorn

>         { .compatible = "qcom,scm-msm8996" },
>         { .compatible = "qcom,scm" },
>         {}
> --
> 2.26.2
>

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 04/14] firmware: qcom_scm: Add msm8992 compatible
  2020-06-23 23:20   ` Bjorn Andersson
@ 2020-06-23 23:37     ` Konrad Dybcio
  0 siblings, 0 replies; 18+ messages in thread
From: Konrad Dybcio @ 2020-06-23 23:37 UTC (permalink / raw)
  To: Bjorn Andersson; +Cc: Andy Gross, Rob Herring, linux-arm-msm, devicetree, lkml

I have in fact submitted a binding patch here: [1]

Perhaps I shouldn't have split it since it's just a one-liner.

[1] https://patchwork.kernel.org/patch/11580841/

Regards
Konrad

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2020-06-23 23:38 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-31 17:27 [PATCH 00/14] msm8992 DTS updates, peripheral enablement Konrad Dybcio
2020-05-31 17:27 ` [PATCH 01/14] arm64: dts: Add a proper CPU map for MSM8992 Konrad Dybcio
2020-05-31 17:27 ` [PATCH 02/14] arm64: dts: msm8992: Place clock nodes in clocks{} Konrad Dybcio
2020-05-31 17:27 ` [PATCH 03/14] arm64: dts: msm8992: Add a SCM node Konrad Dybcio
2020-05-31 17:27 ` [PATCH 04/14] firmware: qcom_scm: Add msm8992 compatible Konrad Dybcio
2020-06-23 23:20   ` Bjorn Andersson
2020-06-23 23:37     ` Konrad Dybcio
2020-05-31 17:27 ` [PATCH 05/14] Documentation: Document msm8992 qcom_scm compatible Konrad Dybcio
2020-06-09 22:16   ` Rob Herring
2020-05-31 17:27 ` [PATCH 06/14] arm64: dts: msm8992: Add a spmi_bus node Konrad Dybcio
2020-05-31 17:27 ` [PATCH 07/14] arm64: dts: msm8992: Add BLSP2 UART2 node Konrad Dybcio
2020-05-31 17:27 ` [PATCH 08/14] arm64: dts: msm8992: Add a BLSP I2C2 node Konrad Dybcio
2020-05-31 17:27 ` [PATCH 09/14] arm64: dts: msm8992: Add a BLSP I2C6 node Konrad Dybcio
2020-05-31 17:28 ` [PATCH 10/14] arm64: dts: msm8992: Add PMU node Konrad Dybcio
2020-05-31 17:28 ` [PATCH 11/14] arm64: dts: msm8992: Add PSCI support Konrad Dybcio
2020-05-31 17:28 ` [PATCH 12/14] arm64: dts: qcom: Update msm8992 pin configuration Konrad Dybcio
2020-05-31 17:28 ` [PATCH 13/14] arm64: dts: qcom: Fix msm8992 SDHCI Konrad Dybcio
2020-05-31 17:28 ` [PATCH 14/14] arm64: dts: qcom: Add a label to the msm8992 rpm-requests node Konrad Dybcio

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.