BPI-R3 sfp interface problems

What is the source address?

See his post

openwrt has to source it! Thanks I’ll try.But the openwrt source code does not luci-app-syncdial

I tried compiling with the openwrt source code, but I still can’t get the IP address. Is the module incompatible?

I tried compiling with the openwrt source code, but I still can’t get the IP address. Is the module incompatible?

On which port have you inserted the sfp? TL-SM410U is afaik the one daniel used in his tests.

You have to put the interface up (eth1 for wan-sfp,lan4 for lan-sfp).

Can you show your dmesg and ethtool output?

dmesg | grep -i 'eth\|sfp'
ethtool eth1;ethtool -m eth1
root@OpenWrt:/# dmesg | grep -i 'eth\|sfp'
[    0.000000] psci: probing for conduit method from DT.
[    1.130674] mtk_soc_eth 15100000.ethernet eth0: mediatek frame engine at 0xffffffc009600000, irq 132
[    1.139871] mtk_soc_eth 15100000.ethernet: generated random MAC address 9a:e5:db:eb:f5:af
[    1.148637] mtk_soc_eth 15100000.ethernet eth1: mediatek frame engine at 0xffffffc009600000, irq 132
[    6.737968] mtk_soc_eth 15100000.ethernet eth0: configuring for fixed/2500base-x link mode
[    6.746403] mtk_soc_eth 15100000.ethernet eth0: Link is Up - 2.5Gbps/Full - flow control rx/tx
[   23.761804] sfp sfp1: Host maximum power 1.0W
[   23.766912] sfp sfp2: Host maximum power 1.0W
[   24.107376] sfp sfp2: module TP-LINK          TL-SM410U        rev 2.0  sn 122C304000986    dc 221228  
[   30.512894] mtk_soc_eth 15100000.ethernet eth0: Link is Down
[   30.578030] mtk_soc_eth 15100000.ethernet eth0: configuring for fixed/2500base-x link mode
[   30.586465] mtk_soc_eth 15100000.ethernet eth0: Link is Up - 2.5Gbps/Full - flow control rx/tx
[   30.622011] device eth0 entered promiscuous mode
[   30.629104] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[   30.736510] mt7530 mdio-bus:1f sfp2: configuring for inband/2500base-x link mode
[   30.745283] br-lan: port 5(sfp2) entered blocking state
[   30.750562] br-lan: port 5(sfp2) entered disabled state
[   30.758030] device sfp2 entered promiscuous mode
[  139.526228] sfp sfp2: module removed
[  143.597191] sfp sfp1: module TP-LINK          TL-SM410U        rev 2.0  sn 122C304000986    dc 221228  
[  234.482701] sfp sfp1: module removed
[  238.857199] sfp sfp2: module TP-LINK          TL-SM410U        rev 2.0  sn 122C304000986    dc 221228  
root@OpenWrt:/# ethtool eth1;ethtool -m eth1
/bin/ash: ethtool: not found
/bin/ash: ethtool: not found
root@OpenWrt:/#
  1. You don’t have ethtool installed. Please, install it and do these commands:
ethtool eth1

ethtool -m eth1

Sfp module must be plugged to sfp1 cage (near usb port).

  1. Did you manually swap sfp module from sfp2 cage to sfp1? It seems, your sfp module was recognised by router, but was disconnected from sfp2 first and plugged to sfp1. Than it was disconnected from sfp1 and plugged to sfp2. Is this true?
