[BPI-R3] need help for wifi

Hy ladies and gentlemen :slight_smile:

For a Project, i need to build my Os from Buildroot.

I build my Kernel from the sources of the Frank’s git :slight_smile:

I used the 6.0-R3.

In the Devicetree, there is the eeprom-data for wifi.

I tried to load the driver two ways :
-Built-in the kernel -Load as a Module (modprobe). But same result.

All firmware of Mediatek are presents in the folder /lib/firmware/mediatek/

 # modprobe mt7915e
# lsmod
Module                  Size  Used by
mt7915e               143360  0
mt76_connac_lib        53248  1 mt7915e
mt76                   81920  2 mt7915e,mt76_connac_lib
# modinfo mt7915e
filename:       /lib/modules/6.0.0-rc4-diagbox/kernel/drivers/net/wireless/mediatek/mt76/mt7915/mt7915e.ko
firmware:       mediatek/mt7916_rom_patch.bin
firmware:       mediatek/mt7916_wm.bin
firmware:       mediatek/mt7916_wa.bin
firmware:       mediatek/mt7915_rom_patch.bin
firmware:       mediatek/mt7915_wm.bin
firmware:       mediatek/mt7915_wa.bin
license:        Dual BSD/GPL
firmware:       mediatek/mt7986_rom_patch_mt7975.bin
firmware:       mediatek/mt7986_rom_patch.bin
firmware:       mediatek/mt7986_wm_mt7975.bin
firmware:       mediatek/mt7986_wm.bin
firmware:       mediatek/mt7986_wa.bin
alias:          pci:v000014C3d00007906sv*sd*bc*sc*i*
alias:          pci:v000014C3d00007915sv*sd*bc*sc*i*
alias:          pci:v000014C3d0000790Asv*sd*bc*sc*i*
alias:          pci:v000014C3d00007916sv*sd*bc*sc*i*
depends:        mt76-connac-lib,mt76
intree:         Y
name:           mt7915e
vermagic:       6.0.0-rc4-diagbox SMP mod_unload aarch64
parm:           wed_enable:bool

If i understand the output of my command modinfo mt7915e; all firmware needed are loaded.

