mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH RFC v2 0/2] arm64: dts: qcom: introduce minimal Xiaomi Warsaw support
@ 2026-10-16 15:51 Zhang Jiaxi
  2026-10-16 15:53 ` [PATCH RFC v2 1/2] dt-bindings: arm: qcom: Add Xiaomi Warsaw Zhang Jiaxi
  2026-10-16 15:53 ` [PATCH RFC v2 2/2] arm64: dts: qcom: Add a minimal Xiaomi Warsaw description Zhang Jiaxi
  0 siblings, 2 replies; 5+ messages in thread
From: Zhang Jiaxi @ 2026-10-16 15:51 UTC (permalink / raw)
  To: Bjorn Andersson, Konrad Dybcio
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-arm-msm,
	devicetree, linux-kernel, Zhang Jiaxi

Document the Xiaomi Warsaw SM8750 handset compatible and add an initial
board description for its reference clocks, keys, inherited UART7 debug
route and USB2 peripheral connection, including the regulator supplies
and PMIH0108 repeater.

The review base is torvalds/linux
6c377d19d4a5116d9bec5203aa3c6c11523e7898 (Linux 7.3-rc6).
The two patches change only qcom.yaml, the qcom Makefile and the board DTS.

The 103762-byte DTB built against this base has SHA-256
9764d1c2b638aebcfde9ce06c43784903e064a7a24afced79bb5b2fcfc322fdc.
It passes validation with dtschema 2026.9 and the complete processed
binding set, including the Warsaw compatible, without schema diagnostics
or unmatched compatibles. CPP/DTC completes successfully with 18 inherited
DTC warnings.

Hardware validation now uses the same 6c review-base kernel with only
these three board files changed. Kernel entry, FDT mapping, OF lifetime
and watchdog code are otherwise unchanged. A separate native ARM64 boot
adapter supplies the external FDT and initrd using the standard entry
interface: x0 points to the external FDT and x1-x3 are zero. Before
entering Linux it verifies the existing Gunyah SMC
identity and requests STOP for the firmware-inherited watchdog; STOP
returned success. No early kernel watchdog feeder is used.

The adapter validates usable RAM and fixed firmware reservations against
the OEM-supplied FDT. Runtime DT provisioning is limited to memory,
reserved-memory and chosen; the device description is unchanged. The
submitted DTS contains no captured RAM banks, private firmware ranges,
initrd placement or Android command line. This test does not establish
that the stock Android v4 bootloader directly supplies this replacement
raw DTB without the independent adapter. The adapter sources are not
part of this two-patch series.

For the kernel and raw-DTB build, apply these patches to the stated base
and use LLVM 20.1.8 with the matching test configuration (SHA-256
 d20500bb1ee86f3218f351bca0274c20f177c390b26d11bf5774cff19a79086a),
which is available on request:

  mkdir -p out
  cp tested-native6c.config out/.config
  make O=out ARCH=arm64 LLVM=1 LOCALVERSION= olddefconfig
  make O=out ARCH=arm64 LLVM=1 LOCALVERSION= Image qcom/sm8750-xiaomi-warsaw.dtb

The configuration has an empty built-in command line and uses an external
initramfs. Hardware reproduction also requires the separate native boot
adapter and current firmware memory/reservation input; the build commands
alone do not reproduce that boot environment.

Two RAM boots with distinct initramfs nonces reused the same kernel,
configuration, raw DTB, provisioned DT template and adapter. Each reached
BusyBox PID1, brought CPU0-7 online, advanced the timer by two seconds,
confirmed ten actual core driver bindings and exported a fresh report
over USB Ethernet. Each remained running for over 40 seconds without a
kernel watchdog feeder, then returned automatically to completed Android
A. Storage checks confirmed the disk root and installed Linux/default
entry were unchanged. UFS was disabled and no disk root was mounted.

The tests retained cpuidle.off=1. They used normal fw_devlink and unused
clock, power-domain and regulator handling, without the previous global
bypass arguments. Physical key events, display, other peripherals,
suspend/resume and idle power are outside this core/USB validation;
this is not a full-device or power-management completion claim.

Changes in v2:
- Add USB2 and its supplies to the initial board description.
- Use schema-compatible regulator node names and ordinary source labels.
- Group includes/copyrights and merge the fixed-regulator root block.
- Validate the exact 6c board-only kernel twice through a separate native
  adapter; distinguish runtime memory/chosen supply from board hardware.
