Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Kernel & Hardware
  • Search

Mediatek wi-fi 7921 does not work

Kernel not recognizing your hardware? Problems with power management or PCMCIA? What hardware is compatible with Gentoo? See here. (Only for kernels supported by Gentoo.)
Post Reply
Advanced search
4 posts • Page 1 of 1
Author
Message
Blackmorse
n00b
n00b
Posts: 52
Joined: Sun Mar 28, 2021 2:11 pm

Mediatek wi-fi 7921 does not work

  • Quote

Post by Blackmorse » Sun Jun 26, 2022 7:57 am

Following this thread: viewtopic-p-8683048.html, seems that patch mentioned there is not in 5.15 kernel,
but 5.17 does already have it: https://github.com/torvalds/linux/blob/ ... 7921/pci.c.

So I have 5.17 kernel and still are unable to make my wi-fi work

Code: Select all

#: uname -r
5.17.15-gentoo

Code: Select all

#: lspci | grep Wireless

04:00.0 Network controller: MEDIATEK Corp. MT7921 802.11ax PCI Express Wireless Network Adapter

Code: Select all

#: cat /etc/modules-load.d/network.conf

mt7921e

Code: Select all

#: dmesg | grep 7921

...
mt7921e 0000:04:00.0: Direct firmware load for mediatek/WIFI_MT7961_patch_mcu_1_2_hdr.bin failed with error -2
...
File mediatek/WIFI_MT7961_patch_mcu_1_2_hdr.bin is present at /lib/firmware/mediatek
Top
pietinger
Moderator
Moderator
Posts: 6620
Joined: Tue Oct 17, 2006 5:11 pm
Location: Bavaria

Re: Mediatek wi-fi 7921 does not work

  • Quote

Post by pietinger » Sun Jun 26, 2022 9:35 am

Blackmorse wrote:

Code: Select all

#: dmesg | grep 7921
...
mt7921e 0000:04:00.0: Direct firmware load for mediatek/WIFI_MT7961_patch_mcu_1_2_hdr.bin failed with error -2
...
File mediatek/WIFI_MT7961_patch_mcu_1_2_hdr.bin is present at /lib/firmware/mediatek
This means: You have compiled module mt7921e STATIC into your kernel AND the firmware is NOT STATIC into your kernel => THEN the module cant load the firmware (at this time kernel has no access to its root partition). Here I gave an example how to put firmware also static into a kernel: viewtopic-t-1065464.html

Another soultion would be to compile module mt7921e as <M>odule into your kernel; then this module will be able to load its firmware at boottime (because its loaded later when kernel has access to root partition and /lib/firmware ...).
Top
NeddySeagoon
Administrator
Administrator
User avatar
Posts: 56078
Joined: Sat Jul 05, 2003 9:37 am
Location: 56N 3W

  • Quote

Post by NeddySeagoon » Sun Jun 26, 2022 11:00 am

Blackmorse,

Its a given that the kernel will load firmware when the module that needs it initialises.

For built in things, that's before root is mounted.
For loadable modules, that's after root is mounted.

If the first case, all the firmware the module needs must be built into the firmware, not just the

Code: Select all

mediatek/WIFI_MT7961_patch_mcu_1_2_hdr.bin
file that was listed in dmesg.
The kernel gives up after the first failure. If you add that, there will be another and so on, until it will work.

Code: Select all

/etc/modules-load.d/network.conf 
can only be consulted if the the code is a loadable module.
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Top
Blackmorse
n00b
n00b
Posts: 52
Joined: Sun Mar 28, 2021 2:11 pm

  • Quote

Post by Blackmorse » Sun Jun 26, 2022 12:26 pm

Thanks all,
Making mt7921e as <M>odule did the job
Top
Post Reply

4 posts • Page 1 of 1

Return to “Kernel & Hardware”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic