[Bug 263613] iwlwifi0 on framework laptop crashes when setting IP

From: <bugzilla-noreply_at_freebsd.org>
Date: Wed, 27 Apr 2022 18:24:58 UTC

            Bug ID: 263613
           Summary: iwlwifi0 on framework laptop crashes when setting IP
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: wireless
          Assignee: wireless@FreeBSD.org
          Reporter: jon@xyinn.org

Created attachment 233540
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=233540&action=edit

Hey all,

I've spent a few days reading _a lot_ of documentation and experimenting with
getting FreeBSD running on my Framework Laptop on 13.0-RELEASE, 13.1-RC4, and
14-CURRENT (just to see how far all of the branches are working on it -
although originally I wanted to just run 13.1 since that's the next RELEASE but
I was getting too many issues and crashes with it.. and I've been avoiding
jumping into STABLE/CURRENT, but c'est la vie haha). I've definitely noticed a
bunch of issues that either already got fixed, or still remain (but I've yet
gathered exact repro scenarios). However, for this particular issue (and I'm
not sure if it's 100% related but I think it might be), the Intel AX210 card on
the framework laptop seems to associate with my AP properly, but no DHCPOFFERS
are received. I think there was only one time a few days ago on an older build
of CURRENT that I was able to get it to get an IP, but I haven't been able to
replicate that working state.

Also, this is on the sources for 14-CURRENT (for both world and kernel) as of
today 2022-04-27. I'm motivated to help any of the devs test any code needed to
get, not only this issue, but really anything regarding the framework laptop as
an actual desktop productivity machine. I'm not a FreeBSD pro, but have been
using it on my home server for the past 2~ years. So apologies if there any
particular concepts or things I don't yet know, feel free to point me in the
right direction though :).

I've attached various parts of my system config and dmesg output to help debug

I've noticed that I sometimes get the following errors as well (I've also
looked at what the Linux community said about those errors and it seems they
were fixed in 5.13):

iwlwifi0: iwl_trans_send_cmd bad_state = 0
iwlwifi0: Failed to remove MAC context: -5

repro commands:

Given the above situation where the system started up the wlan0 interfaced
(parent: iwlwifi0) and was associated to the AP but did not receive any DHCP

1. ifconfig wlan0 down
2. ifconfig wlan0 netmask

> The command will trigger, and a few seconds later it will hard crash. I've attached a camera shot of this. But something relevant may be the following:

iwlwifi0: Failed to send binding (action:1): -5
iwlwifi0: PHY ctxt cmd error. ret=-5
iwlwifi0: lkpi_iv_newstate: error -5 during state transition 1 (SCAN) -> 2
iwlwifi0: No queue was found. Dropping TX
iwlwifi0: Failed to trigger RX queues sync (-5)


panic: lkpi_sta_auth_to_scan: lsta 0xfffff8012f0c5800 state not NONE: 0, nstate
1 arg 1


Overall, this laptop seems to have slowly gotten better support so that's
definitely encouraging and I also read the recent news about FreeBSD and the
work going on to improve Framework Laptop support. The wifi issues caused hard
reboots on 13.1-RC4 current (It would just shut off, I believe the "firmware
dying in a fire" that Kyle Evans mentioned here:
might have been what he meant by that). This may or may not be the same bug
that I'm experiencing here, but maybe since I'm running -CURRENT now with the
default debug configuration, "hard crash reboots" turn into "hard crash - do
not reboot" situations? 

Anyways, let me know if anything and I can further help debug.

You are receiving this mail because:
You are the assignee for the bug.