root@OpenWrt:/# dmesg | grep -i 'eth\|sfp'
[    0.000000] psci: probing for conduit method from DT.
[    1.140889] mtk_soc_eth 15100000.ethernet eth0: mediatek frame engine at 0xffffffc009680000, irq 134
[    1.150653] mtk_soc_eth 15100000.ethernet eth1: mediatek frame engine at 0xffffffc009680000, irq 134
[    7.155723] mtk_soc_eth 15100000.ethernet eth0: configuring for fixed/2500base-x link mode
[    7.164156] mtk_soc_eth 15100000.ethernet eth0: Link is Up - 2.5Gbps/Full - flow control rx/tx
[   18.037568] sfp sfp1: Host maximum power 3.0W
[   18.042688] sfp sfp2: Host maximum power 3.0W
[   18.377478] sfp sfp2: module TP-LINK          TL-SM410U        rev 2.0  sn 122C304000986    dc 221228  
[   28.802670] mtk_soc_eth 15100000.ethernet eth0: Link is Down
[   28.848124] mtk_soc_eth 15100000.ethernet eth0: configuring for fixed/2500base-x link mode
[   28.857045] mtk_soc_eth 15100000.ethernet eth0: Link is Up - 2.5Gbps/Full - flow control rx/tx
[   28.897856] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[   28.932194] device eth0 entered promiscuous mode
[   29.067874] mt7530 mdio-bus:1f sfp2: configuring for inband/2500base-x link mode
[   29.077333] br-lan: port 5(sfp2) entered blocking state
[   29.082623] br-lan: port 5(sfp2) entered disabled state
[   29.090095] device sfp2 entered promiscuous mode
[   29.099518] mtk_soc_eth 15100000.ethernet eth1: configuring for inband/2500base-x link mode
[   29.109573] br-wan: port 1(eth1) entered blocking state
[   29.114863] br-wan: port 1(eth1) entered disabled state
[   29.120336] device eth1 entered promiscuous mode
[   29.126880] br-wan: port 1(eth1) entered blocking state
[   29.132268] br-wan: port 1(eth1) entered forwarding state
[   29.997487] br-wan: port 1(eth1) entered disabled state
root@OpenWrt:/# ethtool eth1;ethtool -m eth1
Settings for eth1:
        Supported ports: [ MII ]
        Supported link modes:   2500baseX/Full
        Supported pause frame use: Symmetric Receive-only
        Supports auto-negotiation: Yes
        Supported FEC modes: Not reported
        Advertised link modes:  2500baseX/Full
        Advertised pause frame use: Symmetric Receive-only
        Advertised auto-negotiation: Yes
        Advertised FEC modes: Not reported
        Speed: 2500Mb/s
        Duplex: Full
        Auto-negotiation: on
        Port: MII
        PHYAD: 0
        Transceiver: internal
        Current message level: 0x000000ff (255)
                               drv probe link timer ifdown ifup rx_err tx_err
        Link detected: no
netlink error: No such device or address
root@OpenWrt:/# dmesg | grep -i 'eth\|sfp'
[    0.000000] psci: probing for conduit method from DT.
[    1.140889] mtk_soc_eth 15100000.ethernet eth0: mediatek frame engine at 0xffffffc009680000, irq 134
[    1.150653] mtk_soc_eth 15100000.ethernet eth1: mediatek frame engine at 0xffffffc009680000, irq 134
[    7.155723] mtk_soc_eth 15100000.ethernet eth0: configuring for fixed/2500base-x link mode
[    7.164156] mtk_soc_eth 15100000.ethernet eth0: Link is Up - 2.5Gbps/Full - flow control rx/tx
[   18.037568] sfp sfp1: Host maximum power 3.0W
[   18.042688] sfp sfp2: Host maximum power 3.0W
[   18.377478] sfp sfp2: module TP-LINK          TL-SM410U        rev 2.0  sn 122C304000986    dc 221228  
[   28.802670] mtk_soc_eth 15100000.ethernet eth0: Link is Down
[   28.848124] mtk_soc_eth 15100000.ethernet eth0: configuring for fixed/2500base-x link mode
[   28.857045] mtk_soc_eth 15100000.ethernet eth0: Link is Up - 2.5Gbps/Full - flow control rx/tx
[   28.897856] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[   28.932194] device eth0 entered promiscuous mode
[   29.067874] mt7530 mdio-bus:1f sfp2: configuring for inband/2500base-x link mode
[   29.077333] br-lan: port 5(sfp2) entered blocking state
[   29.082623] br-lan: port 5(sfp2) entered disabled state
[   29.090095] device sfp2 entered promiscuous mode
[   29.099518] mtk_soc_eth 15100000.ethernet eth1: configuring for inband/2500base-x link mode
[   29.109573] br-wan: port 1(eth1) entered blocking state
[   29.114863] br-wan: port 1(eth1) entered disabled state
[   29.120336] device eth1 entered promiscuous mode
[   29.126880] br-wan: port 1(eth1) entered blocking state
[   29.132268] br-wan: port 1(eth1) entered forwarding state
[   29.997487] br-wan: port 1(eth1) entered disabled state
[ 1067.373406] sfp sfp2: module removed
[ 1070.797471] sfp sfp1: module TP-LINK          TL-SM410U        rev 2.0  sn 122C304000986    dc 221228  
root@OpenWrt:/# ethtool eth1;ethtool -m eth1
Settings for eth1:
        Supported ports: [ FIBRE ]
        Supported link modes:   2500baseX/Full
        Supported pause frame use: Symmetric Receive-only
        Supports auto-negotiation: Yes
        Supported FEC modes: Not reported
        Advertised link modes:  2500baseX/Full
        Advertised pause frame use: Symmetric Receive-only
        Advertised auto-negotiation: Yes
        Advertised FEC modes: Not reported
        Speed: 2500Mb/s
        Duplex: Full
        Auto-negotiation: on
        Port: FIBRE
        PHYAD: 0
        Transceiver: internal
        Current message level: 0x000000ff (255)
                               drv probe link timer ifdown ifup rx_err tx_err
        Link detected: no
        Identifier                                : 0x03 (SFP)
        Extended identifier                       : 0x04 (GBIC/SFP defined by 2-wire interface ID)
        Connector                                 : 0x07 (LC)
        Transceiver codes                         : 0x00 0x00 0x00 0x00 0x00 0x00 0x40 0x00 0x00
        Transceiver type                          : FC: Twisted Pair (TP)
        Encoding                                  : 0x01 (8B/10B)
        BR, Nominal                               : 3100MBd
        Rate identifier                           : 0x00 (unspecified)
        Length (SMF,km)                           : 0km
        Length (SMF)                              : 0m
        Length (50um)                             : 0m
        Length (62.5um)                           : 0m
        Length (Copper)                           : 0m
        Length (OM3)                              : 0m
        Laser wavelength                          : 0nm
        Vendor name                               : TP-LINK
        Vendor OUI                                : 00:00:00
        Vendor PN                                 : TL-SM410U
        Vendor rev                                : 2.0
        Option values                             : 0x00 0x18
        Option                                    : TX_FAULT implemented
        Option                                    : TX_DISABLE implemented
        BR margin, max                            : 0%
        BR margin, min                            : 0%
        Vendor SN                                 : 122C304000986
        Date code                                 : 221228