Here the ouput of my dmesg :

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
[    0.000000] Linux version 6.0.0-rc4-diagbox (root@workstation) (aarch64-linux-gnu-gcc (Linaro GCC 7.5-2019.12) 7.5.0, GNU ld (Linaro_Binutils-2019.12) 2.28.2.20170706) #2 SMP Sun Oct 30 17:13:37 CET 2022
[    0.000000] Machine model: Bananapi BPI-R3
[    0.000000] earlycon: uart8250 at MMIO32 0x0000000011002000 (options '')
[    0.000000] printk: bootconsole [uart8250] enabled
[    0.000000] efi: UEFI not found.
[    0.000000] OF: fdt: Reserved memory: failed to reserve memory for node 'wmcpu-reserved@4fc00000': base 0x000000004fc00000, size 1 MiB
[    0.000000] Zone ranges:
[    0.000000]   DMA      [mem 0x0000000040000000-0x00000000bfffffff]
[    0.000000]   DMA32    empty
[    0.000000]   Normal   empty
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000040000000-0x0000000042ffffff]
[    0.000000]   node   0: [mem 0x0000000043000000-0x000000004302ffff]
[    0.000000]   node   0: [mem 0x0000000043030000-0x00000000bfffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000040000000-0x00000000bfffffff]
[    0.000000] psci: probing for conduit method from DT.
[    0.000000] psci: PSCIv1.1 detected in firmware.
[    0.000000] psci: Using standard PSCI v0.2 function IDs
[    0.000000] psci: MIGRATE_INFO_TYPE not supported.
[    0.000000] psci: SMC Calling Convention v1.2
[    0.000000] percpu: Embedded 27 pages/cpu s70824 r8192 d31576 u110592
[    0.000000] pcpu-alloc: s70824 r8192 d31576 u110592 alloc=27*4096
[    0.000000] pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3
[    0.000000] Detected VIPT I-cache on CPU0
[    0.000000] CPU features: detected: GIC system register CPU interface
[    0.000000] CPU features: detected: ARM erratum 845719
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 516096
[    0.000000] Kernel command line: board=DiagBox earlycon=uart8250,mmio32,0x11002000 debug=7 initrd=0x48000000,550M
[    0.000000] Unknown kernel command line parameters "board=DiagBox", will be passed to user space.
[    0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes, linear)
[    0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes, linear)
[    0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[    0.000000] Memory: 1469836K/2097152K available (12992K kernel code, 2096K rwdata, 4020K rodata, 3712K init, 419K bss, 627316K reserved, 0K cma-reserved)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] trace event string verifier disabled
[    0.000000] rcu: Hierarchical RCU implementation.
[    0.000000] rcu:     RCU event tracing is enabled.
[    0.000000]  Tracing variant of Tasks RCU enabled.
[    0.000000] rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
[    0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[    0.000000] GICv3: GIC: Using split EOI/Deactivate mode
[    0.000000] GICv3: 640 SPIs implemented
[    0.000000] GICv3: 0 Extended SPIs implemented
[    0.000000] Root IRQ handler: gic_handle_irq
[    0.000000] GICv3: GICv3 features: 16 PPIs
[    0.000000] GICv3: CPU0: found redistributor 0 region 0:0x000000000c080000
[    0.000000] rcu: srcu_init: Setting srcu_struct sizes based on contention.
[    0.000000] arch_timer: cp15 timer(s) running at 13.00MHz (phys).
[    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x2ff89eacb, max_idle_ns: 440795202429 ns
[    0.000000] sched_clock: 56 bits at 13MHz, resolution 76ns, wraps every 4398046511101ns
[    0.008246] Console: colour dummy device 80x25
[    0.012712] printk: console [tty0] enabled
[    0.016826] printk: bootconsole [uart8250] disabled
[    0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
[    0.000000] Linux version 6.0.0-rc4-diagbox (root@workstation) (aarch64-linux-gnu-gcc (Linaro GCC 7.5-2019.12) 7.5.0, GNU ld (Linaro_Binutils-2019.12) 2.28.2.20170706) #2 SMP Sun Oct 30 17:13:37 CET 2022
[    0.000000] Machine model: Bananapi BPI-R3
[    0.000000] earlycon: uart8250 at MMIO32 0x0000000011002000 (options '')
[    0.000000] printk: bootconsole [uart8250] enabled
[    0.000000] efi: UEFI not found.
[    0.000000] OF: fdt: Reserved memory: failed to reserve memory for node 'wmcpu-reserved@4fc00000': base 0x000000004fc00000, size 1 MiB
[    0.000000] Zone ranges:
[    0.000000]   DMA      [mem 0x0000000040000000-0x00000000bfffffff]
[    0.000000]   DMA32    empty
[    0.000000]   Normal   empty
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000040000000-0x0000000042ffffff]
[    0.000000]   node   0: [mem 0x0000000043000000-0x000000004302ffff]
[    0.000000]   node   0: [mem 0x0000000043030000-0x00000000bfffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000040000000-0x00000000bfffffff]
[    0.000000] psci: probing for conduit method from DT.
[    0.000000] psci: PSCIv1.1 detected in firmware.
[    0.000000] psci: Using standard PSCI v0.2 function IDs
[    0.000000] psci: MIGRATE_INFO_TYPE not supported.
[    0.000000] psci: SMC Calling Convention v1.2
[    0.000000] percpu: Embedded 27 pages/cpu s70824 r8192 d31576 u110592
[    0.000000] pcpu-alloc: s70824 r8192 d31576 u110592 alloc=27*4096
[    0.000000] pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3
[    0.000000] Detected VIPT I-cache on CPU0
[    0.000000] CPU features: detected: GIC system register CPU interface
[    0.000000] CPU features: detected: ARM erratum 845719
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 516096
[    0.000000] Kernel command line: board=DiagBox earlycon=uart8250,mmio32,0x11002000 debug=7 initrd=0x48000000,550M
[    0.000000] Unknown kernel command line parameters "board=DiagBox", will be passed to user space.
[    0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes, linear)
[    0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes, linear)
[    0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[    0.000000] Memory: 1469836K/2097152K available (12992K kernel code, 2096K rwdata, 4020K rodata, 3712K init, 419K bss, 627316K reserved, 0K cma-reserved)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] trace event string verifier disabled
[    0.000000] rcu: Hierarchical RCU implementation.
[    0.000000] rcu:     RCU event tracing is enabled.
[    0.000000]  Tracing variant of Tasks RCU enabled.
[    0.000000] rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
[    0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[    0.000000] GICv3: GIC: Using split EOI/Deactivate mode
[    0.000000] GICv3: 640 SPIs implemented
[    0.000000] GICv3: 0 Extended SPIs implemented
[    0.000000] Root IRQ handler: gic_handle_irq
[    0.000000] GICv3: GICv3 features: 16 PPIs
[    0.000000] GICv3: CPU0: found redistributor 0 region 0:0x000000000c080000
[    0.000000] rcu: srcu_init: Setting srcu_struct sizes based on contention.
[    0.000000] arch_timer: cp15 timer(s) running at 13.00MHz (phys).
[    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x2ff89eacb, max_idle_ns: 440795202429 ns
[    0.000000] sched_clock: 56 bits at 13MHz, resolution 76ns, wraps every 4398046511101ns
[    0.008246] Console: colour dummy device 80x25
[    0.012712] printk: console [tty0] enabled
[    0.016826] printk: bootconsole [uart8250] disabled
[    0.021753] Calibrating delay loop (skipped), value calculated using timer frequency.. 26.00 BogoMIPS (lpj=130000)
[    0.021765] pid_max: default: 32768 minimum: 301
[    0.021855] Mount-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
[    0.021872] Mountpoint-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
[    0.022313] cacheinfo: Unable to detect cache hierarchy for CPU 0
[    0.022570] cblist_init_generic: Setting adjustable number of callback queues.
[    0.022580] cblist_init_generic: Setting shift to 2 and lim to 1.
[    0.022676] rcu: Hierarchical SRCU implementation.
[    0.022682] rcu:     Max phase no-delay instances is 1000.
[    0.023078] EFI services will not be available.
[    0.023214] smp: Bringing up secondary CPUs ...
[    0.023511] Detected VIPT I-cache on CPU1
[    0.023565] cacheinfo: Unable to detect cache hierarchy for CPU 1
[    0.023573] GICv3: CPU1: found redistributor 1 region 0:0x000000000c0a0000
[    0.023607] CPU1: Booted secondary processor 0x0000000001 [0x410fd034]
[    0.023929] Detected VIPT I-cache on CPU2
[    0.023962] cacheinfo: Unable to detect cache hierarchy for CPU 2
[    0.023967] GICv3: CPU2: found redistributor 2 region 0:0x000000000c0c0000
[    0.023980] CPU2: Booted secondary processor 0x0000000002 [0x410fd034]
[    0.024243] Detected VIPT I-cache on CPU3
[    0.024272] cacheinfo: Unable to detect cache hierarchy for CPU 3
[    0.024277] GICv3: CPU3: found redistributor 3 region 0:0x000000000c0e0000
[    0.024287] CPU3: Booted secondary processor 0x0000000003 [0x410fd034]
[    0.024319] smp: Brought up 1 node, 4 CPUs
[    0.024370] SMP: Total of 4 processors activated.
[    0.024376] CPU features: detected: 32-bit EL0 Support
[    0.024382] CPU features: detected: CRC32 instructions
[    0.024424] CPU features: emulated: Privileged Access Never (PAN) using TTBR0_EL1 switching
[    0.025985] CPU: All CPU(s) started at EL2
[    0.026001] alternatives: patching kernel code
[    0.026830] devtmpfs: initialized
[    0.028516] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.028541] futex hash table entries: 1024 (order: 4, 65536 bytes, linear)
[    0.028634] pinctrl core: initialized pinctrl subsystem
[    0.028934] DMI not present or invalid.
[    0.029340] NET: Registered PF_NETLINK/PF_ROUTE protocol family
[    0.029622] DMA: preallocated 256 KiB GFP_KERNEL pool for atomic allocations
[    0.029656] DMA: preallocated 256 KiB GFP_KERNEL|GFP_DMA pool for atomic allocations
[    0.029688] DMA: preallocated 256 KiB GFP_KERNEL|GFP_DMA32 pool for atomic allocations
[    0.030079] thermal_sys: Registered thermal governor 'fair_share'
[    0.030083] thermal_sys: Registered thermal governor 'bang_bang'
[    0.030090] thermal_sys: Registered thermal governor 'step_wise'
[    0.030095] thermal_sys: Registered thermal governor 'user_space'
[    0.030191] hw-breakpoint: found 6 breakpoint and 4 watchpoint registers.
[    0.030251] ASID allocator initialised with 65536 entries
[    0.040828] cryptd: max_cpu_qlen set to 1000
[    0.041592] iommu: Default domain type: Translated
[    0.041612] iommu: DMA domain TLB invalidation policy: strict mode
[    0.041732] SCSI subsystem initialized
[    0.041834] libata version 3.00 loaded.
[    0.041934] usbcore: registered new interface driver usbfs
[    0.041960] usbcore: registered new interface driver hub
[    0.041983] usbcore: registered new device driver usb
[    0.042210] i2c-gpio i2c-gpio-0: using lines 427 (SDA) and 428 (SCL)
[    0.042329] i2c-gpio i2c-gpio-1: using lines 429 (SDA) and 430 (SCL)
[    0.042369] pps_core: LinuxPPS API ver. 1 registered
[    0.042375] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <[email protected]>
[    0.042390] PTP clock support registered
[    0.043099] vgaarb: loaded
[    0.062401] clocksource: Switched to clocksource arch_sys_counter
[    0.066477] NET: Registered PF_INET protocol family
[    0.066684] IP idents hash table entries: 32768 (order: 6, 262144 bytes, linear)
[    0.067767] tcp_listen_portaddr_hash hash table entries: 1024 (order: 2, 16384 bytes, linear)
[    0.067819] Table-perturb hash table entries: 65536 (order: 6, 262144 bytes, linear)
[    0.067834] TCP established hash table entries: 16384 (order: 5, 131072 bytes, linear)
[    0.067907] TCP bind hash table entries: 16384 (order: 6, 262144 bytes, linear)
[    0.068116] TCP: Hash tables configured (established 16384 bind 16384)
[    0.068215] UDP hash table entries: 1024 (order: 3, 32768 bytes, linear)
[    0.068252] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes, linear)
[    0.068381] NET: Registered PF_UNIX/PF_LOCAL protocol family
[    0.069070] PCI: CLS 0 bytes, default 64
[    0.069231] Unpacking initramfs...
[    0.080664] Initialise system trusted keyrings
[    0.080806] workingset: timestamp_bits=62 max_order=19 bucket_order=0
[    0.083365] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    0.083460] jffs2: version 2.2. (NAND) (SUMMARY)  © 2001-2006 Red Hat, Inc.
[    0.105448] Key type asymmetric registered
[    0.105485] Asymmetric key parser 'x509' registered
[    0.105593] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 248)
[    0.105606] io scheduler mq-deadline registered
[    0.105613] io scheduler kyber registered
[    0.143886] Serial: 8250/16550 driver, 3 ports, IRQ sharing disabled
[    0.165551] 11002000.serial: ttyS0 at MMIO 0x11002000 (irq = 116, base_baud = 2500000) is a ST16650V2
[    0.987596] printk: console [ttyS0] enabled
[    1.012959] 11003000.serial: ttyS1 at MMIO 0x11003000 (irq = 117, base_baud = 1625000) is a ST16650V2
[    1.043370] 11004000.serial: ttyS2 at MMIO 0x11004000 (irq = 118, base_baud = 1625000) is a ST16650V2
[    1.053514] mtk_rng 1020f000.trng: registered RNG driver
[    1.053573] hwrng: no data available
[    1.059382] cacheinfo: Unable to detect cache hierarchy for CPU 0
[    1.072366] loop: module loaded
[    1.077522] spi-nand spi0.0: Winbond SPI NAND was found.
[    1.082871] spi-nand spi0.0: 128 MiB, block size: 128 KiB, page size: 2048, OOB size: 64
[    2.295649] Initramfs unpacking failed: invalid magic at start of compressed archive
[    2.499616] Freeing initrd memory: 563200K
[    2.519564] 4 fixed-partitions partitions found on MTD device spi0.0
[    2.525954] Creating 4 MTD partitions on "spi0.0":
[    2.530734] 0x000000580000-0x000008000000 : "ubi"
[    2.666681] 0x000000380000-0x000000580000 : "fip"
[    2.674167] 0x000000080000-0x000000380000 : "reserved"
[    2.683580] 0x000000000000-0x000000080000 : "bl2"
[    2.690940] sfp sfp1: Host maximum power 1.0W
[    2.695935] sfp sfp2: Host maximum power 1.0W
[    2.701695] tun: Universal TUN/TAP device driver, 1.6
[    2.718896] (unnamed net_device) (uninitialized): fixed link full duplex 1000Mbps not recognised
[    2.728362] mtk_soc_eth 15100000.ethernet: generated random MAC address 02:d0:7d:c3:1c:0b
[    2.736900] mtk_soc_eth 15100000.ethernet eth0: mediatek frame engine at 0xffffffc00b280000, irq 121
[    2.746085] mtk_soc_eth 15100000.ethernet: generated random MAC address 3a:25:4b:49:20:f3
[    2.754513] mtk_soc_eth 15100000.ethernet eth1: mediatek frame engine at 0xffffffc00b280000, irq 121
[    2.763802] PPP generic driver version 2.4.2
[    2.768212] PPP BSD Compression module registered
[    2.772944] PPP Deflate Compression module registered
[    2.777982] NET: Registered PF_PPPOX protocol family
[    2.782956] PPTP driver version 0.8.5
[    2.786768] SLIP: version 0.8.4-NET3.019-NEWTTY (dynamic channels, max=256).
[    2.793864] usbcore: registered new interface driver catc
[    2.799268] usbcore: registered new interface driver kaweth
[    2.804831] pegasus: Pegasus/Pegasus II USB Ethernet driver
[    2.810404] usbcore: registered new interface driver pegasus
[    2.816068] usbcore: registered new interface driver rtl8150
[    2.821711] hso: drivers/net/usb/hso.c: Option Wireless
[    2.826964] usbcore: registered new interface driver hso
[    2.832281] usbcore: registered new interface driver asix
[    2.837686] usbcore: registered new interface driver ax88179_178a
[    2.843790] usbcore: registered new interface driver cdc_ether
[    2.849622] usbcore: registered new interface driver net1080
[    2.855288] usbcore: registered new interface driver cdc_subset
[    2.861205] usbcore: registered new interface driver zaurus
[    2.866787] usbcore: registered new interface driver ipheth
[    2.872364] usbcore: registered new interface driver cdc_ncm
[    2.878029] usbcore: registered new interface driver r8153_ecm
[    2.884067] usbcore: registered new interface driver usb-storage
[    2.890243] i2c_dev: i2c /dev entries driver
[    2.895303] SMCCC: SOC_ID: ID = jep106:0426:7986 Revision = 0x00000000
[    2.901949] usbcore: registered new interface driver usbhid
[    2.907553] usbhid: USB HID core driver
[    2.911583] NET: Registered PF_LLC protocol family
[    2.916445] ipip: IPv4 and MPLS over IPv4 tunneling driver
[    2.922264] gre: GRE over IPv4 demultiplexor driver
[    2.927151] ip_gre: GRE over IPv4 tunneling driver
[    2.932876] NET: Registered PF_INET6 protocol family
[    2.952017] Segment Routing with IPv6
[    2.955091] mmc0: host does not support reading read-only switch, assuming write-enable
[    2.955700] RPL Segment Routing with IPv6
[    2.965515] mmc0: new high speed SDHC card at address 0001
[    2.967706] In-situ OAM (IOAM) with IPv6
[    2.973993] mmcblk0: mmc0:0001 00000 29.8 GiB
[    2.977113] mip6: Mobile IPv6
[    2.984882] sit: IPv6, IPv4 and MPLS over IPv4 tunneling driver
[    2.985754] GPT:Primary header thinks Alt. header is not at the end of the disk.
[    2.991475] ip6_gre: GRE over IPv6 tunneling driver
[    2.998179] GPT:1 != 62521343
[    2.998182] GPT:Alternate GPT header not at the end of the disk.
[    3.004803] NET: Registered PF_PACKET protocol family
[    3.005993] GPT:1 != 62521343
[    3.005995] GPT: Use GNU Parted to correct GPT errors.
[    3.012142] 8021q: 802.1Q VLAN Support v1.8
[    3.017043]  mmcblk0: p1 p2 p3 p4 p5 p6 p7
[    3.020282] Loading compiled-in X.509 certificates
[    3.046507] mtk-pcie-gen3 11280000.pcie: host bridge /soc/pcie@11280000 ranges:
[    3.053896] mtk-pcie-gen3 11280000.pcie: Parsing ranges property...
[    3.060155] mtk-pcie-gen3 11280000.pcie:      MEM 0x0020000000..0x002fffffff -> 0x0020000000
[    3.282410] mtk-pcie-gen3 11280000.pcie: PCIe link down, current LTSSM state: detect.active (0x1000001)
[    3.291834] mtk-pcie-gen3: probe of 11280000.pcie failed with error -110
[    3.335413] mt7530 mdio-bus:1f: no interrupt support
[    3.366528] mt7530 mdio-bus:1f: configuring for fixed/2500base-x link mode
[    3.373698] mt7530 mdio-bus:1f: Link is Up - 2.5Gbps/Full - flow control rx/tx
[    3.382897] mt7530 mdio-bus:1f wan (uninitialized): PHY [mt7530-0:00] driver [MediaTek MT7531 PHY] (irq=POLL)
[    3.402753] mt7530 mdio-bus:1f lan0 (uninitialized): PHY [mt7530-0:01] driver [MediaTek MT7531 PHY] (irq=POLL)
[    3.422409] mt7530 mdio-bus:1f lan1 (uninitialized): PHY [mt7530-0:02] driver [MediaTek MT7531 PHY] (irq=POLL)
[    3.442044] mt7530 mdio-bus:1f lan2 (uninitialized): PHY [mt7530-0:03] driver [MediaTek MT7531 PHY] (irq=POLL)
[    3.461692] mt7530 mdio-bus:1f lan3 (uninitialized): PHY [mt7530-0:04] driver [MediaTek MT7531 PHY] (irq=POLL)
[    3.472570] device eth0 entered promiscuous mode
[    3.477218] DSA: tree 0 setup
[    3.481590] xhci-mtk 11200000.usb: xHCI Host Controller
[    3.486849] xhci-mtk 11200000.usb: new USB bus registered, assigned bus number 1
[    3.497236] xhci-mtk 11200000.usb: hcc params 0x01403f99 hci version 0x110 quirks 0x0000000000210010
[    3.506405] xhci-mtk 11200000.usb: irq 125, io mem 0x11200000
[    3.512221] xhci-mtk 11200000.usb: xHCI Host Controller
[    3.517443] xhci-mtk 11200000.usb: new USB bus registered, assigned bus number 2
[    3.524833] xhci-mtk 11200000.usb: Host supports USB 3.2 Enhanced SuperSpeed
[    3.532370] hub 1-0:1.0: USB hub found
[    3.536149] hub 1-0:1.0: 2 ports detected
[    3.540447] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
[    3.548883] hub 2-0:1.0: USB hub found
[    3.552735] hub 2-0:1.0: 1 port detected
[    3.557193] printk: console [netcon0] enabled
[    3.561552] netconsole: network logging started
[    3.566156] cfg80211: Loading compiled-in X.509 certificates for regulatory database
[    3.580918] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
[    3.590991] Freeing unused kernel memory: 3712K
[    3.652445] Run /init as init process
[    3.656108]   with arguments:
[    3.659065]     /init
[    3.661328]   with environment:
[    3.664467]     HOME=/
[    3.666816]     TERM=linux
[    3.669511]     board=DiagBox
Starting syslogd: OK
Starting klogd: OK
Running sysctl: OK
Populating /dev using udev: [    3.744715] udevd[1099]: starting version 3.2.9
[    3.749702] random: udevd: uninitialized urandom read (16 bytes read)
[    3.756421] random: udevd: uninitialized urandom read (16 bytes read)
[    3.763213] random: udevd: uninitialized urandom read (16 bytes read)
[    3.775896] udevd[1100]: starting eudev-3.2.9
[    3.855463] mtdblock: MTD device 'ubi' is NAND, please consider using UBI block devices instead.
[    3.855812] mtdblock: MTD device 'fip' is NAND, please consider using UBI block devices instead.
[    3.864670] mtdblock: MTD device 'reserved' is NAND, please consider using UBI block devices instead.
[    3.900655] mtdblock: MTD device 'bl2' is NAND, please consider using UBI block devices instead.
[    4.004007] sfp sfp1: please wait, module slow to respond
[    4.012418] usb 1-1: new high-speed USB device number 2 using xhci-mtk
[    4.193296] hub 1-1:1.0: USB hub found
[    4.197119] hub 1-1:1.0: 4 ports detected
done
Saving random seed: OK
Starting rngd: OK
Starting system message bus: done
Starting network: OK
Starting ntpd: OK
Starting php-fpm [    4.612420] usb 1-1.1: new high-speed USB device number 3 using xhci-mtk
 done
