Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions config/sources/families/sun55iw3.conf
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ declare -g LINUXCONFIG="linux-sunxi64-${BRANCH}"
case "${BRANCH}" in

edge)
declare -g KERNEL_MAJOR_MINOR="6.16" # Major and minor versions of this kernel.
declare -g KERNELBRANCH="tag:v6.16"
declare -g KERNEL_MAJOR_MINOR="6.18" # Major and minor versions of this kernel.
declare -g KERNELBRANCH="tag:v6.18-rc4"
Comment on lines +28 to +29
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

Critical: Kernel version contradicts maintainer feedback and PR objectives.

The PR description states patches support "both Linux 6.17 and 6.18-rc3," but igorpecovnik's comment explicitly identified a "configuration bug" and provided the intended fix: KERNEL_MAJOR_MINOR="6.17" and KERNELBRANCH="tag:v6.17.7". The current code sets these to "6.18" and "tag:v6.18-rc4" respectively, which:

  1. Contradicts the maintainer's intended configuration (6.17.7 stable, not 6.18-rc4)
  2. Shows only edge branch support, with no visible current branch for 6.17
  3. Uses 6.18-rc4 instead of the tested 6.18-rc3 mentioned in the PR description

Based on igorpecovnik's feedback, apply this diff to use the stable 6.17.7 release:

-		declare -g KERNEL_MAJOR_MINOR="6.18" # Major and minor versions of this kernel.
-		declare -g KERNELBRANCH="tag:v6.18-rc4"
+		declare -g KERNEL_MAJOR_MINOR="6.17" # Major and minor versions of this kernel.
+		declare -g KERNELBRANCH="tag:v6.17.7"

If both 6.17 and 6.18 support is needed, please clarify whether a separate current branch case should be added or if only edge (6.17) is intended at this time.

🤖 Prompt for AI Agents
In config/sources/families/sun55iw3.conf around lines 28-29, the kernel
variables are incorrect for the maintainer-intended configuration; update
KERNEL_MAJOR_MINOR to "6.17" and KERNELBRANCH to "tag:v6.17.7" to match
igorpecovnik's feedback (stable 6.17.7), and if support for both 6.17 and 6.18
is required instead, add a clear branching/`current` case to select between the
two versions rather than leaving the file pointing to 6.18-rc4.

declare -g KERNELPATCHDIR="archive/sunxi-dev-${KERNEL_MAJOR_MINOR}"
;;
esac
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Juan Sanchez <[email protected]>
Date: Sat, 14 Jun 2025 19:07:52 -0400
Subject: Add leds to Radxa Cubie A5E

Signed-off-by: Juan Sanchez <[email protected]>
---
arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts | 16 ++++++++++
1 file changed, 16 insertions(+)

