svn commit: r213734 - stable/7/sys/dev/iwi
Bernhard Schmidt
bschmidt at FreeBSD.org
Tue Oct 12 17:12:35 UTC 2010
Author: bschmidt
Date: Tue Oct 12 17:12:35 2010
New Revision: 213734
URL: http://svn.freebsd.org/changeset/base/213734
Log:
When bringing the interface down we clear the command queue but do
not reset the sc_cmd_cur and sc_cmd_next indices. If there are
still pending commands while clearing the queue those two indices
are off by at least one. This leads to no commands being sent
to the firmware until the queue overruns. Fix this by also resetting
the indices.
This is a direct commit as the code does not exist in head.
Modified:
stable/7/sys/dev/iwi/if_iwi.c
Modified: stable/7/sys/dev/iwi/if_iwi.c
==============================================================================
--- stable/7/sys/dev/iwi/if_iwi.c Tue Oct 12 17:12:22 2010 (r213733)
+++ stable/7/sys/dev/iwi/if_iwi.c Tue Oct 12 17:12:35 2010 (r213734)
@@ -3267,6 +3267,7 @@ iwi_stop(void *priv)
ifp->if_drv_flags &= ~(IFF_DRV_RUNNING | IFF_DRV_OACTIVE);
memset(sc->sc_cmd, 0, sizeof(sc->sc_cmd));
+ sc->sc_cmd_cur = sc->sc_cmd_next = 0;
sc->sc_tx_timer = 0;
sc->sc_rfkill_timer = 0;
sc->sc_state_timer = 0;
More information about the svn-src-stable-7
mailing list