Starting dropbear sshd: OK
Starting nginx...
[    7.801459] random: crng init done
[    7.804890] random: 9 urandom warning(s) missed due to ratelimiting
ssh-keygen: generating new host keys: RSA DSA ECDSA ED25519
Starting sshd: OK
Starting inadyn: SKIPPED
atd: created missing .SEQ file (atjobs will be lost on reboot)
Starting atd: OK

I compared with others on https://github.com/openwrt/mt76/issues/702. In mine, i don’t see :

```
mt7986-wmac 18000000.wmac
```

I tried to put the script firmware.sh in /lib/udev :

#!/bin/sh -e

FIRMWARE_DIRS="/lib/firmware/updates/$(uname -r) /lib/firmware/updates \
               /lib/firmware/$(uname -r) /lib/firmware"

err() {
	echo "$@" >&2
	logger -t "${0##*/}[$$]" "$@" 2>/dev/null || true
}

if [ ! -e /sys$DEVPATH/loading ]; then
	err "udev firmware loader misses sysfs directory"
	exit 1
fi

for DIR in $FIRMWARE_DIRS; do
	[ -e "$DIR/$FIRMWARE" ] || continue
	echo 1 > /sys$DEVPATH/loading
	cat "$DIR/$FIRMWARE" > /sys$DEVPATH/data
	echo 0 > /sys$DEVPATH/loading
	exit 0