root@OpenWrt:/#
root@OpenWrt:/# dmesg | grep -i 'eth\|sfp'
[    0.000000] psci: probing for conduit method from DT.
[    1.140889] mtk_soc_eth 15100000.ethernet eth0: mediatek frame engine at 0xffffffc009680000, irq 134
[    1.150653] mtk_soc_eth 15100000.ethernet eth1: mediatek frame engine at 0xffffffc009680000, irq 134
[    7.155723] mtk_soc_eth 15100000.ethernet eth0: configuring for fixed/2500base-x link mode
[    7.164156] mtk_soc_eth 15100000.ethernet eth0: Link is Up - 2.5Gbps/Full - flow control rx/tx
[   18.037568] sfp sfp1: Host maximum power 3.0W
[   18.042688] sfp sfp2: Host maximum power 3.0W
[   18.377478] sfp sfp2: module TP-LINK          TL-SM410U        rev 2.0  sn 122C304000986    dc 221228  
[   28.802670] mtk_soc_eth 15100000.ethernet eth0: Link is Down
[   28.848124] mtk_soc_eth 15100000.ethernet eth0: configuring for fixed/2500base-x link mode
[   28.857045] mtk_soc_eth 15100000.ethernet eth0: Link is Up - 2.5Gbps/Full - flow control rx/tx
[   28.897856] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[   28.932194] device eth0 entered promiscuous mode
[   29.067874] mt7530 mdio-bus:1f sfp2: configuring for inband/2500base-x link mode
[   29.077333] br-lan: port 5(sfp2) entered blocking state
[   29.082623] br-lan: port 5(sfp2) entered disabled state
[   29.090095] device sfp2 entered promiscuous mode
[   29.099518] mtk_soc_eth 15100000.ethernet eth1: configuring for inband/2500base-x link mode
[   29.109573] br-wan: port 1(eth1) entered blocking state
[   29.114863] br-wan: port 1(eth1) entered disabled state
[   29.120336] device eth1 entered promiscuous mode
[   29.126880] br-wan: port 1(eth1) entered blocking state
[   29.132268] br-wan: port 1(eth1) entered forwarding state
[   29.997487] br-wan: port 1(eth1) entered disabled state
[ 1067.373406] sfp sfp2: module removed
[ 1070.797471] sfp sfp1: module TP-LINK          TL-SM410U        rev 2.0  sn 122C304000986    dc 221228  
root@OpenWrt:/# ethtool eth1;ethtool -m eth1
Settings for eth1:
        Supported ports: [ FIBRE ]
        Supported link modes:   2500baseX/Full
        Supported pause frame use: Symmetric Receive-only
        Supports auto-negotiation: Yes
        Supported FEC modes: Not reported
        Advertised link modes:  2500baseX/Full
        Advertised pause frame use: Symmetric Receive-only
        Advertised auto-negotiation: Yes
        Advertised FEC modes: Not reported
        Speed: 2500Mb/s
        Duplex: Full
        Auto-negotiation: on
        Port: FIBRE
        PHYAD: 0
        Transceiver: internal
        Current message level: 0x000000ff (255)
                               drv probe link timer ifdown ifup rx_err tx_err
        Link detected: no
        Identifier                                : 0x03 (SFP)
        Extended identifier                       : 0x04 (GBIC/SFP defined by 2-wire interface ID)
        Connector                                 : 0x07 (LC)
        Transceiver codes                         : 0x00 0x00 0x00 0x00 0x00 0x00 0x40 0x00 0x00
        Transceiver type                          : FC: Twisted Pair (TP)
        Encoding                                  : 0x01 (8B/10B)
        BR, Nominal                               : 3100MBd
        Rate identifier                           : 0x00 (unspecified)
        Length (SMF,km)                           : 0km
        Length (SMF)                              : 0m
        Length (50um)                             : 0m
        Length (62.5um)                           : 0m
        Length (Copper)                           : 0m
        Length (OM3)                              : 0m
        Laser wavelength                          : 0nm
        Vendor name                               : TP-LINK
        Vendor OUI                                : 00:00:00
        Vendor PN                                 : TL-SM410U
        Vendor rev                                : 2.0
        Option values                             : 0x00 0x18
        Option                                    : TX_FAULT implemented
        Option                                    : TX_DISABLE implemented
        BR margin, max                            : 0%
        BR margin, min                            : 0%
        Vendor SN                                 : 122C304000986
        Date code                                 : 221228
