1.\" 2.\" SPDX-License-Identifier: BSD-2-Clause 3.\" 4.\" Copyright (c) 2025 The FreeBSD Foundation 5.\" 6.\" This documentation was written by Bj\xc3\xb6rn Zeeb under sponsorship from 7.\" the FreeBSD Foundation. 8.\" 9.Dd June 13, 2025 10.Dt LINUXKPI_WLAN 4 11.Os 12.Sh NAME 13.Nm linuxkpi_wlan 14.Nd LinuxKPI 802.11 support 15.Sh DESCRIPTION 16The 17.Nm 18kernel module provides an 802.11 compat layer to translate between Linux 19802.11 drivers and the native net8011 wireless stack. 20It currently supports 21.Em mac80211 22based drivers. 23Parts of the 24.Em cfg80211 25exist but there is no code for net80211 to drive it. 26.Pp 27.Nm 28currently supports the following 29.Em wlanmode 30operating modes: 31.Bl -tag -width monitor -compact 32.It Cm sta 33client station in an infrastructure bss (IBSS). 34.El 35.Pp 36Compat code for 802.11n (HT) and 802.11ac (VHT) is implemented but 37support may vary for different drivers due to different KPI usage. 38.Pp 39Crypto support for hardware acceleration needs to be enabled using the 40.Va compat.linuxkpi.80211.hw_crypto 41tunable. 42The following cipher suites are supported: 43.Bl -tag -width CCMP -compact 44.It Cm tkip 45Support for 46.Xr wlan_tkip 4 47has to be manually enabled using the 48.Va compat.linuxkpi.80211.tkip 49tunable. 50.It Cm ccmp 51Support for 52.Xr wlan_ccmp 4 53is available. 54.It Cm gcmp 55Support for 56.Xr wlan_gcmp 4 57is available. 58.El 59Further cipher suites will be implemented as soon as 60.Xr net80211 4 61grows support. 62While it would be possible to implement 63.Xr wlan_wep 4 64support, it was decided not to do so given 65.Em Wired Equivalent Privacy (WEP) 66has been deprecated since 2004. 67.Pp 68The list of supported drivers includes 69.Xr iwlwifi 4 , 70.Xr rtw88 4 , 71and 72.Xr rtw89 4 . 73.Sh SYSCTL VARIABLES AND LOADER TUNABLES 74The 75.Nm 76module supports the following 77.Xr loader 8 78tunable and read-only 79.Xr sysctl 8 80variables: 81.Bl -tag -width "compat.linuxkpi.80211.hw_crypto" 82.It Va compat.linuxkpi.80211.hw_crypto 83Turn on hardware crypto offload support. 84Default 85.Ql 0 . 86.It Va compat.linuxkpi.80211.tkip 87Turn on support for 88.Xr wlan_tkip 4 89offloading. 90Default 91.Ql 0 . 92.El 93.Pp 94The 95.Nm 96module supports the following 97.Xr sysctl 8 98variables: 99.Bl -tag -width "compat.linuxkpi.80211.IF.dump_stas" 100.It Va compat.linuxkpi.80211.debug 101If the kernel is compiled with 102.Dv IEEE80211_DEBUG 103or 104.Dv LINUXKPI_DEBUG_80211 105is manually enabled, the sysctl is a bitmask to turn on individual 106debug messages. 107See 108.Pa sys/compat/linuxkpi/common/src/linux_80211.h 109for details. 110.It Va compat.linuxkpi.80211.IF.dump_stas 111Print statistics for a given, associated 112.Xr wlan 4 113interface; typically IF would be 114.Em wlan0 . 115.El 116.Sh SEE ALSO 117.Xr iwlwifi 4 , 118.Xr linuxkpi 4 , 119.Xr rtw88 4 , 120.Xr rtw89 4 , 121.Xr wlan 4 122.Sh HISTORY 123The 124.Nm 125module first appeared in 126.Fx 13.1 . 127Support for IEEE 802.11n and 802.11ac in 128.Nm 129first appeared in 130.Fx 14.3 . 131.Sh AUTHORS 132LinuxKPI 802.11 support was developed by 133.An Bjoern A. Zeeb 134under sponsorship from the FreeBSD Foundation. 135