done

echo -1 > /sys$DEVPATH/loading
err "Cannot find  firmware file '$FIRMWARE'"
mkdir -p /dev/.udev/firmware-missing
file=$(echo "$FIRMWARE" | sed 's:/:\\x2f:g')
ln -s -f "$DEVPATH" /dev/.udev/firmware-missing/$file
exit 1

and modify the 50-udev-default.rules to add : ACTION=="add", SUBSYSTEM=="firmware", RUN+="/lib/udev/firmware.sh"

But i 'm always stuck :frowning:

Thanks by advance to help me :slight_smile:

The line

mt7986-wmac 18000000.wmac

Should appear in dmesg when you load the mt7915e module. Builtin will not work as firmware cannot be loaded (rootfs not ready at this point)

# modprobe mt7915e
# lsmod
Module                  Size  Used by
mt7915e               143360  0
mt76_connac_lib        53248  1 mt7915e
mt76                   81920  2 mt7915e,mt76_connac_lib
# dmesg | grep 'mt7986'
#

Here the ouput when i load the module with modprobe.

Thats strange, can you check if wifi node is enabled?

cat /sys/firmware/devicetree/base/soc/wifi\@18000000/status

Should display okay

It returns “okay”. I tried it before and after load the module.

It does not change…then i guess something is missing in driver. Afair i had tested wifi first in 6.1-rc. I remember watchdog was missing (dts node or driver)

