Bugzilla – Bug 1179308
Image X11 for Raspberry Pi 3B is missing packages for WLAN for 2.4GHz channel 12 and 13
Last modified: 2021-01-12 09:33:15 UTC
this fact leads even after adding the line options cfg80211 ieee80211_regdom=DE in /etc/modprobe.d/99-local.conf and reloading both cfg80211 and brcmfmac kernel modules ... in the kernel logs I see: [ 9360.888829] usbcore: deregistering interface driver brcmfmac [ 9378.151397] cfg80211: Loading compiled-in X.509 certificates for regulatory database [ 9378.152331] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7' [ 9378.152533] platform regulatory.0: Direct firmware load for regulatory.db failed with error -2 [ 9378.152545] cfg80211: failed to load regulatory.db [ 9382.598023] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac43430-sdio for chip BCM43430/1 [ 9382.598335] usbcore: registered new interface driver brcmfmac [ 9382.725940] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac43430-sdio for chip BCM43430/1 [ 9382.726020] brcmfmac: brcmf_c_process_clm_blob: no clm_blob available (err=-2), device may have limited channels available [ 9382.726514] brcmfmac: brcmf_c_preinit_dcmds: Firmware: BCM43430/1 wl0: Oct 23 2017 03:55:53 version 7.45.98.38 (r674442 CY) FWID 01-e58d219f in other words theregulatory.bin is missed, compare with https://forum-raspberrypi.de/forum/thread/34332-rpi3-trotz-kernel-4-4-50-kein-wlan-kanal-12-13
It seems that a major part is also missed to be able to fully use the WLAN: https://wireless.wiki.kernel.org/en/developers/regulatory/crda
First ... the image indeed misses the package wireless-regdb ... currently I do not see how this cdra thingy will be loaded
After seting country=DE in /etc/wpa_supplicant/wpa_supplicant.conf and restarting wpa_supplicant.service as well after installing wireless-regdb and reloading the modules brcmfmac and cfg80211 still no WLAN 2.4GHz channels above 11
Where are the tools regdbdump and crda mentioned in the manual page regulatory.bin(5) ... also missing the udev rule for cdra
(In reply to Dr. Werner Fink from comment #4) > Where are the tools regdbdump and crda mentioned in the manual page > regulatory.bin(5) ... also missing the udev rule for cdra Do you know more about this?
This is what I see smartmeter:~ # iw phy | grep MHz * 2412 MHz [1] (20.0 dBm) * 2417 MHz [2] (20.0 dBm) * 2422 MHz [3] (20.0 dBm) * 2427 MHz [4] (20.0 dBm) * 2432 MHz [5] (20.0 dBm) * 2437 MHz [6] (20.0 dBm) * 2442 MHz [7] (20.0 dBm) * 2447 MHz [8] (20.0 dBm) * 2452 MHz [9] (20.0 dBm) * 2457 MHz [10] (20.0 dBm) * 2462 MHz [11] (20.0 dBm) * 2467 MHz [12] (disabled) * 2472 MHz [13] (disabled) * 2484 MHz [14] (disabled) how can I *enable* channel 12 and 13
AFAIK linux is handling these stuff with https://wireless.wiki.kernel.org/en/developers/regulatory/wireless-regdb That mean, if you set your COUNTRY settings, channels get enabled or disabled, corresponding to your location. There are also manufactures which burn these things into the firmware. Not sure if it is then possible to bypass these (or legal).
Wikipedia has a nice overview https://en.wikipedia.org/wiki/List_of_WLAN_channels
Package wpa_supplicant misses dependency to system-group-wheel as group wheel is used in "/etc/wpa_supplicant/wpa_supplicant.conf" .. ctrl_interface=/var/run/wpa_supplicant ctrl_interface_group=wheel
(In reply to Clemens Famulla-Conrad from comment #7) > AFAIK linux is handling these stuff with > https://wireless.wiki.kernel.org/en/developers/regulatory/wireless-regdb > > That mean, if you set your COUNTRY settings, channels get enabled or > disabled, corresponding to your location. > > There are also manufactures which burn these things into the firmware. Not > sure if it is then possible to bypass these (or legal). Accordingly to the german forum page https://forum-raspberrypi.de/forum/thread/34332-rpi3-trotz-kernel-4-4-50-kein-wlan-kanal-12-13/ it is possible ... but the tools to do so are missed (crda via udev rule)
It seems that the crda is indeed handled novercal https://build.opensuse.org/package/show/devel%3AARM%3AFactory%3AContrib%3AILP32/crda what is wrong with this package which is *mandatory* for usage of WiFi in several countries including USA, Japan and Germany?
Now I've build crda for aarch64 ... and modify the rule that is added a ENV{COUNTRY}="DE", before RUN+="/usr/sbin/crda" but the rule isn#t done at any time and calling the crda on the command line leads to smartmeter:~ # COUNTRY=DE /usr/sbin/crda Failed to set regulatory domain: -7 can anyone explain how to get the physical available WLAN channel working? My fritrbox is using autochannel and is at channel 13 (and I guess that there is a reason for that due WLAN neighbourhood ... in past changing this had lead to trouble). smartmeter:~ # iw phy | grep MHz * 2412 MHz [1] (20.0 dBm) * 2417 MHz [2] (20.0 dBm) * 2422 MHz [3] (20.0 dBm) * 2427 MHz [4] (20.0 dBm) * 2432 MHz [5] (20.0 dBm) * 2437 MHz [6] (20.0 dBm) * 2442 MHz [7] (20.0 dBm) * 2447 MHz [8] (20.0 dBm) * 2452 MHz [9] (20.0 dBm) * 2457 MHz [10] (20.0 dBm) * 2462 MHz [11] (20.0 dBm) * 2467 MHz [12] (disabled) * 2472 MHz [13] (disabled) * 2484 MHz [14] (disabled) smartmeter:~ # iwlist wlan0 channel wlan0 11 channels in total; available frequencies : Channel 01 : 2.412 GHz Channel 02 : 2.417 GHz Channel 03 : 2.422 GHz Channel 04 : 2.427 GHz Channel 05 : 2.432 GHz Channel 06 : 2.437 GHz Channel 07 : 2.442 GHz Channel 08 : 2.447 GHz Channel 09 : 2.452 GHz Channel 10 : 2.457 GHz Channel 11 : 2.462 GHz smartmeter:~ # iw reg get global country DE: DFS-ETSI (2400 - 2483 @ 40), (N/A, 20), (N/A) (5150 - 5250 @ 80), (N/A, 23), (N/A), NO-OUTDOOR, AUTO-BW (5250 - 5350 @ 80), (N/A, 20), (0 ms), NO-OUTDOOR, DFS, AUTO-BW (5470 - 5725 @ 160), (N/A, 26), (0 ms), DFS (5725 - 5875 @ 80), (N/A, 13), (N/A) (57000 - 66000 @ 2160), (N/A, 40), (N/A)
Even with udev Nov 27 12:45:40 smartmeter systemd-udevd[3016]: '/usr/sbin/crda'(err) 'Failed to set regulatory domain: -7' what does go wrong here?
Hmmm ... now th crda seems to work after setting a wromg value and resetting DE with `iw reg set´ smartmeter:~ # iwlist wlan0 channel wlan0 13 channels in total; available frequencies : Channel 01 : 2.412 GHz Channel 02 : 2.417 GHz Channel 03 : 2.422 GHz Channel 04 : 2.427 GHz Channel 05 : 2.432 GHz Channel 06 : 2.437 GHz Channel 07 : 2.442 GHz Channel 08 : 2.447 GHz Channel 09 : 2.452 GHz Channel 10 : 2.457 GHz Channel 11 : 2.462 GHz Channel 12 : 2.467 GHz Channel 13 : 2.472 GHz smartmeter:~ # iw phy | grep MHz * 2412 MHz [1] (20.0 dBm) * 2417 MHz [2] (20.0 dBm) * 2422 MHz [3] (20.0 dBm) * 2427 MHz [4] (20.0 dBm) * 2432 MHz [5] (20.0 dBm) * 2437 MHz [6] (20.0 dBm) * 2442 MHz [7] (20.0 dBm) * 2447 MHz [8] (20.0 dBm) * 2452 MHz [9] (20.0 dBm) * 2457 MHz [10] (20.0 dBm) * 2462 MHz [11] (20.0 dBm) * 2467 MHz [12] (20.0 dBm) * 2472 MHz [13] (20.0 dBm) * 2484 MHz [14] (disabled) ... nevertheless with `nmcli dev wifi list´ my fritzbox with its SSID does not occur
Not sure if it helps, but maybe use iw tools directly like > iw dev wlan0 scan trigger freq 2472 > iw dev wlan0 scan dump
(In reply to Clemens Famulla-Conrad from comment #15) > Not sure if it helps, but maybe use iw tools directly like > > iw dev wlan0 scan trigger freq 2472 > > iw dev wlan0 scan dump smartmeter:~ # iw dev wlan0 scan trigger freq 2472 smartmeter:~ # iw dev wlan0 scan dump | grep -E 'SSID:|primary channel:' SSID: Claudia und Manuel * primary channel: 1 SSID: naduah * primary channel: 1 SSID: DOMINION * primary channel: 1 SSID: DIRECT-E1-HP OfficeJet Pro 8720 * primary channel: 4 SSID: Mazsola * primary channel: 4 SSID: HP-Setup>ee-M277 LaserJet * primary channel: 6 SSID: DIRECT-25-HP OfficeJet Pro 8710 * primary channel: 6 SSID: ZYXEL-098 * primary channel: 6 SSID: Art * primary channel: 6 SSID: Obi.net * primary channel: 9 SSID: * primary channel: 9 SSID: FRITZ!Box 7590 UV * primary channel: 11 nope, that does not work either ...
this could be a problem with the firmware and/or kernel driver modul: [ 36.903630] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac43430-sdio for chip BCM43430/1 [ 36.903797] brcmfmac: brcmf_c_process_clm_blob: no clm_blob available (err=-2), device may have limited channels available [ 36.904454] brcmfmac: brcmf_c_preinit_dcmds: Firmware: BCM43430/1 wl0: Oct 23 2017 03:55:53 version 7.45.98.38 (r674442 CY) FWID 01-e58d219f ... ``device may have limited channels available´´ Inersting the cfg80211 module also works in x86 without using crda lsmod | grep cfg80211 cfg80211 827392 3 iwlmvm,iwlwifi,mac80211 rfkill 28672 7 bluetooth,cfg80211 and nevertheless the iwlwifi does know about chanel 12 and 13 for DE and disable only channel 14. iw reg get global country 00: DFS-UNSET (2402 - 2472 @ 40), (N/A, 20), (N/A) (2457 - 2482 @ 20), (N/A, 20), (N/A), AUTO-BW, PASSIVE-SCAN (2474 - 2494 @ 20), (N/A, 20), (N/A), NO-OFDM, PASSIVE-SCAN (5170 - 5250 @ 80), (N/A, 20), (N/A), AUTO-BW, PASSIVE-SCAN (5250 - 5330 @ 80), (N/A, 20), (0 ms), DFS, AUTO-BW, PASSIVE-SCAN (5490 - 5730 @ 160), (N/A, 20), (0 ms), DFS, PASSIVE-SCAN (5735 - 5835 @ 80), (N/A, 20), (N/A), PASSIVE-SCAN (57240 - 63720 @ 2160), (N/A, 0), (N/A) phy#0 (self-managed) country DE: DFS-UNSET (2402 - 2437 @ 40), (6, 22), (N/A), AUTO-BW, NO-HT40MINUS, NO-80MHZ, NO-160MHZ (2422 - 2462 @ 40), (6, 22), (N/A), AUTO-BW, NO-80MHZ, NO-160MHZ (2447 - 2482 @ 40), (6, 22), (N/A), AUTO-BW, NO-HT40PLUS, NO-80MHZ, NO-160MHZ [....] how does this *self-managed* work?`
Beside missing major tools like wireless-regdb and crda where I've now build the later one for Leap 15.2 on aarch64 for my own this seems to be a kernel issue: https://github.com/raspberrypi/linux/issues/1355 Therefore I´ll clone this bug for the kernel people
It looks like the package crda is also useful on other architectures than only arm based. This because many WLAN USB dongle uses drivers from Broadcom. This would also explain why many users outside the USA reports WLAN connection loose ... which IMHO are explained by not supported WLAN channels above channel 11
Created attachment 843976 [details] crda-default.patch This one implements the (/usr)/etc/default/crda setup for crds(8)
Created attachment 843977 [details] /usr/etc/default/crda This is my suggestion for the configuration file below /usr/etc/default/ For more see home:WernerFink:aarch64/crda I´ll to submit this to the original devel:ARM:Factory:Contrib:ILP32/crda but IMHO this should be moved to openSUSE:Factory or better to one of the hardware reporitory to support also WLAN USB dongles on other platforms as well
Could the package devel:ARM:Factory:Contrib:ILP32 crda a linkes package *without* hard set revision to hardware crda to get the latest crda
Hi Werner, I guess you added me to the bug because I am one of the last people to touch the package. To be honest, I do not even remember why I did that back in 2015, but from the changelog entry (updating the version, adding a new pubkey) I guess it was a "it is totally broken and I'll just fix it up" event :-) I have maintainer rights in the hardware repository and thus I can accept your submitrequest. I could also make you the maintainer if you wish so ;-)
(In reply to Stefan Seyfried from comment #23) > Hi Werner, > I guess you added me to the bug because I am one of the last people to touch > the package. > To be honest, I do not even remember why I did that back in 2015, but from > the changelog entry (updating the version, adding a new pubkey) I guess it > was a "it is totally broken and I'll just fix it up" event :-) > > I have maintainer rights in the hardware repository and thus I can accept > your submitrequest. > I could also make you the maintainer if you wish so ;-) Thanks, that would be nice indeed! Actual it looks like that the current broadcom driver(s) do not know about the last changes in the REDME of crda +purpose: tell Linux kernel what regulatory ruels to enforce for 802.11. + +CRDA is no longer needed as of kernel v4.15 since commit 007f6c5e6eb45 +("cfg80211: support loading regulatory database as firmware file") added +support to use the kernel's firmware request API which looks for the +firmware on /lib/firmware. Because of this CRDA is legacy software for +older kernels. It will continue to be maintained. + +CRDA is a udev helper for communication between the kernel and userspace. You +only need to run this manually for debugging purposes. For manual changing of +regulatory domains use iw (iw reg set) or wpa_supplicant.
Accepted the SR and made you maintainer of the package. As I cannot judge the technical parts of your submission at all, I did not yet auto-forward to factory. Have fun :-)
This is an autogenerated message for OBS integration: This bug (1179308) was mentioned in https://build.opensuse.org/request/show/852376 Factory / crda
setting assignee to werner as new maintainer of crda
SR #852376 is accepted