[Bug 242337] iwm - rate 0 causes iwm panic (and work around)
Adrian Chadd
adrian.chadd at gmail.com
Sun Dec 1 18:03:25 UTC 2019
Hi!
Wait, someone's calling iwn_rate2ridx() with rate=0 ? That's highly
bogus and yes will lead to a firmware panic.
what's the caller? How's it being called with rate=0 ? It sounds like
something in the rate negotiation is failing...
-adrian
On Sun, 1 Dec 2019 at 05:24, <bugzilla-noreply at freebsd.org> wrote:
>
> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=242337
>
> --- Comment #2 from dirkx at webweaving.org ---
> As a workaround - in if_iwm.c -- simply picking the first rate from the table
> (the slowest) makes things work again although it emits below error:
>
>
> iwm0: frame 0/230 b800002c UNHANDLED (this should not happen)
> tun0: link state changed to UP
>
> Function changed below.
>
> static int
> iwm_rate2ridx(struct iwm_softc *sc, uint8_t rate)
> {
> int i;
>
> for (i = 0; i <= IWM_RIDX_MAX; i++) {
> if (iwm_rates[i].rate == rate)
> return i;
> }
>
> device_printf(sc->sc_dev,
> "%s: WARNING: device rate for %u not found!!\n",
> __func__, rate);
>
> // On KPN Experia ADSL modems - one somehow gets a rate==0;
> // just picking the first value from the table works.
> if (rate == 0) {
> device_printf(sc->sc_dev,
> "%s: WARNING: using first rate fom the table.\n",
> __func__);
> return 0;
> };
> return -1;
> }
>
> --
> You are receiving this mail because:
> You are the assignee for the bug.
> _______________________________________________
> freebsd-wireless at freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
> To unsubscribe, send any mail to "freebsd-wireless-unsubscribe at freebsd.org"
More information about the freebsd-wireless
mailing list