1 Like

Thank you, wifi is ok when i use the kernel 6.1.

The only one problem is for my sfp gpon onu. I have a 2.5gbps but it stays at 1gbps.

i see this Topic.

When i use a kernel 6.0 or lower,it works.

I modify the sfp-bus.c to add the quirks like this :

static const struct sfp_quirk sfp_quirks[] = {
	{
		// Alcatel Lucent G-010S-P can operate at 2500base-X, but
		// incorrectly report 2500MBd NRZ in their EEPROM
		.vendor = "ALCATELLUCENT",
		.part = "G010SP",
		.modes = sfp_quirk_2500basex,
	}, {
		// Alcatel Lucent G-010S-A can operate at 2500base-X, but
		// report 3.2GBd NRZ in their EEPROM
		.vendor = "ALCATELLUCENT",
		.part = "3FE46541AA",
		.modes = sfp_quirk_2500basex,
	}, {
		// Huawei MA5671A can operate at 2500base-X, but report 1.2GBd
		// NRZ in their EEPROM
		.vendor = "HUAWEI",
		.part = "MA5671A",
		.modes = sfp_quirk_2500basex,
	}, {
		// Lantech 8330-262D-E can operate at 2500base-X, but
		// incorrectly report 2500MBd NRZ in their EEPROM
		.vendor = "Lantech",
		.part = "8330-262D-E",
		.modes = sfp_quirk_2500basex,
	}, {
		.vendor = "UBNT",
		.part = "UF-INSTANT",
		.modes = sfp_quirk_ubnt_uf_instant,
	}, {
		.vendor = "SERCOMM",
		.part = "FGS202",
		.modes = sfp_quirk_2500basex,
	}, {
		.vendor = "FS",
		.part = "GSFP-ONU-SC",
		.modes = sfp_quirk_2500basex,
	},
};

