Re: Kernel panic in ieee80211_chan2mode <- SIOCS80211 ioctl

From: Bjoern A. Zeeb <bz_at_FreeBSD.org>
Date: Thu, 10 Sep 2026 10:12:33 UTC
On Thu, 10 Sep 2026, Marcin Cieslak wrote:

> On Wed, 9 Sep 2026, Bjoern A. Zeeb wrote:
>
>> On Wed, 9 Sep 2026, Marcin Cieslak wrote:
>> 
>>> On Wed, 9 Sep 2026, Bjoern A. Zeeb wrote:
>>> 
>
> (quick answers)
>
>> Now the question is:  what's your VAIO kernel?  GENERIC or NODEBUG?
>
> Roughly based on GENERIC + additional debug. I should probably include 
> GENERIC at some point. (Diff to GENERIC attached)
>
> (...)
>
>> That leads me to the question: what does your AP send you?
>> Can you capture a beacon frame (on a different machine)?
>
> I can do it on a Linux laptop (how?)

Here's a description on how to get into monitor mode on Linux:
https://sandilands.info/sgordon/capturing-wifi-in-monitor-mode-with-iw

You can then use
 	tcpdump -I wlan0 -y IEEE802_11_RADIO -s0 -w /tmp/forbz.pcap

You could limit that to type mgt subtype beacon but given you say it's
happening at assoc, that I am not sure about (you may mean something
different than I with that).  As on ASSOC RESPONSE you get rates as well
from the AP but looking at your backtrace it doesn't seem you made it
that far.


> Besides, if I kill devd and do not launch anything else
> I can "ifconfig wlan0 scan" and get the results without
> crashing. Is ther any way I get the scan structures out easily on that 
> machine (dtrace maybe) - it crashes only
> if I try to associate.

actually happens if you try to authenticate I beleive but that's wifi
state machine...

I am not sure if ifconfig shows the unfiltered raw bits (sorry cannot look
it up currently):

ifconfig -v wlan0 list scan

Note the -v which is important.




>> Speaking of that, what machine did you say do you have with a brmcfmac in 
>> it?
>
> Apple MacBookPro13,1 without touch bar (no T1 chip).
> One of the last Intel ones.
>
>> The reason I replied to the AI driver was that I was seeing the chance of 
>> net80211
>> improvements (even if the real problem may sit elsehwere).  And net80211 
>> tech debt
>> is on my agenda.
>
> I was using wifibox before and also tried to build your
> driver.

There is no "my driver".  It's the Linux brcmfmac driver which I imported
but we are still lacking the cfg80211 LinuxKPI glue.


> Thank you for the effort, will dig more in few hours

-- 
For there shall arise false Christs, and false prophets, and shall shew
great signs and wonders; insomuch that, if it were possible, they shall
deceive the very elect. Behold, I have told you before. [Mat. 24:24-25]