1.\"- 2.\" Copyright (c) 2023-2024 Bjoern A. Zeeb 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. 9.\" 2. Redistributions in binary form must reproduce the above copyright 10.\" notice, this list of conditions and the following disclaimer in the 11.\" documentation and/or other materials provided with the distribution. 12.\" 13.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 14.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 15.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 16.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 17.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23.\" SUCH DAMAGE. 24.\" 25.\" $FreeBSD$ 26.\" 27.Dd October 12, 2024 28.Dt RTW89 4 29.Os 30.Sh NAME 31.Nm rtw89 32.Nd Realtek IEEE 802.11ax wireless network driver 33.Sh SYNOPSIS 34The driver will auto-load without any user interaction using 35.Xr devmatch 8 36if enabled in 37.Xr rc.conf 5 . 38.Pp 39Only if auto-loading is explicitly disabled, place the following 40lines in 41.Xr rc.conf 5 42to manually load the driver as a module at boot time: 43.Bd -literal -offset indent 44kld_list="${kld_list} if_rtw89" 45.Ed 46.Pp 47It is discouraged to load the driver from 48.Xr loader 8 . 49.Sh DESCRIPTION 50The 51.Nm 52driver is derived from Realtek's Linux rtw89 driver. 53.Pp 54This driver requires firmware to be loaded before it will work. 55The package 56.Pa wifi-firmware-rtw89-kmod 57from the 58.Pa ports/net/wifi-firmware-rtw89-kmod 59port needs to be installed before the driver is loaded. 60Otherwise no 61.Xr wlan 4 62interface can be created using 63.Xr ifconfig 8 . 64One should use 65.Xr fwget 8 66to install the correct firmware package. 67.Pp 68The driver uses the 69.\" No LinuxKPI man pages so no .Xr here. 70.Em linuxkpi_wlan 71and 72.Em linuxkpi 73compat framework to bridge between the Linux and 74native 75.Fx 76driver code as well as to the native 77.Xr net80211 4 78wireless stack. 79.Pp 80While 81.Nm 82supports all 802.11 a/b/g/n/ac and ax 83the compatibility code currently only supports 802.11 a/b/g modes. 84Support for 802.11 n/ac is to come. 85.Sh LOADER TUNABLES 86.Bl -tag -width indent 87.It Va compat.linuxkpi.skb.mem_limit 88If you are running a 64bit system with more than 4GB of main memory 89you need to set this tunable to 90.Sy 1 91in 92.Xr loader.conf 5 93and reboot once to make it effective. 94This tunable will work around a problem with DMA and limit allocations 95for network buffer memory to the lower 32bit of physical memory and 96make the driver work. 97.El 98.Sh HARDWARE 99The 100.Nm 101driver supports PCIe devices with the following chipsets: 102.Pp 103.Bl -tag -width Ds -offset indent -compact 104.It Realtek 8851BE Wi-Fi 6 (RTL8851BE) 105.It Realtek 8852AE Wi-Fi 6 (RTL8852AE) 106.It Realtek 8852BE Wi-Fi 6 (RTL8852BE) 107.It Realtek 8852CE Wi-Fi 6E (RTL8852CE) 108.It Realtek 8922AE Wi-Fi 7 (RTL8922AE) 109.El 110.Sh BUGS 111Certainly. 112.Pp 113Does not seem to work (reliably) on machines with more than 4GB of 114main memory. 115See in the 116.Sx LOADER TUNABLES 117section above. 118.Sh SEE ALSO 119.Xr wlan 4 , 120.Xr fwget 8 , 121.Xr ifconfig 8 , 122.Xr wpa_supplicant 8 123.Sh HISTORY 124The 125.Nm 126driver first appeared in 127.Fx 14.2 . 128