microsoft / microsoft/WSL

Enable CONFIG_MAC80211_HWSIM=m on x86 (config-wsl) to match arm64

Open
#41,184 4 comments 0 reactions 1 assignee View on GitHub

@chessturo is already working on this.

Since Jul 28, 2026.

feature kernel
Dominant language
C++
Stars
33.7k
Forks
1.8k
Avg merge
3d 17h
Merged PRs (30d)
116

Description

**Is your feature request related to a problem? Please describe.**
The x86_64 WSL2 kernel can't load `mac80211_hwsim`, which blocks virtual-radio Wi-Fi userspace testing (`nl80211` / `wpa_supplicant` / `hostapd` / `iw`). The rest of the stack is already present: `CONFIG_MODULES=y`, `CONFIG_CFG80211=m`, `CONFIG_MAC80211=m`, `CONFIG_WLAN=y`. Notably, `config-wsl-arm64` already sets `CONFIG_MAC80211_HWSIM=m`, so this looks like an unintended x86/arm64 config inconsistency rather than a deliberate exclusion.

**Describe the solution you'd like**
Bring x86 to parity with arm64 by setting the option in `arch/x86/configs/config-wsl`:

```diff
diff --git a/arch/x86/configs/config-wsl b/arch/x86/configs/config-wsl
index 61f65876cbb7..3d4f8a00b862 100755
--- a/arch/x86/configs/config-wsl
+++ b/arch/x86/configs/config-wsl
@@ -3249,7 +3249,7 @@ CONFIG_WLAN_VENDOR_ZYDAS=y
# CONFIG_ZD1211RW is not set
CONFIG_WLAN_VENDOR_QUANTENNA=y
# CONFIG_QTNFMAC_PCIE is not set
-# CONFIG_MAC80211_HWSIM is not set
+CONFIG_MAC80211_HWSIM=m
# CONFIG_VIRT_WIFI is not set
# CONFIG_WAN is not set
```

**Describe alternatives you've considered**
- Building a custom WSL2 kernel with the option enabled: every WSL user who wants virtual-radio testing then has to maintain a private kernel + `.wslconfig kernel=` override that a WSL kernel update silently reverts.
- Out-of-tree `mac80211_hwsim.ko`: not viable; WSL ships no `/lib/modules/$(uname -r)/build` tree and vermagic must match.

**Additional context**
Concrete consumer: the Zephyr RTOS `native_sim` Wi-Fi driver (https://github.com/zephyrproject-rtos/zephyr/pull/110681) drives a `mac80211_hwsim` radio via host `nl80211`; on x86_64 WSL2 this missing module is the only blocker.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.