[PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO

Barnabás Czémán posted 5 patches 1 month ago
There is a newer version of this series
[PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by Barnabás Czémán 1 month ago
Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO (tiare),
it can be commonized for avoid unnecessary code duplications.

Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
---
 .../boot/dts/qcom/msm8917-xiaomi-riva-common.dtsi  | 317 +++++++++++++++++++++
 arch/arm64/boot/dts/qcom/msm8917-xiaomi-riva.dts   | 304 +-------------------
 2 files changed, 320 insertions(+), 301 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/msm8917-xiaomi-riva-common.dtsi b/arch/arm64/boot/dts/qcom/msm8917-xiaomi-riva-common.dtsi
new file mode 100644
index 000000000000..f0a534106e11
--- /dev/null
+++ b/arch/arm64/boot/dts/qcom/msm8917-xiaomi-riva-common.dtsi
@@ -0,0 +1,317 @@
+// SPDX-License-Identifier: GPL-2.0-only
+/*
+ * Copyright (c) 2023, Barnabas Czeman
+ */
+
+/dts-v1/;
+
+#include <dt-bindings/arm/qcom,ids.h>
+#include <dt-bindings/gpio/gpio.h>
+#include "msm8917.dtsi"
+#include "pm8937.dtsi"
+
+/delete-node/ &qseecom_mem;
+
+/ {
+	chassis-type = "handset";
+
+	qcom,msm-id = <QCOM_ID_MSM8917 0>;
+
+	pwm_backlight: backlight {
+		compatible = "pwm-backlight";
+		pwms = <&pm8937_pwm 0 100000>;
+		brightness-levels = <0 255>;
+		num-interpolated-steps = <255>;
+		default-brightness-level = <128>;
+	};
+
+	chosen {
+		#address-cells = <2>;
+		#size-cells = <2>;
+		ranges;
+
+		stdout-path = "framebuffer0";
+
+		framebuffer0: framebuffer@90001000 {
+			compatible = "simple-framebuffer";
+			reg = <0x0 0x90001000 0x0 (720 * 1280 * 3)>;
+			width = <720>;
+			height = <1280>;
+			stride = <(720 * 3)>;
+			format = "r8g8b8";
+
+			clocks = <&gcc GCC_MDSS_AHB_CLK>,
+				 <&gcc GCC_MDSS_AXI_CLK>,
+				 <&gcc GCC_MDSS_VSYNC_CLK>,
+				 <&gcc GCC_MDSS_MDP_CLK>,
+				 <&gcc GCC_MDSS_BYTE0_CLK>,
+				 <&gcc GCC_MDSS_PCLK0_CLK>,
+				 <&gcc GCC_MDSS_ESC0_CLK>;
+			power-domains = <&gcc MDSS_GDSC>;
+		};
+	};
+
+	gpio-keys {
+		compatible = "gpio-keys";
+
+		pinctrl-0 = <&gpio_keys_default>;
+		pinctrl-names = "default";
+
+		key-volup {
+			label = "Volume Up";
+			linux,code = <KEY_VOLUMEUP>;
+			gpios = <&tlmm 91 GPIO_ACTIVE_LOW>;
+			debounce-interval = <15>;
+		};
+	};
+
+	vph_pwr: regulator-vph-pwr {
+		compatible = "regulator-fixed";
+		regulator-name = "vph_pwr";
+		regulator-min-microvolt = <3700000>;
+		regulator-max-microvolt = <3700000>;
+		regulator-always-on;
+		regulator-boot-on;
+	};
+
+	reserved-memory {
+		qseecom_mem: qseecom@84a00000 {
+			reg = <0x0 0x84a00000 0x0 0x1900000>;
+			no-map;
+		};
+
+		framebuffer_mem: memory@90001000 {
+			reg = <0x0 0x90001000 0x0 (720 * 1280 * 3)>;
+			no-map;
+		};
+	};
+};
+
+&blsp1_i2c3 {
+	status = "okay";
+
+	edt_ft5306: touchscreen@38 {
+		compatible = "edt,edt-ft5306";
+		reg = <0x38>;
+		interrupts-extended = <&tlmm 65 IRQ_TYPE_LEVEL_LOW>;
+		reset-gpios = <&tlmm 64 GPIO_ACTIVE_LOW>;
+		pinctrl-0 = <&tsp_int_rst_default>;
+		pinctrl-names = "default";
+		vcc-supply = <&pm8937_l10>;
+		iovcc-supply = <&pm8937_l5>;
+		touchscreen-size-x = <720>;
+		touchscreen-size-y = <1280>;
+
+		status = "disabled";
+	};
+};
+
+&pm8937_gpios {
+	pwm_enable_default: pwm-enable-default-state {
+		pins = "gpio8";
+		function = "dtest2";
+		output-low;
+		bias-disable;
+		qcom,drive-strength = <2>;
+	};
+};
+
+&pm8937_pwm {
+	pinctrl-0 = <&pwm_enable_default>;
+	pinctrl-names = "default";
+
+	status = "okay";
+};
+
+&pm8937_resin {
+	linux,code = <KEY_VOLUMEDOWN>;
+
+	status = "okay";
+};
+
+&rpm_requests {
+	regulators-0 {
+		compatible = "qcom,rpm-pm8937-regulators";
+
+		vdd_s1-supply = <&vph_pwr>;
+		vdd_s2-supply = <&vph_pwr>;
+		vdd_s3-supply = <&vph_pwr>;
+		vdd_s4-supply = <&vph_pwr>;
+
+		vdd_l1_l19-supply = <&pm8937_s3>;
+		vdd_l2_l23-supply = <&pm8937_s3>;
+		vdd_l3-supply = <&pm8937_s3>;
+		vdd_l4_l5_l6_l7_l16-supply = <&pm8937_s4>;
+		vdd_l8_l11_l12_l17_l22-supply = <&vph_pwr>;
+		vdd_l9_l10_l13_l14_l15_l18-supply = <&vph_pwr>;
+
+		pm8937_s1: s1 {
+			regulator-min-microvolt = <1000000>;
+			regulator-max-microvolt = <1225000>;
+		};
+
+		pm8937_s3: s3 {
+			regulator-min-microvolt = <1300000>;
+			regulator-max-microvolt = <1300000>;
+		};
+
+		pm8937_s4: s4 {
+			regulator-min-microvolt = <2050000>;
+			regulator-max-microvolt = <2050000>;
+		};
+
+		pm8937_l2: l2 {
+			regulator-min-microvolt = <1200000>;
+			regulator-max-microvolt = <1200000>;
+		};
+
+		pm8937_l5: l5 {
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <1800000>;
+		};
+
+		pm8937_l6: l6 {
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <1800000>;
+		};
+
+		pm8937_l7: l7 {
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <1800000>;
+		};
+
+		pm8937_l8: l8 {
+			regulator-min-microvolt = <2850000>;
+			regulator-max-microvolt = <2900000>;
+		};
+
+		pm8937_l9: l9 {
+			regulator-min-microvolt = <3000000>;
+			regulator-max-microvolt = <3300000>;
+		};
+
+		pm8937_l10: l10 {
+			regulator-min-microvolt = <2800000>;
+			regulator-max-microvolt = <3000000>;
+		};
+
+		pm8937_l11: l11 {
+			regulator-min-microvolt = <2950000>;
+			regulator-max-microvolt = <2950000>;
+			regulator-allow-set-load;
+			regulator-system-load = <200000>;
+		};
+
+		pm8937_l12: l12 {
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <2950000>;
+		};
+
+		pm8937_l13: l13 {
+			regulator-min-microvolt = <3075000>;
+			regulator-max-microvolt = <3075000>;
+		};
+
+		pm8937_l14: l14 {
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <3300000>;
+		};
+
+		pm8937_l15: l15 {
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <3300000>;
+		};
+
+		pm8937_l16: l16 {
+			regulator-min-microvolt = <1800000>;
+			regulator-max-microvolt = <1800000>;
+		};
+
+		pm8937_l17: l17 {
+			regulator-min-microvolt = <2800000>;
+			regulator-max-microvolt = <2900000>;
+		};
+
+		pm8937_l19: l19 {
+			regulator-min-microvolt = <1225000>;
+			regulator-max-microvolt = <1350000>;
+		};
+
+		pm8937_l22: l22 {
+			regulator-min-microvolt = <2800000>;
+			regulator-max-microvolt = <2800000>;
+		};
+
+		pm8937_l23: l23 {
+			regulator-min-microvolt = <1200000>;
+			regulator-max-microvolt = <1200000>;
+		};
+	};
+};
+
+&sdhc_1 {
+	vmmc-supply = <&pm8937_l8>;
+	vqmmc-supply = <&pm8937_l5>;
+
+	status = "okay";
+};
+
+&sdhc_2 {
+	cd-gpios = <&tlmm 67 GPIO_ACTIVE_LOW>;
+	vmmc-supply = <&pm8937_l11>;
+	vqmmc-supply = <&pm8937_l12>;
+	pinctrl-0 = <&sdc2_default &sdc2_cd_default>;
+	pinctrl-1 = <&sdc2_sleep &sdc2_cd_default>;
+	pinctrl-names = "default", "sleep";
+
+	status = "okay";
+};
+
+&sleep_clk {
+	clock-frequency = <32768>;
+};
+
+&tlmm {
+	gpio_keys_default: gpio-keys-default-state {
+		pins = "gpio91";
+		function = "gpio";
+		drive-strength = <2>;
+		bias-pull-up;
+	};
+
+	sdc2_cd_default: sdc2-cd-default-state {
+		pins = "gpio67";
+		function = "gpio";
+		drive-strength = <2>;
+		bias-disable;
+	};
+
+	tsp_int_rst_default: tsp-int-rst-default-state {
+		pins = "gpio64", "gpio65";
+		function = "gpio";
+		drive-strength = <8>;
+		bias-pull-up;
+	};
+};
+
+&wcnss {
+	vddpx-supply = <&pm8937_l5>;
+
+	status = "okay";
+};
+
+&wcnss_iris {
+	compatible = "qcom,wcn3620";
+	vddxo-supply = <&pm8937_l7>;
+	vddrfa-supply = <&pm8937_l19>;
+	vddpa-supply = <&pm8937_l9>;
+	vdddig-supply = <&pm8937_l5>;
+};
+
+&wcnss_mem {
+	status = "okay";
+};
+
+&xo_board {
+	clock-frequency = <19200000>;
+};
diff --git a/arch/arm64/boot/dts/qcom/msm8917-xiaomi-riva.dts b/arch/arm64/boot/dts/qcom/msm8917-xiaomi-riva.dts
index 9db503e21888..564ec94d7f97 100644
--- a/arch/arm64/boot/dts/qcom/msm8917-xiaomi-riva.dts
+++ b/arch/arm64/boot/dts/qcom/msm8917-xiaomi-riva.dts
@@ -1,33 +1,18 @@
 // SPDX-License-Identifier: GPL-2.0-only
 /*
- * Copyright (c) 2023, Barnabas Czeman
+ * Copyright (c) 2026, Barnabas Czeman
  */
 
 /dts-v1/;
 
-#include <dt-bindings/arm/qcom,ids.h>
-#include <dt-bindings/gpio/gpio.h>
-#include "msm8917.dtsi"
-#include "pm8937.dtsi"
-
-/delete-node/ &qseecom_mem;
+#include "msm8917-xiaomi-riva-common.dtsi"
 
 / {
 	model = "Xiaomi Redmi 5A (riva)";
 	compatible = "xiaomi,riva", "qcom,msm8917";
-	chassis-type = "handset";
 
-	qcom,msm-id = <QCOM_ID_MSM8917 0>;
 	qcom,board-id = <0x1000b 2>, <0x2000b 2>;
 
-	pwm_backlight: backlight {
-		compatible = "pwm-backlight";
-		pwms = <&pm8937_pwm 0 100000>;
-		brightness-levels = <0 255>;
-		num-interpolated-steps = <255>;
-		default-brightness-level = <128>;
-	};
-
 	battery: battery {
 		compatible = "simple-battery";
 		charge-full-design-microamp-hours = <3000000>;
@@ -38,84 +23,6 @@ battery: battery {
 		charge-term-current-microamp = <60000>;
 		voltage-min-design-microvolt = <3400000>;
 	};
-
-	chosen {
-		#address-cells = <2>;
-		#size-cells = <2>;
-		ranges;
-
-		stdout-path = "framebuffer0";
-
-		framebuffer0: framebuffer@90001000 {
-			compatible = "simple-framebuffer";
-			reg = <0x0 0x90001000 0x0 (720 * 1280 * 3)>;
-			width = <720>;
-			height = <1280>;
-			stride = <(720 * 3)>;
-			format = "r8g8b8";
-
-			clocks = <&gcc GCC_MDSS_AHB_CLK>,
-				 <&gcc GCC_MDSS_AXI_CLK>,
-				 <&gcc GCC_MDSS_VSYNC_CLK>,
-				 <&gcc GCC_MDSS_MDP_CLK>,
-				 <&gcc GCC_MDSS_BYTE0_CLK>,
-				 <&gcc GCC_MDSS_PCLK0_CLK>,
-				 <&gcc GCC_MDSS_ESC0_CLK>;
-			power-domains = <&gcc MDSS_GDSC>;
-		};
-	};
-
-	gpio-keys {
-		compatible = "gpio-keys";
-
-		pinctrl-0 = <&gpio_keys_default>;
-		pinctrl-names = "default";
-
-		key-volup {
-			label = "Volume Up";
-			linux,code = <KEY_VOLUMEUP>;
-			gpios = <&tlmm 91 GPIO_ACTIVE_LOW>;
-			debounce-interval = <15>;
-		};
-	};
-
-	vph_pwr: regulator-vph-pwr {
-		compatible = "regulator-fixed";
-		regulator-name = "vph_pwr";
-		regulator-min-microvolt = <3700000>;
-		regulator-max-microvolt = <3700000>;
-		regulator-always-on;
-		regulator-boot-on;
-	};
-
-	reserved-memory {
-		qseecom_mem: qseecom@84a00000 {
-			reg = <0x0 0x84a00000 0x0 0x1900000>;
-			no-map;
-		};
-
-		framebuffer_mem: memory@90001000 {
-			reg = <0x0 0x90001000 0x0 (720 * 1280 * 3)>;
-			no-map;
-		};
-	};
-};
-
-&blsp1_i2c3 {
-	status = "okay";
-
-	touchscreen@38 {
-		compatible = "edt,edt-ft5306";
-		reg = <0x38>;
-		interrupts-extended = <&tlmm 65 IRQ_TYPE_LEVEL_LOW>;
-		reset-gpios = <&tlmm 64 GPIO_ACTIVE_LOW>;
-		pinctrl-0 = <&tsp_int_rst_default>;
-		pinctrl-names = "default";
-		vcc-supply = <&pm8937_l10>;
-		iovcc-supply = <&pm8937_l5>;
-		touchscreen-size-x = <720>;
-		touchscreen-size-y = <1280>;
-	};
 };
 
 &blsp2_i2c1 {
@@ -139,172 +46,10 @@ bq25601@6b {
 	};
 };
 
-&pm8937_gpios {
-	pwm_enable_default: pwm-enable-default-state {
-		pins = "gpio8";
-		function = "dtest2";
-		output-low;
-		bias-disable;
-		qcom,drive-strength = <2>;
-	};
-};
-
-&pm8937_pwm {
-	pinctrl-0 = <&pwm_enable_default>;
-	pinctrl-names = "default";
-
-	status = "okay";
-};
-
-&pm8937_resin {
-	linux,code = <KEY_VOLUMEDOWN>;
-
-	status = "okay";
-};
-
-&rpm_requests {
-	regulators-0 {
-		compatible = "qcom,rpm-pm8937-regulators";
-
-		vdd_s1-supply = <&vph_pwr>;
-		vdd_s2-supply = <&vph_pwr>;
-		vdd_s3-supply = <&vph_pwr>;
-		vdd_s4-supply = <&vph_pwr>;
-
-		vdd_l1_l19-supply = <&pm8937_s3>;
-		vdd_l2_l23-supply = <&pm8937_s3>;
-		vdd_l3-supply = <&pm8937_s3>;
-		vdd_l4_l5_l6_l7_l16-supply = <&pm8937_s4>;
-		vdd_l8_l11_l12_l17_l22-supply = <&vph_pwr>;
-		vdd_l9_l10_l13_l14_l15_l18-supply = <&vph_pwr>;
-
-		pm8937_s1: s1 {
-			regulator-min-microvolt = <1000000>;
-			regulator-max-microvolt = <1225000>;
-		};
-
-		pm8937_s3: s3 {
-			regulator-min-microvolt = <1300000>;
-			regulator-max-microvolt = <1300000>;
-		};
-
-		pm8937_s4: s4 {
-			regulator-min-microvolt = <2050000>;
-			regulator-max-microvolt = <2050000>;
-		};
-
-		pm8937_l2: l2 {
-			regulator-min-microvolt = <1200000>;
-			regulator-max-microvolt = <1200000>;
-		};
-
-		pm8937_l5: l5 {
-			regulator-min-microvolt = <1800000>;
-			regulator-max-microvolt = <1800000>;
-		};
-
-		pm8937_l6: l6 {
-			regulator-min-microvolt = <1800000>;
-			regulator-max-microvolt = <1800000>;
-		};
-
-		pm8937_l7: l7 {
-			regulator-min-microvolt = <1800000>;
-			regulator-max-microvolt = <1800000>;
-		};
-
-		pm8937_l8: l8 {
-			regulator-min-microvolt = <2850000>;
-			regulator-max-microvolt = <2900000>;
-		};
-
-		pm8937_l9: l9 {
-			regulator-min-microvolt = <3000000>;
-			regulator-max-microvolt = <3300000>;
-		};
-
-		pm8937_l10: l10 {
-			regulator-min-microvolt = <2800000>;
-			regulator-max-microvolt = <3000000>;
-		};
-
-		pm8937_l11: l11 {
-			regulator-min-microvolt = <2950000>;
-			regulator-max-microvolt = <2950000>;
-			regulator-allow-set-load;
-			regulator-system-load = <200000>;
-		};
-
-		pm8937_l12: l12 {
-			regulator-min-microvolt = <1800000>;
-			regulator-max-microvolt = <2950000>;
-		};
-
-		pm8937_l13: l13 {
-			regulator-min-microvolt = <3075000>;
-			regulator-max-microvolt = <3075000>;
-		};
-
-		pm8937_l14: l14 {
-			regulator-min-microvolt = <1800000>;
-			regulator-max-microvolt = <3300000>;
-		};
-
-		pm8937_l15: l15 {
-			regulator-min-microvolt = <1800000>;
-			regulator-max-microvolt = <3300000>;
-		};
-
-		pm8937_l16: l16 {
-			regulator-min-microvolt = <1800000>;
-			regulator-max-microvolt = <1800000>;
-		};
-
-		pm8937_l17: l17 {
-			regulator-min-microvolt = <2800000>;
-			regulator-max-microvolt = <2900000>;
-		};
-
-		pm8937_l19: l19 {
-			regulator-min-microvolt = <1225000>;
-			regulator-max-microvolt = <1350000>;
-		};
-
-		pm8937_l22: l22 {
-			regulator-min-microvolt = <2800000>;
-			regulator-max-microvolt = <2800000>;
-		};
-
-		pm8937_l23: l23 {
-			regulator-min-microvolt = <1200000>;
-			regulator-max-microvolt = <1200000>;
-		};
-	};
-
-};
-
-&sdhc_1 {
-	vmmc-supply = <&pm8937_l8>;
-	vqmmc-supply = <&pm8937_l5>;
-
+&edt_ft5306 {
 	status = "okay";
 };
 
-&sdhc_2 {
-	cd-gpios = <&tlmm 67 GPIO_ACTIVE_LOW>;
-	vmmc-supply = <&pm8937_l11>;
-	vqmmc-supply = <&pm8937_l12>;
-	pinctrl-0 = <&sdc2_default &sdc2_cd_default>;
-	pinctrl-1 = <&sdc2_sleep &sdc2_cd_default>;
-	pinctrl-names = "default", "sleep";
-
-	status = "okay";
-};
-
-&sleep_clk {
-	clock-frequency = <32768>;
-};
-
 &tlmm {
 	bq25601_int_default: bq25601-int-default-state {
 		pins = "gpio61";
@@ -312,47 +57,4 @@ bq25601_int_default: bq25601-int-default-state {
 		drive-strength = <2>;
 		bias-pull-up;
 	};
-
-	gpio_keys_default: gpio-keys-default-state {
-		pins = "gpio91";
-		function = "gpio";
-		drive-strength = <2>;
-		bias-pull-up;
-	};
-
-	sdc2_cd_default: sdc2-cd-default-state {
-		pins = "gpio67";
-		function = "gpio";
-		drive-strength = <2>;
-		bias-disable;
-	};
-
-	tsp_int_rst_default: tsp-int-rst-default-state {
-		pins = "gpio64", "gpio65";
-		function = "gpio";
-		drive-strength = <8>;
-		bias-pull-up;
-	};
-};
-
-&wcnss {
-	vddpx-supply = <&pm8937_l5>;
-
-	status = "okay";
-};
-
-&wcnss_iris {
-	compatible = "qcom,wcn3620";
-	vddxo-supply = <&pm8937_l7>;
-	vddrfa-supply = <&pm8937_l19>;
-	vddpa-supply = <&pm8937_l9>;
-	vdddig-supply = <&pm8937_l5>;
-};
-
-&wcnss_mem {
-	status = "okay";
-};
-
-&xo_board {
-	clock-frequency = <19200000>;
 };

-- 
2.53.0

Re: [PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by Konrad Dybcio 1 month ago
On 3/5/26 6:28 PM, Barnabás Czémán wrote:
> Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO (tiare),
> it can be commonized for avoid unnecessary code duplications.
> 
> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
> ---

Could you please try adding the following to your gitconfig:

[diff]
        renameLimit = 999999
        algorithm = histogram # or 'copies'
        renames = copies

and see if this generates a shorter diff?

Konrad
Re: [PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by barnabas.czeman@mainlining.org 1 month ago
On 2026-03-09 13:55, Konrad Dybcio wrote:
> On 3/5/26 6:28 PM, Barnabás Czémán wrote:
>> Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO (tiare),
>> it can be commonized for avoid unnecessary code duplications.
>> 
>> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
>> ---
> 
> Could you please try adding the following to your gitconfig:
> 
> [diff]
>         renameLimit = 999999
>         algorithm = histogram # or 'copies'
>         renames = copies
> 
> and see if this generates a shorter diff?
> 
> Konrad
One more question should i rename msm8917-xiaomi-riva-common to 
msm8917-wingtech-common,
they are wingtech devices. Which naming is preferred?
They have wingtech name also:
S88503 - Redmi 4A (rolex)
S88505 - Redmi 5A (riva)
S88508 - Redmi Go (tiare)
Re: [PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by Konrad Dybcio 1 month ago
On 3/10/26 1:57 PM, barnabas.czeman@mainlining.org wrote:
> On 2026-03-09 13:55, Konrad Dybcio wrote:
>> On 3/5/26 6:28 PM, Barnabás Czémán wrote:
>>> Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO (tiare),
>>> it can be commonized for avoid unnecessary code duplications.
>>>
>>> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
>>> ---
>>
>> Could you please try adding the following to your gitconfig:
>>
>> [diff]
>>         renameLimit = 999999
>>         algorithm = histogram # or 'copies'
>>         renames = copies
>>
>> and see if this generates a shorter diff?
>>
>> Konrad
> One more question should i rename msm8917-xiaomi-riva-common to msm8917-wingtech-common,
> they are wingtech devices. Which naming is preferred?

I think xiaomi-riva is easier for people to associate with a phone
they may have in their drawer than wingtech-s88503

Konrad
Re: [PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by barnabas.czeman@mainlining.org 1 month ago
On 2026-03-10 14:04, Konrad Dybcio wrote:
> On 3/10/26 1:57 PM, barnabas.czeman@mainlining.org wrote:
>> On 2026-03-09 13:55, Konrad Dybcio wrote:
>>> On 3/5/26 6:28 PM, Barnabás Czémán wrote:
>>>> Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO (tiare),
>>>> it can be commonized for avoid unnecessary code duplications.
>>>> 
>>>> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
>>>> ---
>>> 
>>> Could you please try adding the following to your gitconfig:
>>> 
>>> [diff]
>>>         renameLimit = 999999
>>>         algorithm = histogram # or 'copies'
>>>         renames = copies
>>> 
>>> and see if this generates a shorter diff?
>>> 
>>> Konrad
>> One more question should i rename msm8917-xiaomi-riva-common to 
>> msm8917-wingtech-common,
>> they are wingtech devices. Which naming is preferred?
> 
> I think xiaomi-riva is easier for people to associate with a phone
> they may have in their drawer than wingtech-s88503
What about renaming just the common part to msm8917-wingtech-common?
> 
> Konrad
Re: [PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by Konrad Dybcio 1 month ago
On 3/10/26 2:11 PM, barnabas.czeman@mainlining.org wrote:
> On 2026-03-10 14:04, Konrad Dybcio wrote:
>> On 3/10/26 1:57 PM, barnabas.czeman@mainlining.org wrote:
>>> On 2026-03-09 13:55, Konrad Dybcio wrote:
>>>> On 3/5/26 6:28 PM, Barnabás Czémán wrote:
>>>>> Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO (tiare),
>>>>> it can be commonized for avoid unnecessary code duplications.
>>>>>
>>>>> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
>>>>> ---
>>>>
>>>> Could you please try adding the following to your gitconfig:
>>>>
>>>> [diff]
>>>>         renameLimit = 999999
>>>>         algorithm = histogram # or 'copies'
>>>>         renames = copies
>>>>
>>>> and see if this generates a shorter diff?
>>>>
>>>> Konrad
>>> One more question should i rename msm8917-xiaomi-riva-common to msm8917-wingtech-common,
>>> they are wingtech devices. Which naming is preferred?
>>
>> I think xiaomi-riva is easier for people to associate with a phone
>> they may have in their drawer than wingtech-s88503
> What about renaming just the common part to msm8917-wingtech-common?

I think it adds more confusion without much benefit. Probably none
of these devices have been released without a Mi logo on the back.

Konrad
Re: [PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by barnabas.czeman@mainlining.org 1 month ago
On 2026-03-10 14:21, Konrad Dybcio wrote:
> On 3/10/26 2:11 PM, barnabas.czeman@mainlining.org wrote:
>> On 2026-03-10 14:04, Konrad Dybcio wrote:
>>> On 3/10/26 1:57 PM, barnabas.czeman@mainlining.org wrote:
>>>> On 2026-03-09 13:55, Konrad Dybcio wrote:
>>>>> On 3/5/26 6:28 PM, Barnabás Czémán wrote:
>>>>>> Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO 
>>>>>> (tiare),
>>>>>> it can be commonized for avoid unnecessary code duplications.
>>>>>> 
>>>>>> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
>>>>>> ---
>>>>> 
>>>>> Could you please try adding the following to your gitconfig:
>>>>> 
>>>>> [diff]
>>>>>         renameLimit = 999999
>>>>>         algorithm = histogram # or 'copies'
>>>>>         renames = copies
>>>>> 
>>>>> and see if this generates a shorter diff?
>>>>> 
>>>>> Konrad
>>>> One more question should i rename msm8917-xiaomi-riva-common to 
>>>> msm8917-wingtech-common,
>>>> they are wingtech devices. Which naming is preferred?
>>> 
>>> I think xiaomi-riva is easier for people to associate with a phone
>>> they may have in their drawer than wingtech-s88503
>> What about renaming just the common part to msm8917-wingtech-common?
> 
> I think it adds more confusion without much benefit. Probably none
> of these devices have been released without a Mi logo on the back.
Yes but riva codename is related to Redmi 5A and naming as 
msm8917-xiaomi-common
could cause confusion later when i would send Redmi Note 5A (ugglite) 
what is
none wingtech device and have much more difference.
> 
> Konrad
Re: [PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by Konrad Dybcio 1 month ago
On 3/10/26 2:26 PM, barnabas.czeman@mainlining.org wrote:
> On 2026-03-10 14:21, Konrad Dybcio wrote:
>> On 3/10/26 2:11 PM, barnabas.czeman@mainlining.org wrote:
>>> On 2026-03-10 14:04, Konrad Dybcio wrote:
>>>> On 3/10/26 1:57 PM, barnabas.czeman@mainlining.org wrote:
>>>>> On 2026-03-09 13:55, Konrad Dybcio wrote:
>>>>>> On 3/5/26 6:28 PM, Barnabás Czémán wrote:
>>>>>>> Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO (tiare),
>>>>>>> it can be commonized for avoid unnecessary code duplications.
>>>>>>>
>>>>>>> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
>>>>>>> ---
>>>>>>
>>>>>> Could you please try adding the following to your gitconfig:
>>>>>>
>>>>>> [diff]
>>>>>>         renameLimit = 999999
>>>>>>         algorithm = histogram # or 'copies'
>>>>>>         renames = copies
>>>>>>
>>>>>> and see if this generates a shorter diff?
>>>>>>
>>>>>> Konrad
>>>>> One more question should i rename msm8917-xiaomi-riva-common to msm8917-wingtech-common,
>>>>> they are wingtech devices. Which naming is preferred?
>>>>
>>>> I think xiaomi-riva is easier for people to associate with a phone
>>>> they may have in their drawer than wingtech-s88503
>>> What about renaming just the common part to msm8917-wingtech-common?
>>
>> I think it adds more confusion without much benefit. Probably none
>> of these devices have been released without a Mi logo on the back.
> Yes but riva codename is related to Redmi 5A and naming as msm8917-xiaomi-common
> could cause confusion later when i would send Redmi Note 5A (ugglite) what is
> none wingtech device and have much more difference.

Well, you never mentioned that!

perhaps msm8917-xiaomi-wingtech.dtsi then?

Konrad
Re: [PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by barnabas.czeman@mainlining.org 1 month ago
On 2026-03-09 13:55, Konrad Dybcio wrote:
> On 3/5/26 6:28 PM, Barnabás Czémán wrote:
>> Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO (tiare),
>> it can be commonized for avoid unnecessary code duplications.
>> 
>> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
>> ---
> 
> Could you please try adding the following to your gitconfig:
> 
> [diff]
>         renameLimit = 999999
>         algorithm = histogram # or 'copies'
>         renames = copies
> 
> and see if this generates a shorter diff?
It is inverting the diff there will be less change in 
msm8917-xiaomi-riva-common.dtsi
and a lot of deletion in msm8917-xiaomi-riva.dts.

I can split the commit in that case rename will be shown properly but 
riva devicetree
will be removed temporarily.
> 
> Konrad
Re: [PATCH 1/5] arm64: dts: qcom: msm8917-xiaomi-riva: Commonize for Redmi 4A and GO
Posted by Krzysztof Kozlowski 1 month ago
On Thu, Mar 05, 2026 at 06:28:33PM +0100, Barnabás Czémán wrote:
> Redmi 5A is very similar for Redmi 4A (rolex) and Redmi GO (tiare),
> it can be commonized for avoid unnecessary code duplications.
> 
> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
> ---
>  .../boot/dts/qcom/msm8917-xiaomi-riva-common.dtsi  | 317 +++++++++++++++++++++
>  arch/arm64/boot/dts/qcom/msm8917-xiaomi-riva.dts   | 304 +-------------------

Difficult to review. Use proper b4 configuration or flags for
format-patch to generate rename.

Best regards,
Krzysztof