svn commit: r211299 - head/sys/dev/ath

Adrian Chadd adrian at FreeBSD.org
Sat Aug 14 14:01:12 UTC 2010


Author: adrian
Date: Sat Aug 14 14:01:12 2010
New Revision: 211299
URL: http://svn.freebsd.org/changeset/base/211299

Log:
  Add a global counter of missed beacons.
  
  The existing missed beacon count is reset once a beacon isn't missed.

Modified:
  head/sys/dev/ath/if_ath.c
  head/sys/dev/ath/if_athioctl.h

Modified: head/sys/dev/ath/if_ath.c
==============================================================================
--- head/sys/dev/ath/if_ath.c	Sat Aug 14 13:51:38 2010	(r211298)
+++ head/sys/dev/ath/if_ath.c	Sat Aug 14 14:01:12 2010	(r211299)
@@ -2824,6 +2824,7 @@ ath_beacon_proc(void *arg, int pending)
 	 */
 	if (ath_hal_numtxpending(ah, sc->sc_bhalq) != 0) {
 		sc->sc_bmisscount++;
+		sc->sc_stats.ast_be_missed++;
 		DPRINTF(sc, ATH_DEBUG_BEACON,
 			"%s: missed %u consecutive beacons\n",
 			__func__, sc->sc_bmisscount);

Modified: head/sys/dev/ath/if_athioctl.h
==============================================================================
--- head/sys/dev/ath/if_athioctl.h	Sat Aug 14 13:51:38 2010	(r211298)
+++ head/sys/dev/ath/if_athioctl.h	Sat Aug 14 14:01:12 2010	(r211299)
@@ -118,7 +118,8 @@ struct ath_stats {
 	u_int32_t	ast_tdma_ack;	/* TDMA tx failed 'cuz ACK required */
 	u_int32_t	ast_tx_raw_fail;/* raw tx failed 'cuz h/w down */
 	u_int32_t	ast_tx_nofrag;	/* tx dropped 'cuz no ath frag buffer */
-	u_int32_t	ast_pad[14];
+	u_int32_t	ast_be_missed;	/* missed beacons */
+	u_int32_t	ast_pad[13];
 };
 
 #define	SIOCGATHSTATS	_IOWR('i', 137, struct ifreq)


More information about the svn-src-all mailing list