My sfp is the last one, the FS.

But in kernel 6.1, there isn’t this part in the files :frowning:

commit 23571c7b96437483d28a990c906cc81f5f66374e
Author: Russell King (Oracle) <[email protected]>
Date:   Tue Sep 13 20:06:32 2022 +0100

    net: sfp: move quirk handling into sfp.c
    
    We need to handle more quirks than just those which affect the link
    modes of the module. Move the quirk lookup into sfp.c, and pass the
    quirk to sfp-bus.c
    
    Signed-off-by: Russell King (Oracle) <[email protected]>
    Signed-off-by: Jakub Kicinski <[email protected]>

drivers/net/phy/sfp-bus.c
drivers/net/phy/sfp.c
drivers/net/phy/sfp.h

:wink:

currently see no cause for wifi not working in 6.0, defconfig and dts seems to have all relevant parts, maybe wifi-driver misses something, but at least compatible is there and in log i see only some fixes (mostly race conditions). if compatible is there and no probe happens then you could debug it, or use 6.1-r3 :wink:

there is also a deferred_probing entry in sysfs where you can look if wifi is deferred by something. but afair it does not show WHY it is deferred. i only remember that there was something with watchdog, but it is enabled in both trees and defconfig has options for it.

Hy :slight_smile: Find the link where you take the information :slight_smile:

I tried to add my quirk :
SFP_QUIRK_M("FS", "GSFP-ONU-SC", sfp_quirk_2500basex),

But always at 1gbps

I see some diffrence between the file (sfp.c and sfp.h) in my kernel and the link for example :

In the file

static const struct sfp_quirk sfp_quirks[] = {
	// Alcatel Lucent G-010S-P can operate at 2500base-X, but incorrectly
	// report 2500MBd NRZ in their EEPROM
	SFP_QUIRK_M("ALCATELLUCENT", "G010SP", sfp_quirk_2500basex),

	//FS
	SFP_QUIRK_M("FS", "GSFP-ONU-SC", sfp_quirk_2500basex),

	// Alcatel Lucent G-010S-A can operate at 2500base-X, but report 3.2GBd
	// NRZ in their EEPROM
	SFP_QUIRK("ALCATELLUCENT", "3FE46541AA", sfp_quirk_2500basex,
		  sfp_fixup_long_startup),

	SFP_QUIRK_F("HALNY", "HL-GSFP", sfp_fixup_halny_gsfp),

	// Huawei MA5671A can operate at 2500base-X, but report 1.2GBd NRZ in
	// their EEPROM
	SFP_QUIRK("HUAWEI", "MA5671A", sfp_quirk_2500basex,
		  sfp_fixup_ignore_tx_fault),

	// Lantech 8330-262D-E can operate at 2500base-X, but incorrectly report
	// 2500MBd NRZ in their EEPROM
	SFP_QUIRK_M("Lantech", "8330-262D-E", sfp_quirk_2500basex),

	SFP_QUIRK_M("UBNT", "UF-INSTANT", sfp_quirk_ubnt_uf_instant),

	SFP_QUIRK_F("OEM", "SFP-10G-T", sfp_fixup_rollball_cc),
	SFP_QUIRK_F("OEM", "RTSFP-10", sfp_fixup_rollball_cc),
	SFP_QUIRK_F("OEM", "RTSFP-10G", sfp_fixup_rollball_cc),
	SFP_QUIRK_F("Turris", "RTSFP-10", sfp_fixup_rollball),
	SFP_QUIRK_F("Turris", "RTSFP-10G", sfp_fixup_rollball),
};