- Disclose LLM assistance and prepare the two-patch series with b4.

Both patches carry my Signed-off-by. I used LLM assistance for source
analysis, drafting and preparation of the host-side tests; I remain
responsible for the submission and its DCO sign-off.

Assisted-by: LLM
---
Jiaxi Zhang (2):
      dt-bindings: arm: qcom: Add Xiaomi Warsaw
      arm64: dts: qcom: Add a minimal Xiaomi Warsaw description

 Documentation/devicetree/bindings/arm/qcom.yaml   |   1 +
 arch/arm64/boot/dts/qcom/Makefile                 |   1 +
 arch/arm64/boot/dts/qcom/sm8750-xiaomi-warsaw.dts | 258 ++++++++++++++++++++++
 3 files changed, 260 insertions(+)
---
base-commit: 6c377d19d4a5116d9bec5203aa3c6c11523e7898
change-id: 20261015-b4-warsaw-minimal-usb2-44808df9f2f3

Best regards,
--  
Jiaxi Zhang <z1529105815@outlook.com>


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

* [PATCH RFC v2 1/2] dt-bindings: arm: qcom: Add Xiaomi Warsaw
  2026-10-16 15:51 [PATCH RFC v2 0/2] arm64: dts: qcom: introduce minimal Xiaomi Warsaw support Zhang Jiaxi
@ 2026-10-16 15:53 ` Zhang Jiaxi
  2026-10-16 15:53 ` [PATCH RFC v2 2/2] arm64: dts: qcom: Add a minimal Xiaomi Warsaw description Zhang Jiaxi
  1 sibling, 0 replies; 5+ messages in thread
From: Zhang Jiaxi @ 2026-10-16 15:53 UTC (permalink / raw)
  To: Bjorn Andersson, Konrad Dybcio
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-arm-msm,
	devicetree, linux-kernel, Zhang Jiaxi

From: Jiaxi Zhang <z1529105815@outlook.com>

Document the Xiaomi Warsaw SM8750 handset compatible.

Assisted-by: LLM
Signed-off-by: Jiaxi Zhang <z1529105815@outlook.com>
---
 Documentation/devicetree/bindings/arm/qcom.yaml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/arm/qcom.yaml b/Documentation/devicetree/bindings/arm/qcom.yaml
index ff8a35df7..8932cc47d 100644
--- a/Documentation/devicetree/bindings/arm/qcom.yaml
+++ b/Documentation/devicetree/bindings/arm/qcom.yaml
@@ -1170,6 +1170,7 @@ properties:
           - enum:
               - qcom,sm8750-mtp
               - qcom,sm8750-qrd
+              - xiaomi,warsaw
           - const: qcom,sm8750
 
       - items:

-- 
2.55.0


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