root@OpenWrt:/#

please format code to be readable (select code and press the <> button) make sure there is an empty line between “normal” text and the code…for longer code do not post 3 messages, put output in textfile and append it or use pastebin or similar and put link in your message

I am very sorry, I am inserting the modules into SPF1 and 2 respectively and then using the command output. But what you said (select code and press the <> button) I’m not very good at it!

basicly it looks good so far, only the toggling state before you read out the sfp is strange…but this looks like manual switch from sfp2 (lan sfp cage) to sfp1 (wan sfp cage = eth1)

so what exactly does not work? the 2500 Mbit/s SFPs (the TP-Link you have and the OEM i have) have a bit problems recognizing the link and link speed we are trying to fix. so for now try the autoneg workaround to get link working

ethtool -s eth1 autoneg off

Using the commands you provided is still not good, I can’t get an IP address when my problematic network cable is connected. Looking forward to your fix.

Have you plugged in cable? Is link/speed detected? Is interface (eth1) set to up?

Please show ethtool (without m switch) output when cable is plugged (and the other side ready) and interface admin-up and

ip l show eth1
ip a s eth1

It is not my fix…eric tries to fix the autoneg issue with daniel and russel.

See SFP OEM SFP-2.5G-T kernel PHY?

<root@OpenWrt:~# ethtool eth1 Settings for eth1: Supported ports: [ FIBRE ] Supported link modes: 2500baseX/Full Supported pause frame use: Symmetric Receive-only Supports auto-negotiation: Yes Supported FEC modes: Not reported Advertised link modes: 2500baseX/Full Advertised pause frame use: Symmetric Receive-only Advertised auto-negotiation: No Advertised FEC modes: Not reported Speed: 2500Mb/s Duplex: Full Auto-negotiation: off Port: FIBRE PHYAD: 0 Transceiver: internal Current message level: 0x000000ff (255) drv probe link timer ifdown ifup rx_err tx_err Link detected: no>

root@OpenWrt:~# ip l show eth1
3: eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq master br-lan state DOWN mode DEFAULT group default qlen 1000
    link/ether 9a:31:8a:46:a5:e7 brd ff:ff:ff:ff:ff:ff
root@OpenWrt:~# ip a s eth1
3: eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq master br-lan state DOWN group default qlen 1000
    link/ether 9a:31:8a:46:a5:e7 brd ff:ff:ff:ff:ff:ff

your eth1 seems to be put into bridge br-lan…so you have to put this bridge up too…and please format the code…else it is unreadable

Please enclose in three ` at line start when copying text …