MediaTek MT7922 WiFi 6 and Bluetooth 5.3 modules have recently been found in several mini PCs, but Bluetooth would not work in Linux due to a lack of drivers. In this post, we’ll show how to easily enable Bluetooth in MediaTek MT7922 modules when running Ubuntu 24.04.
We previously noted that Ian Morrisson submitted a patch adding the IDs for the MT7922 module (Azurewave AW-XB591NF) used in recent GEEKOM mini PCs last March. In theory, you could have rebuilt the Linux kernel, but now that Linux 6.10 has been released, it’s much easier since Canonical has made the Linux 6.10 kernel available for Ubuntu, so we only need to install it and problem solved!
Ubuntu 24.04 ships with Linux 6.8, we can see a Bluetooth opcode error in the kernel log.
1 2 3 4 5 6 7 8 9 10 11 12 13 |
aey@AE7-CNX:~$ uname -a Linux AE7-CNX 6.8.0-38-generic #38-Ubuntu SMP PREEMPT_DYNAMIC Fri Jun 7 15:25:01 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux aey@AE7-CNX:~$ dmesg | grep -i bluetooth [ 7.341849] Bluetooth: Core ver 2.22 [ 7.341877] NET: Registered PF_BLUETOOTH protocol family [ 7.341879] Bluetooth: HCI device and connection manager initialized [ 7.341884] Bluetooth: HCI socket layer initialized [ 7.341888] Bluetooth: L2CAP socket layer initialized [ 7.341894] Bluetooth: SCO socket layer initialized [ 8.863982] Bluetooth: BNEP (Ethernet Emulation) ver 1.3 [ 8.863987] Bluetooth: BNEP filters: protocol multicast [ 8.863991] Bluetooth: BNEP socket layer initialized [ 9.446360] Bluetooth: hci0: Opcode 0x0c03 failed: -110 |
If you go to the settings to enable Bluetooth, you’ll be greeted with a “Bluetooth Turned Off” window and a greyed-out toggle button that can’t be slid right to enable Bluetooth.
We can enable Bluetooth by downloading Linux 6.10 or greater from the Ubuntu mainline kernel server. Sadly the amd64 images for Linux 6.10 are not available yet.
For testing, I downloaded Linux 6.10-rc4 images and installed them as follows:
1 2 3 4 5 |
wget https://kernel.ubuntu.com/mainline/v6.10-rc4/amd64/linux-headers-6.10.0-061000rc4-generic_6.10.0-061000rc4.202406161734_amd64.deb wget https://kernel.ubuntu.com/mainline/v6.10-rc4/amd64/linux-headers-6.10.0-061000rc4_6.10.0-061000rc4.202406161734_all.deb wget https://kernel.ubuntu.com/mainline/v6.10-rc4/amd64/linux-image-unsigned-6.10.0-061000rc4-generic_6.10.0-061000rc4.202406161734_amd64.deb wget https://kernel.ubuntu.com/mainline/v6.10-rc4/amd64/linux-modules-6.10.0-061000rc4-generic_6.10.0-061000rc4.202406161734_amd64.deb sudo dpkg -i *.deb |
After a reboot, we can verify Linux 6.10 is running and Bluetooth is indeed enabled.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
aey@AE7-CNX:~$ uname -a Linux AE7-CNX 6.10.0-061000rc4-generic #202406161734 SMP PREEMPT_DYNAMIC Sun Jun 16 21:47:04 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux aey@AE7-CNX:~$ dmesg | grep -i bluetooth [ 1.544918] Bluetooth: Core ver 2.22 [ 1.544956] NET: Registered PF_BLUETOOTH protocol family [ 1.544958] Bluetooth: HCI device and connection manager initialized [ 1.544964] Bluetooth: HCI socket layer initialized [ 1.544968] Bluetooth: L2CAP socket layer initialized [ 1.544974] Bluetooth: SCO socket layer initialized [ 1.555268] Bluetooth: hci0: HW/SW Version: 0x008a008a, Build Time: 20240219103618 [ 3.807004] Bluetooth: hci0: Device setup in 2201591 usecs [ 3.807017] Bluetooth: hci0: HCI Enhanced Setup Synchronous Connection command is advertised, but not supported. [ 3.864865] Bluetooth: hci0: AOSP extensions version v1.00 [ 3.864875] Bluetooth: hci0: AOSP quality report is supported [ 4.853938] Bluetooth: BNEP (Ethernet Emulation) ver 1.3 [ 4.853944] Bluetooth: BNEP filters: protocol multicast [ 4.853951] Bluetooth: BNEP socket layer initialized [ 4.855511] Bluetooth: MGMT ver 1.22 [ 6.539271] Bluetooth: RFCOMM TTY layer initialized [ 6.539280] Bluetooth: RFCOMM socket layer initialized [ 6.539285] Bluetooth: RFCOMM ver 1.11 |
We tested this with the GEEKOM AE7 mini PC and it works with the Azurewave AW-XB591NF module, but other MT7922 module brands might have other HW IDs and your mileage may vary. You should avoid using RC releases on production machines, and it may be worth waiting for the Linux 6.10 image to become available. Note that Canonical releases mainline Linux images without commitment they work and does not provide support for these. The Ubuntu 24.04.1 release is scheduled for August 15 and might include the necessary changes to enable Bluetooth on such MT7922 modules (TBC). Other Linux distributions should also work as long as you can install Linux 6.10.
Jean-Luc started CNX Software in 2010 as a part-time endeavor, before quitting his job as a software engineering manager, and starting to write daily news, and reviews full time later in 2011.
Support CNX Software! Donate via cryptocurrencies, become a Patron on Patreon, or purchase goods on Amazon or Aliexpress