* [PATCH RFC v2 2/2] arm64: dts: qcom: Add a minimal Xiaomi Warsaw description
  2026-10-16 15:51 [PATCH RFC v2 0/2] arm64: dts: qcom: introduce minimal Xiaomi Warsaw support Zhang Jiaxi
  2026-10-16 15:53 ` [PATCH RFC v2 1/2] dt-bindings: arm: qcom: Add Xiaomi Warsaw Zhang Jiaxi
@ 2026-10-16 15:53 ` Zhang Jiaxi
  2026-10-21 10:32   ` Konrad Dybcio
  1 sibling, 1 reply; 5+ messages in thread
From: Zhang Jiaxi @ 2026-10-16 15:53 UTC (permalink / raw)
  To: Bjorn Andersson, Konrad Dybcio
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-arm-msm,
	devicetree, linux-kernel, Zhang Jiaxi

From: Jiaxi Zhang <z1529105815@outlook.com>

Add the Warsaw board identity, reference clocks, PM8550/PMK8550
devices, key wiring and inherited debug UART route. Describe the board
from the SoC and PMIC includes instead of inheriting all MTP devices.

Describe the USB2 peripheral connection, its regulator supplies and
PMIH0108 repeater directly in the board source. Leave other peripheral
bring-up out of this initial description.

Usable RAM and firmware reservations remain a bootloader contract. Do
not encode captured memory banks, private firmware regions or an
Android command line in the board description.

Assisted-by: LLM
Signed-off-by: Jiaxi Zhang <z1529105815@outlook.com>
---
 arch/arm64/boot/dts/qcom/Makefile                 |   1 +
 arch/arm64/boot/dts/qcom/sm8750-xiaomi-warsaw.dts | 258 ++++++++++++++++++++++
 2 files changed, 259 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/Makefile b/arch/arm64/boot/dts/qcom/Makefile
index 1c86e7e98..23ac53888 100644
--- a/arch/arm64/boot/dts/qcom/Makefile
+++ b/arch/arm64/boot/dts/qcom/Makefile
@@ -408,6 +408,7 @@ dtb-$(CONFIG_ARCH_QCOM)	+= sm8650-mtp.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= sm8650-qrd.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= sm8750-mtp.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= sm8750-qrd.dtb
+dtb-$(CONFIG_ARCH_QCOM)	+= sm8750-xiaomi-warsaw.dtb
 dtb-$(CONFIG_ARCH_QCOM)	+= talos-evk.dtb
 
 talos-evk-el2-dtbs	:= talos-evk.dtb talos-el2.dtbo
diff --git a/arch/arm64/boot/dts/qcom/sm8750-xiaomi-warsaw.dts b/arch/arm64/boot/dts/qcom/sm8750-xiaomi-warsaw.dts
new file mode 100644
index 000000000..863e400d9
--- /dev/null
+++ b/arch/arm64/boot/dts/qcom/sm8750-xiaomi-warsaw.dts
@@ -0,0 +1,258 @@
+// SPDX-License-Identifier: BSD-3-Clause
+/*
+ * Copyright (c) 2024 Qualcomm Innovation Center, Inc. All rights reserved.
+ * Copyright (c) 2026 Jiaxi Zhang <z1529105815@outlook.com>
+ */
+
+/dts-v1/;
+
+#include <dt-bindings/clock/qcom,rpmh.h>
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
+#include "sm8750.dtsi"
+#include "pm8550.dtsi"
+#include "pmk8550.dtsi"
+
+/ {
+	model = "Xiaomi Warsaw";
+	compatible = "xiaomi,warsaw", "qcom,sm8750";
+	chassis-type = "handset";
+
+	aliases {
+		serial0 = &uart7;
+	};
+
+	chosen {
+		stdout-path = "serial0:115200n8";
+	};
+
+	clocks {
+		xo_board: xo-board {
+			compatible = "fixed-clock";
+			clock-frequency = <76800000>;
+			#clock-cells = <0>;
+		};
+
+		sleep_clk: sleep-clk {
+			compatible = "fixed-clock";
+			clock-frequency = <32000>;
+			#clock-cells = <0>;
+		};
+
+		bi_tcxo_div2: bi-tcxo-div2-clk {
+			compatible = "fixed-factor-clock";
+			#clock-cells = <0>;
+
+			clocks = <&rpmhcc RPMH_CXO_CLK>;
+			clock-mult = <1>;
+			clock-div = <2>;
+		};
+
+		bi_tcxo_ao_div2: bi-tcxo-ao-div2-clk {
+			compatible = "fixed-factor-clock";
+			#clock-cells = <0>;
+
+			clocks = <&rpmhcc RPMH_CXO_CLK_A>;
+			clock-mult = <1>;
+			clock-div = <2>;
+		};
+	};
+
+	gpio-keys {
+		compatible = "gpio-keys";
+
+		pinctrl-0 = <&volume_up_n>;
+		pinctrl-names = "default";
+
+		key-volume-up {
+			label = "Volume Up";
+			linux,code = <KEY_VOLUMEUP>;
+			gpios = <&pm8550_gpios 6 GPIO_ACTIVE_LOW>;
+			debounce-interval = <15>;
+			linux,can-disable;
+			wakeup-source;
+		};
+	};
+
+	vph_pwr: regulator-3v7 {
+		compatible = "regulator-fixed";
+		regulator-name = "vph_pwr";
+		regulator-min-microvolt = <3700000>;
+		regulator-max-microvolt = <3700000>;
+		regulator-always-on;
+		regulator-boot-on;
+	};
+};
+
+&pm8550_gpios {
+	volume_up_n: volume-up-n-state {
+		pins = "gpio6";
+		function = "normal";
+		bias-pull-up;
+		input-enable;
+		power-source = <1>;
+	};
+};
+
+&pon_pwrkey {
+	status = "okay";
+};
+
+&pon_resin {
+	linux,code = <KEY_VOLUMEDOWN>;
+
+	status = "okay";
+};
+
+&qupv3_1 {
+	status = "okay";
+};
+
+&uart7 {
+	status = "okay";
+};
+
+&tlmm {
+	/* GPIOs reserved by the Warsaw firmware. */
+	gpio-reserved-ranges = <36 4>, <48 4>, <74 1>;
+};
+
+&apps_rsc {
+	regulators-0 {
+		compatible = "qcom,pm8550-rpmh-regulators";
+		qcom,pmic-id = "b";
+		vdd-bob1-supply = <&vph_pwr>;
+		vdd-l5-l16-supply = <&vreg_bob1>;
+		vdd-l15-supply = <&vreg_s3g_1p8>;
+
+		vreg_bob1: bob1 {
+			regulator-name = "vreg_bob1";
+			regulator-min-microvolt = <3008000>;
+			regulator-max-microvolt = <4000000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l5b_3p1: ldo5 {
+			regulator-name = "vreg_l5b_3p1";
+			regulator-min-microvolt = <3100000>;
+			regulator-max-microvolt = <3148000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l15b_1p8: ldo15 {
+			regulator-name = "vreg_l15b_1p8";
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <1800000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+
+	regulators-1 {
+		compatible = "qcom,pm8550ve-rpmh-regulators";
+		qcom,pmic-id = "d";
+		vdd-s1-supply = <&vph_pwr>;
+		vdd-l2-supply = <&vreg_s1d_0p97>;
+
+		vreg_s1d_0p97: smps1 {
+			regulator-name = "vreg_s1d_0p97";
+			regulator-min-microvolt = <880000>;
+			regulator-max-microvolt = <1100000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l2d_0p88: ldo2 {
+			regulator-name = "vreg_l2d_0p88";
+			regulator-min-microvolt = <880000>;
+			regulator-max-microvolt = <912000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+
+	regulators-2 {
+		compatible = "qcom,pm8550ve-rpmh-regulators";
+		qcom,pmic-id = "g";
+		vdd-s3-supply = <&vph_pwr>;
+		vdd-l3-supply = <&vreg_s7i_1p2>;
+
+		vreg_s3g_1p8: smps3 {
+			regulator-name = "vreg_s3g_1p8";
+			regulator-min-microvolt = <1856000>;
+			regulator-max-microvolt = <2000000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM RPMH_REGULATOR_MODE_HPM>;
+		};
+
+		vreg_l3g_1p2: ldo3 {
+			regulator-name = "vreg_l3g_1p2";
+			regulator-min-microvolt = <1200000>;
+			regulator-max-microvolt = <1256000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+			regulator-allow-set-load;
+			regulator-allowed-modes = <RPMH_REGULATOR_MODE_LPM RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+
+	regulators-3 {
+		compatible = "qcom,pm8550ve-rpmh-regulators";
+		qcom,pmic-id = "i";
+		vdd-s7-supply = <&vph_pwr>;
+
+		vreg_s7i_1p2: smps7 {
+			regulator-name = "vreg_s7i_1p2";
+			regulator-min-microvolt = <1224000>;
+			regulator-max-microvolt = <1340000>;
+			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
+		};
+	};
+};
+
+&spmi_bus {
+	#address-cells = <2>;
+	#size-cells = <0>;
+
+	pmic@7 {
+		compatible = "qcom,pmih0108", "qcom,spmi-pmic";
+		reg = <7 0>;
+		#address-cells = <1>;
+		#size-cells = <0>;
+
+		eusb2_repeater: phy@fd00 {
+			compatible = "qcom,pm8550b-eusb2-repeater";
+			reg = <0xfd00>;
+			#phy-cells = <0>;
+
+			vdd18-supply = <&vreg_l15b_1p8>;
+			vdd3-supply = <&vreg_l5b_3p1>;
+
+			qcom,tune-usb2-preem = /bits/ 8 <3>;
+			qcom,tune-usb2-amplitude = /bits/ 8 <10>;
+			qcom,squelch-detector-bp = <(-2000)>;
+		};
+	};
+};
+
+&usb_hsphy {
+	vdd-supply = <&vreg_l2d_0p88>;
+	vdda12-supply = <&vreg_l3g_1p2>;
+	phys = <&eusb2_repeater>;
+
+	status = "okay";
+};
+
+&usb {
+	phys = <&usb_hsphy>;
+	phy-names = "usb2-phy";
+	dr_mode = "peripheral";
+	maximum-speed = "high-speed";
+	qcom,select-utmi-as-pipe-clk;
+
+	status = "okay";
+};

-- 
2.55.0


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

* Re: [PATCH RFC v2 2/2] arm64: dts: qcom: Add a minimal Xiaomi Warsaw description
  2026-10-16 15:53 ` [PATCH RFC v2 2/2] arm64: dts: qcom: Add a minimal Xiaomi Warsaw description Zhang Jiaxi
