From fd38b18bb70d499d5cf569d53fe20b38af91c742 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mattias=20Walstr=C3=B6m?= Date: Tue, 20 Jan 2026 22:19:46 +0100 Subject: [PATCH] Revert "udev: Always enumerate wifi phys from 0" This reverts commit bf1eca05679ed288d3b99e5a9814874f8618fc7a. This mess up order if having more than 1 phy, have not been reproduce the error that got me to introduce this fix from the beginning. --- .../rootfs/etc/udev/rules.d/60-rename-wifi-phy.rules | 2 +- board/common/rootfs/usr/libexec/infix/rename-wifi-phy | 8 -------- 2 files changed, 1 insertion(+), 9 deletions(-) delete mode 100755 board/common/rootfs/usr/libexec/infix/rename-wifi-phy diff --git a/board/common/rootfs/etc/udev/rules.d/60-rename-wifi-phy.rules b/board/common/rootfs/etc/udev/rules.d/60-rename-wifi-phy.rules index a7449506..89c64154 100644 --- a/board/common/rootfs/etc/udev/rules.d/60-rename-wifi-phy.rules +++ b/board/common/rootfs/etc/udev/rules.d/60-rename-wifi-phy.rules @@ -1,3 +1,3 @@ # Rename WiFi PHY devices from phy0 to radio0 to avoid name clashes SUBSYSTEM=="ieee80211", ACTION=="add", KERNEL=="phy*", \ - RUN+="/usr/libexec/infix/rename-wifi-phy %k" + RUN+="/bin/sh -c '/usr/sbin/iw phy %k set name radio%n'" diff --git a/board/common/rootfs/usr/libexec/infix/rename-wifi-phy b/board/common/rootfs/usr/libexec/infix/rename-wifi-phy deleted file mode 100755 index b50dcda8..00000000 --- a/board/common/rootfs/usr/libexec/infix/rename-wifi-phy +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh -# Rename WiFi PHY to radio{N}, enumerating from 0 -phy="$1" -n=0 -while [ -d "/sys/class/ieee80211/radio$n" ]; do - n=$((n + 1)) -done -/usr/sbin/iw phy "$phy" set name "radio$n"