> Date: Mon, 8 Jun 2015 09:03:47 +0200
> From: Stefan Sperling
>
> The iwm(4) watchdog does two things wrong:
>
> - It doesn't trigger iwm_init_task so the task remains entirely unused.
>
> - It clears the IFF_UP interface flag. Only the intel wifi drivers do this,
>and I think it's wrong. Other wifi drivers don't clear it. The watchdog
>should attempt to get the hardware going again with minimal disruption.
>
> Can iwm(4) users test this, please? Especially if you occasionally see a
> message saying 'iwm0: device timeout' this change will affect you.
Seems reasonable to me. ok kettenis@
> Index: if_iwm.c
> ===
> RCS file: /cvs/src/sys/dev/pci/if_iwm.c,v
> retrieving revision 1.42
> diff -u -p -r1.42 if_iwm.c
> --- if_iwm.c 30 May 2015 02:49:23 - 1.42
> +++ if_iwm.c 8 Jun 2015 06:56:31 -
> @@ -5720,8 +5720,7 @@ iwm_watchdog(struct ifnet *ifp)
> #ifdef IWM_DEBUG
> iwm_nic_error(sc);
> #endif
> - ifp->if_flags &= ~IFF_UP;
> - iwm_stop(ifp, 1);
> + task_add(systq, &sc->init_task);
> ifp->if_oerrors++;
> return;
> }
>
>