Yeah, but your device shows the PHY links are up in mdio while mine doesnât. Hence, the stock fw doesnât have 2 DPs enabled but only one connected to Port 6 (combined with Port 0) on the switch.
@hzyitc Redmi AX3000 has got both connected via the PHYs and MAC to MAC. Guess these devices are just wired up differently.
From his email:
root@OpenWrt:/# mdio 8*
DEV PHY-ID LINK
...
0x07 0x004dd0c0 up
...
root@OpenWrt:/# mdio 9*
DEV PHY-ID LINK
0x00 0x004dd036 down
0x01 0x004dd036 up
0x02 0x004dd036 down
0x03 0x004dd036 down
0x04 0x004dd036 up
understood, but what I'm highlighting here is that on the Redmi AX3000 the PHY links are reported is 'up' while on the Linksys MX2000 it's 'down'. Same PHY ids on both ends (see previous posts). So Linksys chose not to physically wire the PHYs up and only opted for the MAC to MAC link, while Redmi has chosen both links through PHYs and MAC to MAC.
Anyone has got any ideas as to why swconfig doesnât detect the switches in 6.1 while it does work in 5.15 on @hzyitcâs repo?
I did try rolling back netifd to an earlier version as suggested but that didnât help either.
At least Iâve confirmed how the device is wired and tested that traffic flows through Port 0 and 6 on the qca8337 to and from GMAC1 on the ipq5018 switch (MAC to MAC).
Maybe the GEPhy in your device connected directly to the WAN port? The SGMII port only work in 1G mode with QCA8337, so if the GEPhy isn't used, the bidirectional bandwidth will be limited to 1Gbps instand of 2Gbps.
on 1. there's a multi-CPU patch for the qca8337 driver
on 2. I figure you'd essentially describe it as the example below:
port@5 {
reg = <5>; <--- on your device it would be port 5
label = "cpu";
ethernet = <&gmac1>; <--- phandle to your dp1 alias
phy-mode = "sgmii";
fixed-link { <--- not sure this will be needed
speed = <1000>;
full-duplex;
};
};
have finally got the switch to work, thought I was going nuts because I had gone from borrowing 'some' of @hzyitc's code to literally everything line by line and it still didn't work. Compared nss-dp and ssdk versions, they're all the same. It was only after I rolled back the kernel version from 5.15.134 to 5.15.120 with the associated patches in target/linux/generic that the switch started working. I haven't figured out when and where the code breaks, but in .134 the RX counters on the LAN ports stayed at 0 while TX counters showed traffic.
Anyone knows what might have changed between .120 and .134 that could have caused this?
be aware, haven't had the need and/or courage to flash yet. I'd rather wait until the redesigned QPIC driver has been submitted fully rather than the hack it is now. First few patches were submitted yesterday: [RFC,0/5] Add QPIC SPI NAND driver support - Patchwork (kernel.org)
will now focus on adding wifi (ipq5018, qcn6122, qcn9074) and DSA support.
@hzyitc: did you manage to check in your code with support for DSA?
I've just started working with the DR5018 router board from WallysTech and have been following your progress with interest.
I have not ported OpenWrt to a new board before so I was wondering if you would be able to provide a high level overview of the steps you have followed? This would help me and anyone else interested to start the process.