diff --git a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts b/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
index 0f58d92a6adc..1c56306dffa1 100644
--- a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
+++ b/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
@@ -18,10 +18,26 @@ aliases {

chosen {
stdout-path = "serial0:115200n8";
};

+ leds {
+ compatible = "gpio-leds";
+
+ led-0 {
+ label = "radxa:green:power";
+ gpios = <&r_pio 0 4 GPIO_ACTIVE_LOW>; /* PL4 */
+ linux,default-trigger = "heartbeat";
+ };
+
+ led-1 {
+ label = "radxa:blue:user";
+ gpios = <&r_pio 0 5 GPIO_ACTIVE_LOW>; /* PL5 */
+ linux,default-trigger = "default-on";
+ };
+ };
+
ext_osc32k: ext-osc32k-clk {
#clock-cells = <0>;
compatible = "fixed-clock";
clock-frequency = <32768>;
clock-output-names = "ext_osc32k";
--
Created with Armbian build tools https://github.com/armbian/build

Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Juan Sanchez <[email protected]>
Date: Fri, 4 Jul 2025 15:17:54 -0400
Subject: Add wifi (mmc1) to Radxa Cubie A5E

Signed-off-by: Juan Sanchez <[email protected]>
---
arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts | 28 ++++++++++
1 file changed, 28 insertions(+)

diff --git a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts b/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
index 1c56306dffa1..d9bbfb916090 100644
--- a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
+++ b/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
@@ -11,10 +11,11 @@ / {
model = "Radxa Cubie A5E";
compatible = "radxa,cubie-a5e", "allwinner,sun55i-a527";

aliases {
ethernet0 = &gmac0;
+ ethernet2 = &sdio_wifi;
serial0 = &uart0;
};

chosen {
stdout-path = "serial0:115200n8";
@@ -41,10 +42,20 @@ ext_osc32k: ext-osc32k-clk {
compatible = "fixed-clock";
clock-frequency = <32768>;
clock-output-names = "ext_osc32k";
};

+ reg_3v3_wifi: 3v3-wifi {
+ compatible = "regulator-fixed";
+ regulator-name = "3v3-wifi";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ vin-supply = <&reg_vcc5v>;
+ gpio = <&r_pio 0 7 GPIO_ACTIVE_HIGH>; /* PL7 */
+ enable-active-high;
+ };
+
reg_vcc5v: vcc5v {
/* board wide 5V supply from the USB-C connector */
compatible = "regulator-fixed";
regulator-name = "vcc-5v";
regulator-min-microvolt = <5000000>;
@@ -94,10 +105,27 @@ &mmc0 {
cd-gpios = <&pio 5 6 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PF6 */
bus-width = <4>;
status = "okay";
};

+&mmc1_pins {
+ drive-strength = <40>;
+};
+
+&mmc1 {
+ bus-width = <4>;
+ vmmc-supply = <&reg_3v3_wifi>;
+ non-removable;
+ // todo: investigate why clock above 40MHz makes data errors
+ max-frequency = <35000000>;
+ status = "okay";
+
+ sdio_wifi: wifi@1 {
+ reg = <1>;
+ };
+};
+
&ohci0 {
status = "okay";
};

&ohci1 {
--
Created with Armbian build tools https://github.com/armbian/build

Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
From: Chen-Yu Tsai <[email protected]>

The external Ethernet PHY has a reset pin that is connected to the SoC.
It is missing from the original submission.

Add it to complete the description.

Fixes: acca163f3f51 ("arm64: dts: allwinner: a527: add EMAC0 to Radxa A5E board")
Signed-off-by: Chen-Yu Tsai <[email protected]>
---
arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts | 3 +++
1 file changed, 3 insertions(+)

diff --git a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts b/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
index 8bc0f2c72a24..c57ecc420aed 100644
--- a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
+++ b/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
@@ -70,6 +70,9 @@ &mdio0 {
ext_rgmii_phy: ethernet-phy@1 {
compatible = "ethernet-phy-ieee802.3-c22";
reg = <1>;
+ reset-gpios = <&pio 7 8 GPIO_ACTIVE_LOW>; /* PH8 */
+ reset-assert-us = <10000>;
+ reset-deassert-us = <150000>;
};
};

--
2.39.5
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Juan Sanchez <[email protected]>
Date: Sat, 5 Jul 2025 22:59:14 -0400
Subject: From: Chen-Yu Tsai <[email protected]>

Signed-off-by: Juan Sanchez <[email protected]>
---
arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts | 26 +++++++++-
1 file changed, 24 insertions(+), 2 deletions(-)

diff --git a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts b/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
index 76e41202ecc8..592a50436454 100644
--- a/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
+++ b/arch/arm64/boot/dts/allwinner/sun55i-a527-cubie-a5e.dts
@@ -11,10 +11,11 @@ / {
model = "Radxa Cubie A5E";
compatible = "radxa,cubie-a5e", "allwinner,sun55i-a527";

aliases {
ethernet0 = &gmac0;
+ ethernet1 = &gmac1;
ethernet2 = &sdio_wifi;
serial0 = &uart0;
};

chosen {
@@ -86,7 +86,7 @@ &ehci1 {

&gmac0 {
phy-mode = "rgmii-id";
- phy-handle = <&ext_rgmii_phy>;
+ phy-handle = <&ext_rgmii0_phy>;
phy-supply = <&reg_cldo3>;

allwinner,tx-delay-ps = <300>;
@@ -95,19 +95,40 @@ &gmac0 {
status = "okay";
};

+&gmac1 {
+ phy-mode = "rgmii-id";
+ phy-handle = <&ext_rgmii1_phy>;
+ phy-supply = <&reg_cldo4>;
+
+ allwinner,tx-delay-ps = <300>;
+ allwinner,rx-delay-ps = <400>;
+
+ status = "okay";
+};
+
&gpu {
mali-supply = <&reg_dcdc2>;
status = "okay";
};

&mdio0 {
- ext_rgmii_phy: ethernet-phy@1 {
+ ext_rgmii0_phy: ethernet-phy@1 {
compatible = "ethernet-phy-ieee802.3-c22";
reg = <1>;
reset-gpios = <&pio 7 8 GPIO_ACTIVE_LOW>; /* PH8 */
reset-assert-us = <10000>;
reset-deassert-us = <150000>;
};
+};
+
+&mdio1 {
+ ext_rgmii1_phy: ethernet-phy@1 {
+ compatible = "ethernet-phy-ieee802.3-c22";
+ reg = <1>;
+ reset-gpios = <&pio 9 16 GPIO_ACTIVE_LOW>; /* PJ16 */
+ reset-assert-us = <10000>;
+ reset-deassert-us = <150000>;
+ };
};

&mmc0 {
--
Created with Armbian build tools https://github.com/armbian/build

Original file line number Diff line number Diff line change
@@ -0,0 +1,134 @@
From: Chen-Yu Tsai <[email protected]>

The Allwinner A523 SoC family has a second Ethernet controller, called
the GMAC200 in the BSP and T527 datasheet, and referred to as GMAC1 for
numbering. This controller, according to BSP sources, is fully
compatible with a slightly newer version of the Synopsys DWMAC core.
The glue layer around the controller is the same as found around older
DWMAC cores on Allwinner SoCs. The only slight difference is that since
this is the second controller on the SoC, the register for the clock
delay controls is at a different offset. Last, the integration includes
a dedicated clock gate for the memory bus and the whole thing is put in
a separately controllable power domain.

Add a compatible string entry for it, and work in the requirements for
a second clock and a power domain.

Signed-off-by: Chen-Yu Tsai <[email protected]>
---
.../net/allwinner,sun8i-a83t-emac.yaml | 68 ++++++++++++++++++-
1 file changed, 66 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/net/allwinner,sun8i-a83t-emac.yaml b/Documentation/devicetree/bindings/net/allwinner,sun8i-a83t-emac.yaml
index 2ac709a4c472..1058e5af92ba 100644
--- a/Documentation/devicetree/bindings/net/allwinner,sun8i-a83t-emac.yaml
+++ b/Documentation/devicetree/bindings/net/allwinner,sun8i-a83t-emac.yaml
@@ -26,6 +26,9 @@ properties:
- allwinner,sun50i-h616-emac0
- allwinner,sun55i-a523-gmac0
- const: allwinner,sun50i-a64-emac
+ - items:
+ - const: allwinner,sun55i-a523-gmac200
+ - const: snps,dwmac-4.20a

reg:
maxItems: 1
@@ -37,14 +40,19 @@ properties:
const: macirq

clocks:
- maxItems: 1
+ minItems: 1
+ maxItems: 2

clock-names:
- const: stmmaceth
+ minItems: 1
+ maxItems: 2

phy-supply:
description: PHY regulator

+ power-domains:
+ maxItems: 1
+
syscon:
$ref: /schemas/types.yaml#/definitions/phandle
description:
@@ -75,6 +83,7 @@ allOf:
- allwinner,sun8i-h3-emac
- allwinner,sun8i-v3s-emac
- allwinner,sun50i-a64-emac
+ - allwinner,sun55i-a523-gmac200

then:
properties:
@@ -191,6 +200,31 @@ allOf:
- mdio-parent-bus
- mdio@1

+ - if:
+ properties:
+ compatible:
+ contains:
+ const: allwinner,sun55i-a523-gmac200
+ then:
+ properties:
+ clocks:
+ minItems: 2
+ clock-names:
+ items:
+ - const: stmmaceth
+ - const: mbus
+ required:
+ - power-domains
+ else:
+ properties:
+ clocks:
+ maxItems: 1
+ clock-names:
+ items:
+ - const: stmmaceth
+ power-domains: false
+
+
unevaluatedProperties: false

examples:
@@ -323,4 +357,34 @@ examples:
};
};

+ - |
+ ethernet@4510000 {
+ compatible = "allwinner,sun55i-a523-gmac200",
+ "snps,dwmac-4.20a";
+ reg = <0x04510000 0x10000>;
+ clocks = <&ccu 117>, <&ccu 79>;
+ clock-names = "stmmaceth", "mbus";
+ resets = <&ccu 43>;
+ reset-names = "stmmaceth";
+ interrupts = <0 47 4>;
+ interrupt-names = "macirq";
+ pinctrl-names = "default";
+ pinctrl-0 = <&rgmii1_pins>;
+ power-domains = <&pck600 4>;
+ syscon = <&syscon>;
+ phy-handle = <&ext_rgmii_phy_1>;
+ phy-mode = "rgmii-id";
+ snps,fixed-burst;
+ snps,axi-config = <&gmac1_stmmac_axi_setup>;
+
+ mdio {
+ compatible = "snps,dwmac-mdio";
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ ext_rgmii_phy_1: ethernet-phy@1 {
+ reg = <1>;
+ };
+ };
+ };
...
--
2.39.5
Loading