And in the website:

+static const struct sfp_quirk sfp_quirks[] = {
+	{
+		// Alcatel Lucent G-010S-P can operate at 2500base-X, but
+		// incorrectly report 2500MBd NRZ in their EEPROM
+		.vendor = "ALCATELLUCENT",
+		.part = "G010SP",
+		.modes = sfp_quirk_2500basex,
+	}, {
+		// Alcatel Lucent G-010S-A can operate at 2500base-X, but
+		// report 3.2GBd NRZ in their EEPROM
+		.vendor = "ALCATELLUCENT",
+		.part = "3FE46541AA",
+		.modes = sfp_quirk_2500basex,
+	}, {
+		// Huawei MA5671A can operate at 2500base-X, but report 1.2GBd
+		// NRZ in their EEPROM
+		.vendor = "HUAWEI",
+		.part = "MA5671A",
+		.modes = sfp_quirk_2500basex,
+	}, {
+		// Lantech 8330-262D-E can operate at 2500base-X, but
+		// incorrectly report 2500MBd NRZ in their EEPROM
+		.vendor = "Lantech",
+		.part = "8330-262D-E",
+		.modes = sfp_quirk_2500basex,
+	}, {
+		.vendor = "UBNT",
+		.part = "UF-INSTANT",
+		.modes = sfp_quirk_ubnt_uf_instant,
+	},
+};
+

I ave not taken it from a link…i searched in git directly

git log 6.0-r3..6.1-r3 -- file

My 6.1 does real auto-negotation because of russels patch. Maybe this is the cause. You can revert it and revert the reverts from mtk_get_pcs_state

Please do a

ethtool eth1
ethtool -m eth1

First (use your right interface)

You can also try reverting changes in sfp*.c

Here the output of the command lines you advised me :

# ethool eth1
-bash: ethool: command not found
# ethtool eth1
Settings for eth1:
        Supported ports: [ FIBRE ]
        Supported link modes:   2500baseX/Full
                                1000baseX/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: 10Mb/s
        Duplex: Half
        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
# ethtool -m eth1
        Identifier                                : 0x03 (SFP)
        Extended identifier                       : 0x04 (GBIC/SFP defined by 2-                             wire interface ID)
        Connector                                 : 0x01 (SC)
        Transceiver codes                         : 0x00 0x00 0x00 0x02 0x00 0x0                             0 0x00 0x00 0x00
        Transceiver type                          : Ethernet: 1000BASE-LX
        Encoding                                  : 0x03 (NRZ)
        BR, Nominal                               : 1200MBd
        Rate identifier                           : 0x00 (unspecified)
        Length (SMF,km)                           : 20km
        Length (SMF)                              : 20000m
        Length (50um)                             : 0m
        Length (62.5um)                           : 0m
        Length (Copper)                           : 0m
        Length (OM3)                              : 0m
        Laser wavelength                          : 1310nm
        Vendor name                               : FS
        Vendor OUI                                : 00:00:00
        Vendor PN                                 : GSFP-ONU-SC
        Vendor rev                                : 01
        Option values                             : 0x00 0x1a
        Option                                    : RX_LOS implemented
        Option                                    : TX_FAULT implemented
        Option                                    : TX_DISABLE implemented
        BR margin, max                            : 0%
        BR margin, min                            : 0%
        Vendor SN                                 : SCOM210A1F5A
        Date code                                 : 211007
        Optical diagnostics support               : Yes
        Laser bias current                        : 0.000 mA
        Laser output power                        : 0.0001 mW / -40.00 dBm
        Receiver signal average optical power     : 0.0001 mW / -40.00 dBm
        Module temperature                        : 24.16 degrees C / 75.48 degr                             ees F
        Module voltage                            : 3.2736 V
        Alarm/warning flags implemented           : Yes
        Laser bias current high alarm             : Off
        Laser bias current low alarm              : Off
        Laser bias current high warning           : Off
        Laser bias current low warning            : Off
        Laser output power high alarm             : Off
        Laser output power low alarm              : On
        Laser output power high warning           : Off
        Laser output power low warning            : On
        Module temperature high alarm             : Off
        Module temperature low alarm              : Off
        Module temperature high warning           : Off
        Module temperature low warning            : Off
        Module voltage high alarm                 : Off
        Module voltage low alarm                  : Off
        Module voltage high warning               : Off
        Module voltage low warning                : Off
        Laser rx power high alarm                 : Off
        Laser rx power low alarm                  : On
        Laser rx power high warning               : Off
        Laser rx power low warning                : On
        Laser bias current high alarm threshold   : 90.000 mA
        Laser bias current low alarm threshold    : 0.000 mA
        Laser bias current high warning threshold : 70.000 mA
        Laser bias current low warning threshold  : 0.000 mA
        Laser output power high alarm threshold   : 6.3095 mW / 8.00 dBm
        Laser output power low alarm threshold    : 0.5623 mW / -2.50 dBm
        Laser output power high warning threshold : 5.0118 mW / 7.00 dBm
        Laser output power low warning threshold  : 0.7079 mW / -1.50 dBm
        Module temperature high alarm threshold   : 95.00 degrees C / 203.00 deg                             rees F
        Module temperature low alarm threshold    : -50.00 degrees C / -58.00 de                             grees F
        Module temperature high warning threshold : 90.00 degrees C / 194.00 deg                             rees F
        Module temperature low warning threshold  : -45.00 degrees C / -49.00 de                             grees F
        Module voltage high alarm threshold       : 3.6000 V
        Module voltage low alarm threshold        : 3.0000 V
        Module voltage high warning threshold     : 3.5000 V
        Module voltage low warning threshold      : 3.1000 V
        Laser rx power high alarm threshold       : 0.3162 mW / -5.00 dBm
        Laser rx power low alarm threshold        : 0.0008 mW / -30.97 dBm
        Laser rx power high warning threshold     : 0.2511 mW / -6.00 dBm
        Laser rx power low warning threshold      : 0.0010 mW / -30.00 dBm
