之前适配的intel8265模块有点小贵,这里再适配另一款wifi模块RTL8821。经验在上一篇文章可以参考基于龙芯2K1000适配WIFI模块(型号:Intel 8265NGW),这里主要记录一些新问题。并且将此模块的蓝牙功能驱动一下。
1 wifi功能
首先确保模块及电路是没有问题的,用命令查看一下,RTL8821AE能被识别:
[loongson@localhost ~]$ lspci -v
04:00.0 USB controller: Renesas Technology Corp. uPD720201 USB 3.0 Host Controller (rev 03) (prog-if 30 [XHCI])
Flags: bus master, fast devsel, latency 0, IRQ 138
Memory at 40400000 (64-bit, non-prefetchable) [size=8K]
Capabilities: <access denied>
Kernel driver in use: xhci_hcd
08:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8821AE 802.11ac PCIe Wireless Network Adapter
Subsystem: Realtek Semiconductor Co., Ltd. Device 2162
Flags: bus master, fast devsel, latency 0, IRQ 42
I/O ports at 6000 [size=256]
Memory at 40300000 (64-bit, non-prefetchable) [size=16K]
Capabilities: <access denied>
1.1 linux3.10
环境:pmon+linux3.10+loongnix1.0
正如适配Intel 8265NGW模块文章写道,需要改动的不多,主要在内核里选中以下参数就可以使用了,不做过多描述:
Device Drivers > Network device support > Wireless LAN > Realtek rtlwifi family of devices > Realtek RTL8821AE/RTL8812AE Wireless Network Adapter
1.2 linux4.19
环境:uboot+linux4.19+buildroot
内核选上:
Device Drivers > Network device support > Wireless LAN > Realtek rtlwifi family of devices > Realtek RTL8821AE/RTL8812AE Wireless Network Adapter
问题:
[ 3.516805] pci 0000:08:00.0: [10ec:8821] type 00 class 0x028000
[ 3.553800] rtl8821ae: Using firmware rtlwifi/rtl8821aefw_29.bin
[ 3.559951] rtl8821ae 0000:08:00.0: Direct firmware load for rtlwifi/rtl8821aefw_29.bin failed with error -2
[ 3.569869] rtl8821ae: Using firmware rtlwifi/rtl8821aefw_wowlan.bin
[ 3.569916] rtl8821ae 0000:08:00.0: Direct firmware load for rtlwifi/rtl8821aefw.bin failed with error -2