@ 2026-10-21 10:32   ` Konrad Dybcio
  2026-10-21 12:52     ` Zhang Jiaxi
  0 siblings, 1 reply; 5+ messages in thread
From: Konrad Dybcio @ 2026-10-21 10:32 UTC (permalink / raw)
  To: Zhang Jiaxi, Bjorn Andersson, Konrad Dybcio
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-arm-msm,
	devicetree, linux-kernel

On 10/16/26 5:53 PM, Zhang Jiaxi wrote:
> From: Jiaxi Zhang <z1529105815@outlook.com>
> 
> Add the Warsaw board identity, reference clocks, PM8550/PMK8550
> devices, key wiring and inherited debug UART route. Describe the board
> from the SoC and PMIC includes instead of inheriting all MTP devices.

[...]

> +	model = "Xiaomi Warsaw";

Google suggests that's "REDMI K90 Ultra", we usually put marketing
names in the model field

[...]

> +&qupv3_1 {
> +	status = "okay";
> +};
> +
> +&uart7 {
> +	status = "okay";
> +};

This node (and apps_rsc below) is out of alphabetical sorting order,
please touch that up:

https://docs.kernel.org/devicetree/bindings/dts-coding-style.html

> +
> +&tlmm {
> +	/* GPIOs reserved by the Warsaw firmware. */
> +	gpio-reserved-ranges = <36 4>, <48 4>, <74 1>;

Do we know what they correspond do? It's commongly NFC eSE, FP
scanner etc. If you do, please add a comment like the one in
glymur-crd.dtsi

[...]

> +&spmi_bus {
> +	#address-cells = <2>;
> +	#size-cells = <0>;
> +
> +	pmic@7 {

#include "pmih0108-kaanapali.dtsi" instead

[...]

> +&usb {
> +	phys = <&usb_hsphy>;
> +	phy-names = "usb2-phy";
> +	dr_mode = "peripheral";
> +	maximum-speed = "high-speed";
> +	qcom,select-utmi-as-pipe-clk;
> +
> +	status = "okay";

No SuperSpeed / DP altmode on this one?

Konrad

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

* RE: [PATCH RFC v2 2/2] arm64: dts: qcom: Add a minimal Xiaomi Warsaw description
  2026-10-21 10:32   ` Konrad Dybcio
@ 2026-10-21 12:52     ` Zhang Jiaxi
  0 siblings, 0 replies; 5+ messages in thread
From: Zhang Jiaxi @ 2026-10-21 12:52 UTC (permalink / raw)
  To: Konrad Dybcio, Bjorn Andersson
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-arm-msm,
	devicetree, linux-kernel

Hi Konrad,

Thank you for reviewing v2. I have posted RFC v3:
https://lore.kernel.org/all/20261021-b4-warsaw-minimal-usb2-v3-0-9f4213ab83ef@outlook.com/

It updates the model name, node ordering, common PMIC include and GPIO
reservation comments. The cover describes the revised DT's bounded
native core/USB test and the Codex/LLM assistance used.

USB remains restricted to High-Speed peripheral mode in this RFC. The OEM
configuration retains OTG/UCSI role switching, so this is not a claim of
peripheral-only hardware. I would appreciate your guidance on whether
that explicit initial restriction is acceptable, or USB should remain
disabled until the dual-role board integration is included.

Best regards,
Jiaxi

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

end of thread, other threads:[~2026-10-21 12:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-16 15:51 [PATCH RFC v2 0/2] arm64: dts: qcom: introduce minimal Xiaomi Warsaw support Zhang Jiaxi
2026-10-16 15:53 ` [PATCH RFC v2 1/2] dt-bindings: arm: qcom: Add Xiaomi Warsaw Zhang Jiaxi
2026-10-16 15:53 ` [PATCH RFC v2 2/2] arm64: dts: qcom: Add a minimal Xiaomi Warsaw description Zhang Jiaxi
2026-10-21 10:32   ` Konrad Dybcio
2026-10-21 12:52     ` Zhang Jiaxi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®