Ah ok, then you can use 6.6…for upstreaming you have to use latest net-next
On R3 you will need:
Together with the other patches. From 6.8, phylink_pcs_neg_mode() has moved to phylink.c So you may have to change the name of the function, if you want to use it below 6.8.
So, I am still trying to make the SFP work on Debian with my BPI-R3. I apply all the patches I think. SFP is now detected :
[ 1.374294] sfp sfp-1: Host maximum power 3.0W
[ 1.379261] sfp sfp-2: Host maximum power 3.0W
[ 1.512721] mtk_soc_eth 15100000.ethernet: generated random MAC address 06:27:b6:80:ad:2a
[ 1.522925] mtk_soc_eth 15100000.ethernet eth0: mediatek frame engine at 0xffffffc083300000, irq 123
[ 1.532776] mtk_soc_eth 15100000.ethernet eth1: mediatek frame engine at 0xffffffc083300000, irq 123
[ 1.542384] usbcore: registered new interface driver usb-storage
[ 1.548573] i2c_dev: i2c /dev entries driver
[ 1.555053] mtk-wdt 1001c000.watchdog: Watchdog enabled (timeout=31 sec, nowayout=0)
[ 1.563772] SMCCC: SOC_ID: ID = jep106:0426:7986 Revision = 0x00000000
[ 1.570400] usbcore: registered new interface driver usbhid
[ 1.575982] usbhid: USB HID core driver
[ 1.580260] NET: Registered PF_INET6 protocol family
[ 1.585818] Segment Routing with IPv6
[ 1.589495] In-situ OAM (IOAM) with IPv6
[ 1.593449] sit: IPv6, IPv4 and MPLS over IPv4 tunneling driver
[ 1.599737] NET: Registered PF_PACKET protocol family
[ 1.604955] 8021q: 802.1Q VLAN Support v1.8
[ 1.617597] Loading compiled-in X.509 certificates
[ 1.633751] mtk-pcie-gen3 11280000.pcie: host bridge /soc/pcie@11280000 ranges:
[ 1.641076] mtk-pcie-gen3 11280000.pcie: Parsing ranges property...
[ 1.647408] mtk-pcie-gen3 11280000.pcie: MEM 0x0020000000..0x002fffffff -> 0x0020000000
[ 1.711182] sfp sfp-1: module FS SFP-2.5G-T rev 1.0 sn G2340039491 dc 231101
[ 1.871493] mtk-pcie-gen3 11280000.pcie: PCIe link down, current LTSSM state: detect.active (0x1000001)
[ 1.880905] mtk-pcie-gen3: probe of 11280000.pcie failed with error -110
[ 1.940641] mt7530-mdio mdio-bus:1f: configuring for fixed/2500base-x link mode
[ 1.949792] mt7530-mdio mdio-bus:1f: Link is Up - 2.5Gbps/Full - flow control rx/tx
[ 1.958480] mt7530-mdio mdio-bus:1f wan (uninitialized): PHY [mt7530-0:00] driver [MediaTek MT7531 PHY] (irq=128)
[ 1.978957] mt7530-mdio mdio-bus:1f lan0 (uninitialized): PHY [mt7530-0:01] driver [MediaTek MT7531 PHY] (irq=129)
[ 1.999095] mt7530-mdio mdio-bus:1f lan1 (uninitialized): PHY [mt7530-0:02] driver [MediaTek MT7531 PHY] (irq=130)
[ 2.019244] mt7530-mdio mdio-bus:1f lan2 (uninitialized): PHY [mt7530-0:03] driver [MediaTek MT7531 PHY] (irq=131)
[ 2.039409] mt7530-mdio mdio-bus:1f lan3 (uninitialized): PHY [mt7530-0:04] driver [MediaTek MT7531 PHY] (irq=132)
[ 2.050790] mtk_soc_eth 15100000.ethernet eth0: entered promiscuous mode
[ 2.057540] DSA: tree 0 setup
[ 2.060978] xhci-mtk 11200000.usb: supply vbus not found, using dummy regulator
[ 2.068382] xhci-mtk 11200000.usb: supply vusb33 not found, using dummy regulator
[ 2.076821] xhci-mtk 11200000.usb: xHCI Host Controller
[ 2.082079] xhci-mtk 11200000.usb: new USB bus registered, assigned bus number 1
[ 2.092439] xhci-mtk 11200000.usb: hcc params 0x01403f99 hci version 0x110 quirks 0x0000000000200010
[ 2.101609] xhci-mtk 11200000.usb: irq 133, io mem 0x11200000
[ 2.107433] xhci-mtk 11200000.usb: xHCI Host Controller
[ 2.112658] xhci-mtk 11200000.usb: new USB bus registered, assigned bus number 2
[ 2.120041] xhci-mtk 11200000.usb: Host supports USB 3.2 Enhanced SuperSpeed
[ 2.127564] hub 1-0:1.0: USB hub found
[ 2.131332] hub 1-0:1.0: 2 ports detected
[ 2.135689] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
[ 2.144170] hub 2-0:1.0: USB hub found
[ 2.147946] hub 2-0:1.0: 1 port detected
[ 2.153529] clk: Disabling unused clocks
[ 2.180303] Waiting for root device /dev/mmcblk0p6...
[ 2.214990] mmc0: host does not support reading read-only switch, assuming write-enable
[ 2.226819] mmc0: new high speed SDHC card at address aaaa
[ 2.233143] mmcblk0: mmc0:aaaa SA08G 7.40 GiB
[ 2.246414] mmcblk0: p1 p2 p3 p4 p5 p6
[ 2.263397] EXT4-fs (mmcblk0p6): INFO: recovery required on readonly filesystem
[ 2.270711] EXT4-fs (mmcblk0p6): write access will be enabled during recovery
[ 2.581512] usb 1-1: new high-speed USB device number 2 using xhci-mtk
[ 2.762304] hub 1-1:1.0: USB hub found
[ 2.766109] hub 1-1:1.0: 4 ports detected
[ 2.870731] EXT4-fs (mmcblk0p6): recovery complete
[ 2.878313] EXT4-fs (mmcblk0p6): mounted filesystem c4133c1c-a36b-48da-952a-43ee4e59dcfb ro with ordered data mode. Quota mode: disabled.
[ 2.890687] VFS: Mounted root (ext4 filesystem) readonly on device 179:6.
[ 2.899559] devtmpfs: mounted
[ 2.904021] Freeing unused kernel memory: 4480K
[ 2.908636] Run /sbin/init as init process
[ 2.912767] with arguments:
[ 2.915723] /sbin/init
[ 2.918418] with environment:
[ 2.921552] HOME=/
[ 2.923900] TERM=linux
[ 2.926595] board=bpi-r3
[ 3.829267] systemd[1]: System time before build time, advancing clock.
[ 3.883826] systemd[1]: Failed to find module 'autofs4'
[ 4.070276] systemd[1]: systemd 252.19-1~deb12u1 running in system mode (+PAM +AUDIT +SELINUX +APPARMOR +IMA +SMACK +SECCOMP +GCRYPT -GNUTLS +OPENSSL +ACL +BLKID +CURL +ELFUTILS +FIDO2 +IDN2 -IDN +IPTC +KMOD +LIBCRYPTSETUP +LIBFDISK +PCRE2 -PWQUALITY +P11KIT +QRENCODE +TPM2 +BZIP2 +LZ4 +XZ +ZLIB +ZSTD -BPF_FRAMEWORK -XKBCOMMON +UTMP +SYSVINIT default-hierarchy=unified)
[ 4.102974] systemd[1]: Detected architecture arm64.
[ 4.147870] systemd[1]: Hostname set to <bpi-r3>.
[ 4.792753] systemd[1]: Queued start job for default target graphical.target.
[ 4.799921] systemd[1]: Unnecessary job was removed for sys-subsystem-net-devices-wlan0.device - /sys/subsystem/net/devices/wlan0.
[ 4.811690] systemd[1]: Unnecessary job was removed for sys-subsystem-net-devices-wlan1.device - /sys/subsystem/net/devices/wlan1.
[ 4.863694] systemd[1]: Created slice system-getty.slice - Slice /system/getty.
[ 4.902657] systemd[1]: Created slice system-hostapd.slice - Slice /system/hostapd.
[ 4.942575] systemd[1]: Created slice system-modprobe.slice - Slice /system/modprobe.
[ 4.982600] systemd[1]: Created slice system-serial\x2dgetty.slice - Slice /system/serial-getty.
[ 5.022308] systemd[1]: Created slice user.slice - User and Session Slice.
[ 5.061835] systemd[1]: Started systemd-ask-password-console.path - Dispatch Password Requests to Console Directory Watch.
[ 5.101725] systemd[1]: Started systemd-ask-password-wall.path - Forward Password Requests to Wall Directory Watch.
[ 5.141661] systemd[1]: proc-sys-fs-binfmt_misc.automount - Arbitrary Executable File Formats File System Automount Point was skipped because of an unmet condition check (ConditionPathExists=/proc/sys/fs/binfmt_misc).
[ 5.161077] systemd[1]: Reached target cryptsetup.target - Local Encrypted Volumes.
[ 5.201610] systemd[1]: Reached target integritysetup.target - Local Integrity Protected Volumes.
[ 5.241623] systemd[1]: Reached target paths.target - Path Units.
[ 5.281587] systemd[1]: Reached target remote-fs.target - Remote File Systems.
[ 5.321578] systemd[1]: Reached target slices.target - Slice Units.
[ 5.361583] systemd[1]: Reached target swap.target - Swaps.
[ 5.401581] systemd[1]: Reached target veritysetup.target - Local Verity Protected Volumes.
[ 5.441830] systemd[1]: Listening on systemd-initctl.socket - initctl Compatibility Named Pipe.
[ 5.487782] systemd[1]: systemd-journald-audit.socket - Journal Audit Socket was skipped because of an unmet condition check (ConditionSecurity=audit).
[ 5.501979] systemd[1]: Listening on systemd-journald-dev-log.socket - Journal Socket (/dev/log).
[ 5.542004] systemd[1]: Listening on systemd-journald.socket - Journal Socket.
[ 5.582138] systemd[1]: Listening on systemd-networkd.socket - Network Service Netlink Socket.
[ 5.622078] systemd[1]: Listening on systemd-udevd-control.socket - udev Control Socket.
[ 5.661912] systemd[1]: Listening on systemd-udevd-kernel.socket - udev Kernel Socket.
[ 5.701966] systemd[1]: dev-hugepages.mount - Huge Pages File System was skipped because of an unmet condition check (ConditionPathExists=/sys/kernel/mm/hugepages).
[ 5.761732] systemd[1]: Mounting dev-mqueue.mount - POSIX Message Queue File System...
[ 5.804088] systemd[1]: Mounting sys-kernel-debug.mount - Kernel Debug File System...
[ 5.844070] systemd[1]: Mounting sys-kernel-tracing.mount - Kernel Trace File System...
[ 5.884656] systemd[1]: Starting kmod-static-nodes.service - Create List of Static Device Nodes...
[ 5.924469] systemd[1]: Starting [email protected] - Load Kernel Module configfs...
[ 5.964429] systemd[1]: Starting modprobe@dm_mod.service - Load Kernel Module dm_mod...
[ 6.004471] systemd[1]: Starting [email protected] - Load Kernel Module drm...
[ 6.044457] systemd[1]: Starting modprobe@efi_pstore.service - Load Kernel Module efi_pstore...
[ 6.084475] systemd[1]: Starting [email protected] - Load Kernel Module fuse...
[ 6.124720] systemd[1]: Starting [email protected] - Load Kernel Module loop...
[ 6.162276] systemd[1]: systemd-journald.service: unit configures an IP firewall, but the local system does not support BPF/cgroup firewalling.
[ 6.175179] systemd[1]: (This warning is only shown for the first unit using IP firewalling.)
[ 6.186119] systemd[1]: Starting systemd-journald.service - Journal Service...
[ 6.351770] fuse: init (API version 7.39)
[ 6.381912] systemd[1]: Starting systemd-modules-load.service - Load Kernel Modules...
[ 6.434269] systemd[1]: Starting systemd-network-generator.service - Generate network units from Kernel command line...
[ 6.494294] systemd[1]: Starting systemd-remount-fs.service - Remount Root and Kernel File Systems...
[ 6.534434] systemd[1]: Starting systemd-udev-trigger.service - Coldplug All udev Devices...
[ 6.573803] EXT4-fs (mmcblk0p6): re-mounted c4133c1c-a36b-48da-952a-43ee4e59dcfb r/w. Quota mode: disabled.
[ 6.588219] systemd[1]: Started systemd-journald.service - Journal Service.
[ 7.319999] systemd-journald[1458]: Received client request to flush runtime journal.
[ 7.331869] systemd-journald[1458]: File /var/log/journal/dc93093cb66c4760ac05b4224ae2d753/system.journal corrupted or uncleanly shut down, renaming and replacing.
[ 9.015403] mtdblock: MTD device 'ubi' is NAND, please consider using UBI block devices instead.
[ 9.021333] mtdblock: MTD device 'reserved' is NAND, please consider using UBI block devices instead.
[ 9.043727] mtdblock: MTD device 'fip' is NAND, please consider using UBI block devices instead.
[ 9.052936] mtdblock: MTD device 'bl2' is NAND, please consider using UBI block devices instead.
[ 10.601638] FAT-fs (mmcblk0p5): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
[ 10.605037] cfg80211: Loading compiled-in X.509 certificates for regulatory database
[ 10.632162] Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
[ 10.638300] Loaded X.509 cert 'wens: 61c038651aabdcf94bd0ac7ff06c7248db18c600'
[ 13.944842] mt798x-wmac 18000000.wifi: HW/SW Version: 0x8a108a10, Build Time: 20221012174743a
[ 14.033218] mt798x-wmac 18000000.wifi: WM Firmware Version: ____000000, Build Time: 20221012174805
[ 14.099766] mt798x-wmac 18000000.wifi: WA Firmware Version: DEV_000000, Build Time: 20221012174937
[ 14.244892] mt798x-wmac 18000000.wifi: eeprom load fail, use default bin
[ 14.913201] mtk_soc_eth 15100000.ethernet eth0: configuring for fixed/2500base-x link mode
[ 14.921707] mtk_soc_eth 15100000.ethernet eth0: Link is Up - 2.5Gbps/Full - flow control rx/tx
[ 14.923292] mt7530-mdio mdio-bus:1f wan: configuring for phy/gmii link mode
[ 14.940572] mt7530-mdio mdio-bus:1f wan: Link is Up - 1Gbps/Full - flow control rx/tx
[ 15.076652] mt7530-mdio mdio-bus:1f lan0: configuring for phy/gmii link mode
[ 15.253604] mt7530-mdio mdio-bus:1f lan1: configuring for phy/gmii link mode
[ 15.430061] mt7530-mdio mdio-bus:1f lan2: configuring for phy/gmii link mode
[ 15.606106] mt7530-mdio mdio-bus:1f lan3: configuring for phy/gmii link mode
[ 17.333503] mtk_soc_eth 15100000.ethernet eth1: configuring for inband/2500base-x link mode
[ 43.646970] mtk_soc_eth 15100000.ethernet eth1: switched to inband/sgmii link mode
[ 44.061629] mtk_soc_eth 15100000.ethernet eth1: PHY [i2c:sfp-1:11] driver [RTL8221B-VB-CG 2.5Gbps PHY (C45)] (irq=POLL)
I can see with ethtool speed is correct (1000 or 2500) :
root@bpi-r3:~# ethtool eth1
Settings for eth1:
Supported ports: [ TP MII ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
2500baseT/Full
Supported pause frame use: Symmetric Receive-only
Supports auto-negotiation: Yes
Supported FEC modes: Not reported
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
2500baseT/Full
Advertised pause frame use: Symmetric Receive-only
Advertised auto-negotiation: Yes
Advertised FEC modes: Not reported
Link partner advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
2500baseT/Full
Link partner advertised pause frame use: Symmetric Receive-only
Link partner advertised auto-negotiation: Yes
Link partner advertised FEC modes: Not reported
Speed: 2500Mb/s
Duplex: Full
Auto-negotiation: on
Port: Twisted Pair
PHYAD: 17
Transceiver: external
MDI-X: Unknown
Current message level: 0x000000ff (255)
drv probe link timer ifdown ifup rx_err tx_err
Link detected: no
root@bpi-r3:~# ethtool eth1
Settings for eth1:
Supported ports: [ TP MII ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
2500baseT/Full
Supported pause frame use: Symmetric Receive-only
Supports auto-negotiation: Yes
Supported FEC modes: Not reported
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
2500baseT/Full
Advertised pause frame use: Symmetric Receive-only
Advertised auto-negotiation: Yes
Advertised FEC modes: Not reported
Link partner advertised link modes: 10baseT/Full
100baseT/Full
1000baseT/Full
Link partner advertised pause frame use: Symmetric
Link partner advertised auto-negotiation: Yes
Link partner advertised FEC modes: Not reported
Speed: 1000Mb/s
Duplex: Full
Auto-negotiation: on
Port: Twisted Pair
PHYAD: 17
Transceiver: external
MDI-X: Unknown
Current message level: 0x000000ff (255)
drv probe link timer ifdown ifup rx_err tx_err
Link detected: no
root@bpi-r3:~#
I configured the interface like this with /etc/network/interfaces :
auto eth1
iface eth1 inet static
address 192.168.1.16
netmask 255.255.255.0
But traffic is still KO, I can’t ping a product with IP 192.168.1.254 which is connected on the SFP :
root@bpi-r3:~# ping 192.168.1.254 -I eth1 -c 4
PING 192.168.1.254 (192.168.1.254) from 192.168.1.16 eth1: 56(84) bytes of data.
--- 192.168.1.254 ping statistics ---
4 packets transmitted, 0 received, 100% packet loss, time 3134ms
I f I use a lan of the BPI to make the ping, it is OK :
root@bpi-r3:~# ping 192.168.1.254 -I lan0 -c 4
PING 192.168.1.254 (192.168.1.254) from 192.168.1.10 lan0: 56(84) bytes of data.
64 bytes from 192.168.1.254: icmp_seq=1 ttl=64 time=1.72 ms
64 bytes from 192.168.1.254: icmp_seq=2 ttl=64 time=0.369 ms
64 bytes from 192.168.1.254: icmp_seq=3 ttl=64 time=0.459 ms
64 bytes from 192.168.1.254: icmp_seq=4 ttl=64 time=0.417 ms
--- 192.168.1.254 ping statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 3060ms
rtt min/avg/max/mdev = 0.369/0.741/1.722/0.566 ms
Do you have an idea on what I am missing ?
This ping was OK with the ArchLinux image and this SFP.
Thank you.
If you are trying to ping to/from the same BPI-R3, this is a bit more difficult than using another computer/board to connect to the R3. It should be possible, but there are a few catches. So I don’t do this myself when testing, I might end up spending to much time trying to figure out why this is not working, wasting the little time I have.
So try to keep it simple by using another pc/board. Also, if the pc/board and the R3 are already connected on 1 subnet, then you need to test the SFP over another subnet…
Also make sure there is one patch dealing with the fact that the R3 MAC cannot use inband at 2500base-x
Please show your ip config…afair i used 192.168.1.0/24 for lanbr0 so you cannot assign this to external interface
So either put eth1 into the bridge (please do not if it is wan) or change ip settings including dhcp of the lanbridge.
I did not know that R3 MAC cannot use inband at 2500base-x. What patch should I used ?
Just to clarify the setup :
-
I have a PC connected to the wan port (used for management, ssh).
-
I have a product with IP 192.168.1.254 with 4x lan 1Gb and 1 lan 2.5 Gb
-
Those 4 lans 1 Gb are connected to lan0, lan1, lan2, lan3 of the Bpi.
-
The lan 2.5 iGb s connected to the SFP on eth1 of the Bpi.
I need to ping from the Bpi to the product on each port. This is working for lan0, lan1, lan2, lan3 but not eth1.
Here is my IP config :
root@bpi-r3:~# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host noprefixroute
valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1504 qdisc mq state UP group default qlen 1000
link/ether ee:76:f6:14:5f:e1 brd ff:ff:ff:ff:ff:ff
inet6 fe80::ec76:f6ff:fe14:5fe1/64 scope link
valid_lft forever preferred_lft forever
3: eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN group default qlen 1000
link/ether 06:27:b6:80:ad:2a brd ff:ff:ff:ff:ff:ff
inet 192.168.1.16/24 brd 192.168.1.255 scope global eth1
valid_lft forever preferred_lft forever
4: sit0@NONE: <NOARP> mtu 1480 qdisc noop state DOWN group default qlen 1000
link/sit 0.0.0.0 brd 0.0.0.0
5: wan@eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
link/ether ee:76:f6:14:5f:e1 brd ff:ff:ff:ff:ff:ff
inet 10.1.1.101/24 brd 10.1.1.255 scope global wan
valid_lft forever preferred_lft forever
inet6 fe80::ec76:f6ff:fe14:5fe1/64 scope link
valid_lft forever preferred_lft forever
6: lan0@eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default qlen 1000
link/ether ee:76:f6:14:5f:e1 brd ff:ff:ff:ff:ff:ff
inet 192.168.1.10/24 brd 192.168.1.255 scope global lan0
valid_lft forever preferred_lft forever
7: lan1@eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state LOWERLAYERDOWN group default qlen 1000
link/ether ee:76:f6:14:5f:e1 brd ff:ff:ff:ff:ff:ff
inet 192.168.1.11/24 brd 192.168.1.255 scope global lan1
valid_lft forever preferred_lft forever
8: lan2@eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state LOWERLAYERDOWN group default qlen 1000
link/ether ee:76:f6:14:5f:e1 brd ff:ff:ff:ff:ff:ff
inet 192.168.1.12/24 brd 192.168.1.255 scope global lan2
valid_lft forever preferred_lft forever
9: lan3@eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state LOWERLAYERDOWN group default qlen 1000
link/ether ee:76:f6:14:5f:e1 brd ff:ff:ff:ff:ff:ff
inet 192.168.1.13/24 brd 192.168.1.255 scope global lan3
valid_lft forever preferred_lft forever
10: lan4@eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state LOWERLAYERDOWN group default qlen 1000
link/ether ee:76:f6:14:5f:e1 brd ff:ff:ff:ff:ff:ff
inet 192.168.1.17/24 brd 192.168.1.255 scope global lan4
valid_lft forever preferred_lft forever
11: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
link/ether 00:0c:43:ac:e2:3f brd ff:ff:ff:ff:ff:ff permaddr 00:0c:43:26:60:00
inet 192.168.1.14/24 brd 192.168.1.255 scope global wlan0
valid_lft forever preferred_lft forever
inet6 fe80::20c:43ff:feac:e23f/64 scope link
valid_lft forever preferred_lft forever
12: wlan1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
link/ether 80:0c:43:ab:bc:18 brd ff:ff:ff:ff:ff:ff permaddr 82:0c:43:26:60:00
inet 192.168.1.15/24 brd 192.168.1.255 scope global wlan1
valid_lft forever preferred_lft forever
inet6 fe80::820c:43ff:feab:bc18/64 scope link
valid_lft forever preferred_lft forever
this is wrong…you cannot give mutltiple interfaces different IPs from ONE IP-Subnet because this confuses routing…where should it send packets targeted to 192.168.1.0/24 and where target ip is not locally assigned?
bridge lan-ports as it is done in my default config and give the bridge 1 IP from the subnet…if you need this subnet external, then you cannot use it for your local lan.
ISP (192.168.1.254) — eth1 (192.168.1.1/24) (maybe introduce wanbr0 which gets the IP and have all physical interfaces bridged for wan)
LAN 192.168.0.0/24 - lanbr0 (192.168.0.1/24) (lan0,lan1,lan2,lan3 bridged without own IP address)
see en:bpi-r2:network:start [FW-WEB Wiki]
and yes there is a way to “fix” the routing but this is advanced…so better stay with easy setup here
you can see routing for 192.168.1.0/24 with “ip r” (or “ip r g 192.168.1.254” for ISP IP) there are your packets routed for this subnet if not locally bound…which is mostly the wrong interface
TLDR: only 1 IP-Subnet per Interface to not confuse routing
There were patches that disabled inband of the R3 MAC and the also disable inband for the rtl8221 (only needed for 1000Mbps sgmii). But this issue should not be fixed at device driver level. So I made a crude patch that does handle it at phylink.c, but this will never get upstreamed. There may be a permanent solution coming for this at one time, but to fix this issue for all hardware that is out there is quite difficult.
So I use:
net: phylink: add support for disabling in-band-status for base-x