svn commit: r226694 - user/adrian/if_ath_tx/sys/dev/ath

Adrian Chadd adrian at FreeBSD.org
Mon Oct 24 15:50:23 UTC 2011


Author: adrian
Date: Mon Oct 24 15:50:23 2011
New Revision: 226694
URL: http://svn.freebsd.org/changeset/base/226694

Log:
  Stick the imask update behind ATH_LOCK, so it's done atomically.
  
  The rest of ath_hal_intrset() calls aren't done behind locks though,
  neither are the imask updates/fetches. That'll come in a later
  commit.

Modified:
  user/adrian/if_ath_tx/sys/dev/ath/if_ath.c

Modified: user/adrian/if_ath_tx/sys/dev/ath/if_ath.c
==============================================================================
--- user/adrian/if_ath_tx/sys/dev/ath/if_ath.c	Mon Oct 24 14:50:56 2011	(r226693)
+++ user/adrian/if_ath_tx/sys/dev/ath/if_ath.c	Mon Oct 24 15:50:23 2011	(r226694)
@@ -1425,7 +1425,7 @@ ath_intr(void *arg)
 			}
 		}
 		if (status & HAL_INT_RXEOL) {
-			int imask = sc->sc_imask;
+			int imask;
 			CTR0(ATH_KTR_ERR, "ath_intr: RXEOL");
 			/*
 			 * NB: the hardware should re-read the link when
@@ -1443,6 +1443,7 @@ ath_intr(void *arg)
 			 * interrupt mask will be correctly reprogrammed.
 			 */
 			ATH_LOCK(sc);
+			imask = sc->sc_imask;
 			imask &= ~(HAL_INT_RXEOL | HAL_INT_RXORN);
 			ath_hal_intrset(ah, imask);
 			/*


More information about the svn-src-user mailing list