User Requested Fixes for Anbernic RGxx3
Subsystems (2)
cover User Requested Fixes for Anbernic RGxx3
From: Chris Morgan <[email protected]>
Users have requested fixes for Anbernic devices to help with some intermittent WiFi issues by adding additional properties to the SDMMC2 node and by making the sdmmc aliases consistent across the device lineup. They have also requested that the model name be represented consistently with both the manufacturer name and model name.
I have added the new/additional property of "chasis-type" as well.
Chris Morgan (4):
arm64: dts: rockchip: rgxx3: Add additional properties for WiFi
arm64: dts: rockchip: rgxx3: Add optional node for chasis-type
arm64: dts: rockchip: Correct RGxx3 SDMMC ordering
arm64: dts: rockchip: Correct model name for Anbernic RGxx3 Devices
.../boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts | 7 ------- .../boot/dts/rockchip/rk3566-anbernic-rg-arc-s.dts | 6 ------ .../boot/dts/rockchip/rk3566-anbernic-rg353p.dts | 9 +-------- .../boot/dts/rockchip/rk3566-anbernic-rg353ps.dts | 8 +------- .../boot/dts/rockchip/rk3566-anbernic-rg353v.dts | 9 +-------- .../boot/dts/rockchip/rk3566-anbernic-rg353vs.dts | 8 +------- .../boot/dts/rockchip/rk3566-anbernic-rg503.dts | 8 +------- .../boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi | 12 ++++++++++++ 8 files changed, 17 insertions(+), 50 deletions(-)
Signature · 1 line
2.34.1
PATCH 1/4 arm64: dts: rockchip: rgxx3: Add additional properties for WiFi
From: Chris Morgan <[email protected]>
Add additional properties for the SDMMC2 node. Based on user feedback these help correct some issues with probing the WiFi hardware.
--- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi | 3 +++ 1 file changed, 3 insertions(+)
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi +3 -0
@@ -623,9 +623,12 @@ &sdmmc2 { cap-sdio-irq; keep-power-in-suspend; mmc-pwrseq = <&sdio_pwrseq>; + no-mmc; + no-sd; non-removable; pinctrl-0 = <&sdmmc2m0_bus4 &sdmmc2m0_cmd &sdmmc2m0_clk>; pinctrl-names = "default"; + sd-uhs-sdr50; vmmc-supply = <&vcc_wifi>; vqmmc-supply = <&vcca1v8_pmu>; status = "okay";
Signature · 1 line
2.34.1
PATCH 2/4 arm64: dts: rockchip: rgxx3: Add optional node for chasis-type
In reply to Chris MorganFrom: Chris Morgan <[email protected]>
Add optional node for chasis-type defining this device as a handset.
--- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi | 2 ++ 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi +2 -0
@@ -10,6 +10,8 @@ #include "rk3566.dtsi" / { + chassis-type = "handset"; + chosen: chosen { stdout-path = "serial2:1500000n8"; };
Signature · 1 line
2.34.1
PATCH 3/4 arm64: dts: rockchip: Correct RGxx3 SDMMC ordering
In reply to Chris MorganFrom: Chris Morgan <[email protected]>
Make the order of SDMMC predictable across the entire device lineup. This allows userspace to always know that sdmmc0 is the eMMC (when present), sdmmc1 is always the first sd card slot, sdmmc2 is always the 2nd sd card slot (when present), and sdmmc3 is always the wifi (when present).
--- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts | 7 ------- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-s.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353p.dts | 7 ------- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353ps.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353v.dts | 7 ------- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353vs.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg503.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi | 7 +++++++ 8 files changed, 7 insertions(+), 45 deletions(-)
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts +0 -7
@@ -10,13 +10,6 @@ / { model = "Anbernic RG ARC-D"; compatible = "anbernic,rg-arc-d", "rockchip,rk3566"; - - aliases { - mmc0 = &sdhci; - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; }; &i2c2 {
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-s.dts +0 -6
@@ -10,10 +10,4 @@ / { model = "Anbernic RG ARC-S"; compatible = "anbernic,rg-arc-s", "rockchip,rk3566"; - - aliases { - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; };
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353p.dts +0 -7
@@ -11,13 +11,6 @@ / { model = "RG353P"; compatible = "anbernic,rg353p", "rockchip,rk3566"; - aliases { - mmc0 = &sdhci; - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3472000>;
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353ps.dts +0 -6
@@ -11,12 +11,6 @@ / { model = "RG353PS"; compatible = "anbernic,rg353ps", "rockchip,rk3566"; - aliases { - mmc0 = &sdmmc0; - mmc1 = &sdmmc1; - mmc2 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3472000>;
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353v.dts +0 -7
@@ -11,13 +11,6 @@ / { model = "RG353V"; compatible = "anbernic,rg353v", "rockchip,rk3566"; - aliases { - mmc0 = &sdhci; - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3151000>;
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353vs.dts +0 -6
@@ -11,12 +11,6 @@ / { model = "RG353VS"; compatible = "anbernic,rg353vs", "rockchip,rk3566"; - aliases { - mmc0 = &sdmmc0; - mmc1 = &sdmmc1; - mmc2 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3151000>;
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg503.dts +0 -6
@@ -11,12 +11,6 @@ / { model = "RG503"; compatible = "anbernic,rg503", "rockchip,rk3566"; - aliases { - mmc0 = &sdmmc0; - mmc1 = &sdmmc1; - mmc2 = &sdmmc2; - }; - adc-joystick { compatible = "adc-joystick"; io-channels = <&adc_mux 0>,
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi +7 -0
@@ -12,6 +12,13 @@ / { chassis-type = "handset"; + aliases { + mmc0 = &sdhci; + mmc1 = &sdmmc0; + mmc2 = &sdmmc1; + mmc3 = &sdmmc2; + }; + chosen: chosen { stdout-path = "serial2:1500000n8"; };
Signature · 1 line
2.34.1
Heiko Stübner
maintainerRe: [PATCH 3/4] arm64: dts: rockchip: Correct RGxx3 SDMMC ordering
Hmm,
Am Montag, 25. März 2024, 15:37:28 CET schrieb Chris Morgan:
Quoted 9 lines
From: Chris Morgan <[email protected]>
Make the order of SDMMC predictable across the entire device lineup. This allows userspace to always know that sdmmc0 is the eMMC (when present), sdmmc1 is always the first sd card slot, sdmmc2 is always the 2nd sd card slot (when present), and sdmmc3 is always the wifi (when present).
Signed-off-by Chris Morgan <[email protected]>
this is really really difficult.
For example, you added the rg353p, rk503 nad rg353vs and their aliases two years ago for 6.1 , the rg353ps for 6.5. So someone might actually rely on those already in their userspace setup.
So reorganizing the aliases to point to different devices might actually break userspace, which as you might know, is sort of a big deal ;-) .
Userspace programs can determine the mmc mapping via the board-compatible though.
Heiko
Quoted 150 lines
--- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts | 7 ------- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-s.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353p.dts | 7 ------- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353ps.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353v.dts | 7 ------- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353vs.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg503.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi | 7 +++++++ 8 files changed, 7 insertions(+), 45 deletions(-)arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts +0
-7@@ -10,13 +10,6 @@ / { model = "Anbernic RG ARC-D"; compatible = "anbernic,rg-arc-d", "rockchip,rk3566"; - - aliases { - mmc0 = &sdhci; - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; }; &i2c2 {arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-s.dts +0
-6@@ -10,10 +10,4 @@ / { model = "Anbernic RG ARC-S"; compatible = "anbernic,rg-arc-s", "rockchip,rk3566"; - - aliases { - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; };arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353p.dts +0
-7@@ -11,13 +11,6 @@ / { model = "RG353P"; compatible = "anbernic,rg353p", "rockchip,rk3566"; - aliases { - mmc0 = &sdhci; - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3472000>;arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353ps.dts +0
-6@@ -11,12 +11,6 @@ / { model = "RG353PS"; compatible = "anbernic,rg353ps", "rockchip,rk3566"; - aliases { - mmc0 = &sdmmc0; - mmc1 = &sdmmc1; - mmc2 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3472000>;arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353v.dts +0
-7@@ -11,13 +11,6 @@ / { model = "RG353V"; compatible = "anbernic,rg353v", "rockchip,rk3566"; - aliases { - mmc0 = &sdhci; - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3151000>;arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353vs.dts +0
-6@@ -11,12 +11,6 @@ / { model = "RG353VS"; compatible = "anbernic,rg353vs", "rockchip,rk3566"; - aliases { - mmc0 = &sdmmc0; - mmc1 = &sdmmc1; - mmc2 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3151000>;arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg503.dts +0
-6@@ -11,12 +11,6 @@ / { model = "RG503"; compatible = "anbernic,rg503", "rockchip,rk3566"; - aliases { - mmc0 = &sdmmc0; - mmc1 = &sdmmc1; - mmc2 = &sdmmc2; - }; - adc-joystick { compatible = "adc-joystick"; io-channels = <&adc_mux 0>,arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi +7
-0@@ -12,6 +12,13 @@ / { chassis-type = "handset"; + aliases { + mmc0 = &sdhci; + mmc1 = &sdmmc0; + mmc2 = &sdmmc1; + mmc3 = &sdmmc2; + }; + chosen: chosen { stdout-path = "serial2:1500000n8"; };
Re: [PATCH 3/4] arm64: dts: rockchip: Correct RGxx3 SDMMC ordering
Quoted 19 lines · Heiko Stübner
Hmm,
Am Montag, 25. März 2024, 15:37:28 CET schrieb Chris Morgan:
Quoted 9 lines
From: Chris Morgan <[email protected]>
Make the order of SDMMC predictable across the entire device lineup. This allows userspace to always know that sdmmc0 is the eMMC (when present), sdmmc1 is always the first sd card slot, sdmmc2 is always the 2nd sd card slot (when present), and sdmmc3 is always the wifi (when present).
Signed-off-by Chris Morgan <[email protected]>this is really really difficult.
For example, you added the rg353p, rk503 nad rg353vs and their aliases two years ago for 6.1 , the rg353ps for 6.5. So someone might actually rely on those already in their userspace setup.
Quoted 5 lines
So reorganizing the aliases to point to different devices might actually break userspace, which as you might know, is sort of a big deal ;-) .
Userspace programs can determine the mmc mapping via the board-compatible though.
Okay, then this might need to be disregarded. Perhaps at a minimum we can set the WiFi device to be mmc3 at least for a consistent basis. That was the main driver of this request and shouldn't be a major concern for userspace. Would that work?
Thank you.
Quoted 158 lines
Heiko
Quoted 150 lines
--- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts | 7 ------- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-s.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353p.dts | 7 ------- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353ps.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353v.dts | 7 ------- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353vs.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg503.dts | 6 ------ arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi | 7 +++++++ 8 files changed, 7 insertions(+), 45 deletions(-)arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts +0
-7@@ -10,13 +10,6 @@ / { model = "Anbernic RG ARC-D"; compatible = "anbernic,rg-arc-d", "rockchip,rk3566"; - - aliases { - mmc0 = &sdhci; - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; }; &i2c2 {arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-s.dts +0
-6@@ -10,10 +10,4 @@ / { model = "Anbernic RG ARC-S"; compatible = "anbernic,rg-arc-s", "rockchip,rk3566"; - - aliases { - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; };arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353p.dts +0
-7@@ -11,13 +11,6 @@ / { model = "RG353P"; compatible = "anbernic,rg353p", "rockchip,rk3566"; - aliases { - mmc0 = &sdhci; - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3472000>;arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353ps.dts +0
-6@@ -11,12 +11,6 @@ / { model = "RG353PS"; compatible = "anbernic,rg353ps", "rockchip,rk3566"; - aliases { - mmc0 = &sdmmc0; - mmc1 = &sdmmc1; - mmc2 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3472000>;arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353v.dts +0
-7@@ -11,13 +11,6 @@ / { model = "RG353V"; compatible = "anbernic,rg353v", "rockchip,rk3566"; - aliases { - mmc0 = &sdhci; - mmc1 = &sdmmc0; - mmc2 = &sdmmc1; - mmc3 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3151000>;arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353vs.dts +0
-6@@ -11,12 +11,6 @@ / { model = "RG353VS"; compatible = "anbernic,rg353vs", "rockchip,rk3566"; - aliases { - mmc0 = &sdmmc0; - mmc1 = &sdmmc1; - mmc2 = &sdmmc2; - }; - battery: battery { compatible = "simple-battery"; charge-full-design-microamp-hours = <3151000>;arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg503.dts +0
-6@@ -11,12 +11,6 @@ / { model = "RG503"; compatible = "anbernic,rg503", "rockchip,rk3566"; - aliases { - mmc0 = &sdmmc0; - mmc1 = &sdmmc1; - mmc2 = &sdmmc2; - }; - adc-joystick { compatible = "adc-joystick"; io-channels = <&adc_mux 0>,arch/arm64/boot/dts/rockchip/rk3566-anbernic-rgxx3.dtsi +7
-0@@ -12,6 +12,13 @@ / { chassis-type = "handset"; + aliases { + mmc0 = &sdhci; + mmc1 = &sdmmc0; + mmc2 = &sdmmc1; + mmc3 = &sdmmc2; + }; + chosen: chosen { stdout-path = "serial2:1500000n8"; };
PATCH 4/4 arm64: dts: rockchip: Correct model name for Anbernic RGxx3 Devices
In reply to Chris MorganFrom: Chris Morgan <[email protected]>
Some Anbernic model names begin with the company "Anbernic" and others simply list the model number. Make this consistent across the device lineup by including the manufacturer in the model name.
--- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353p.dts | 2 +- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353ps.dts | 2 +- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353v.dts | 2 +- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353vs.dts | 2 +- arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg503.dts | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-)
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353p.dts +1 -1
@@ -8,7 +8,7 @@ #include "rk3566-anbernic-rg353x.dtsi" / { - model = "RG353P"; + model = "Anbernic RG353P"; compatible = "anbernic,rg353p", "rockchip,rk3566"; battery: battery {
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353ps.dts +1 -1
@@ -8,7 +8,7 @@ #include "rk3566-anbernic-rg353x.dtsi" / { - model = "RG353PS"; + model = "Anbernic RG353PS"; compatible = "anbernic,rg353ps", "rockchip,rk3566"; battery: battery {
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353v.dts +1 -1
@@ -8,7 +8,7 @@ #include "rk3566-anbernic-rg353x.dtsi" / { - model = "RG353V"; + model = "Anbernic RG353V"; compatible = "anbernic,rg353v", "rockchip,rk3566"; battery: battery {
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg353vs.dts +1 -1
@@ -8,7 +8,7 @@ #include "rk3566-anbernic-rg353x.dtsi" / { - model = "RG353VS"; + model = "Anbernic RG353VS"; compatible = "anbernic,rg353vs", "rockchip,rk3566"; battery: battery {
arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg503.dts +1 -1
@@ -8,7 +8,7 @@ #include "rk3566-anbernic-rgxx3.dtsi" / { - model = "RG503"; + model = "Anbernic RG503"; compatible = "anbernic,rg503", "rockchip,rk3566"; adc-joystick {
Signature · 1 line
2.34.1
Re: (subset) [PATCH 0/4] User Requested Fixes for Anbernic RGxx3
In reply to Chris MorganQuoted 10 lines · Chris Morgan
From: Chris Morgan <[email protected]>
Users have requested fixes for Anbernic devices to help with some intermittent WiFi issues by adding additional properties to the SDMMC2 node and by making the sdmmc aliases consistent across the device lineup. They have also requested that the model name be represented consistently with both the manufacturer name and model name.
[...]
Applied, thanks!
[1/4] arm64: dts: rockchip: rgxx3: Add additional properties for WiFi
commit: 6bc8e01c7284ea1f56c6506f38c2ba9474db497a
[2/4] arm64: dts: rockchip: rgxx3: Add optional node for chasis-type
commit: 8db673210ae24ed44acf15642f4abd6d4b4cae52
[4/4] arm64: dts: rockchip: Correct model name for Anbernic RGxx3 Devices
commit: b41b83b701056421bdc494c8e1488d38f2990c3dDropped the sdmmc alias patch.
Best regards,
Signature · 1 line
Heiko Stuebner <[email protected]>
Re: (subset) [PATCH 0/4] User Requested Fixes for Anbernic RGxx3
Quoted 14 lines · Heiko Stuebner
Quoted 10 lines · Chris Morgan
From: Chris Morgan <[email protected]>
Users have requested fixes for Anbernic devices to help with some intermittent WiFi issues by adding additional properties to the SDMMC2 node and by making the sdmmc aliases consistent across the device lineup. They have also requested that the model name be represented consistently with both the manufacturer name and model name.
[...]
Applied, thanks!
Quoted 8 lines
[1/4] arm64: dts: rockchip: rgxx3: Add additional properties for WiFi
commit: 6bc8e01c7284ea1f56c6506f38c2ba9474db497a [2/4] arm64: dts: rockchip: rgxx3: Add optional node for chasis-type commit: 8db673210ae24ed44acf15642f4abd6d4b4cae52 [4/4] arm64: dts: rockchip: Correct model name for Anbernic RGxx3 Devices commit: b41b83b701056421bdc494c8e1488d38f2990c3dDropped the sdmmc alias patch.
Thank you. At a minimum, could we reorder the non-boot mmc devices? To at least ensure that the wifi is always mmc3? If so, I can submit that patch again.
Quoted 4 lines
Best regards,
Signature · 1 line
Heiko Stuebner <[email protected]>