#

mtk_get_pcs_state is in the kernel Defconfig?

i will find too in sfp.c for the reverting

So it seems no problem with the mtk_pcs_get_state (it is callback in mtk ethernet driver in sgmii-source, so it looks like the problem you found with sfp quirks. So try reverting the commits (top to bottom - last commits first) in the sfp-core till you get a working state

If i understand your post, the problem is in the quirks. So, i must see in the sfp.c,am i not?

i don’t really understand what you said with reverting commits and the sfp-core

Sorry to ask you that,but like i said you, i am still a newbie and learn with internet :slight_smile:

Revert is rollback of commits. It is a git command wich creates a new commit with changes of the source commit rolled back. So if you have in file x the commits A,B,C (A = oldest) you can roll back these changes with

git revert C
git revert B
git revert A

Just use the log command above to get commitids from changes in the sfp directory and the revert the changes step by step,apply your changes and test

$ git log --oneline 6.0-r3..6.1-r3 -- ./drivers/net/phy/sfp*
5b4c189d660a net: sfp: fill also 5gbase-r and 25gbase-r modes in sfp_parse_support()
324e88cbe3b7 net: sfp: add support for multigig RollBall transceivers
09bbedac72d5 net: phy: mdio-i2c: support I2C MDIO protocol for RollBall SFP modules
e85b1347ace6 net: sfp: create/destroy I2C mdiobus before PHY probe/after PHY release
13c8adcf221f net: sfp: Add and use macros for SFP quirks definitions
fd580c983031 net: sfp: augment SFP parsing with phy_interface_t bitmap
73472c830eae net: sfp: add support for HALNy GPON SFP
5029be761161 net: sfp: move Huawei MA5671A fixup
275416754e9a net: sfp: move Alcatel Lucent 3FE46541AA fixup
23571c7b9643 net: sfp: move quirk handling into sfp.c
8475c4b70b04 net: sfp: re-implement soft state polling setup
815f5f574144 net: sfp: use simplified HWMON_CHANNEL_INFO macro

so you can try to revert from top to bottom

Hy Thank you for the Explications

I tried with the kernel 6.0, and apply the patch mentionned. The quirk is respected ( see in the ethtool eth1). And wifi works too :).

Another question ^^

I know we can use LEDs green and blue thanks to gpio in sys/class/gpio.

I Seen in /sys/class/led the two LEDs but also, when i load the module wifi, another led. When i change the content of this one, thé Z led 2.4g brights, not the 5g. But when i tried to Switch off to change again the content, the LED still brights. I don’t succeed to Switch on the led 5g and to Switch off After switching on manually.

6.0 or 6.1 (wifi already working,but sfp only 1g)?

Which patch have you applied? The revert(s)? Wich patches have you reverted? Goal is to find out patch that breaks functionality. If you find the one,we can look why your addition is not working.

For leds only 1 gree and one blue can be controlled via sysfs. The others are imho connected to their “function source” (here wifi chip MT7986IAP) but i have not veried the leds yet. As far as i see i should see nearly all leds lighten/blinking

edit: no wifi-led lighten up when i activate the hostapd on both wlan-interfaces. sysfs contains only mt76-phy0 led entry which is w2g led when i set brightness, but does not go off

@sinovoip @simon how should leds work? do i miss anything in dts? how about ssd and lte led have not seen them when using the device

Edit: for ssd it seems to be pin 10 of ngff slot which is “Device Activity Signal / Disable Staggered Spinup” so should be lighten only on activity. Wifi is connected to 2 pins (k21/k22) of wifi-chip i do not know their detailed function (active,mode,connection,…). Lte is pin42 (LED_WWAN#(OC)) where i have to look if my em7455 and pcie2m2 adapter brings this through

1 Like

Hy, Sorry to answer you only now, a lot of works.

Now, i returned with the kernel 6.0 of your repository. And i have applied this patch for sfp.c,sfp.h and sfp-bus.c

patch =>>> [Here](https://lore.kernel.org/netdev/[email protected]/)

Here the output of ethtool eth1

# 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: Yes
        Advertised FEC modes: Not reported
        Speed: 10Mb/s
        Duplex: Half
        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

I no longer have 1000baseX/Full.

I will tried the link this weekd, i must to modify my interfaces conf,dhcp to connect to my provider fiber line.

I wil ltell you if it’s really ok ^^

Thank you for the others informations about led, i will work on it.

I do not understand…i thought sfp was already working on 6.0…but not wifi. So you have to revert sfp patches from 6.1 or apply wifi-patches in 6.0

Sorry, i didn’t go enought into détails.

I have downloaded the sources of kernel 6.0-r3 from your repository Yesterday.

Before Yesterday night, when i worked on kernel 6.0-r3, it was an old version i has downloaded there was more one month i think. And Yesterday, i started from zero for my config files, using your defconfig dedicated R3 and not my old one.

So now, wifi works on 6.0 and sfp quirk load good, according to the Line command ethtool eth1.

This weekend, i will modify all interfaces and DHCP conf to connect directly my bpi to my fiber Line and will rater my speedtest.