svn commit: r250841 - head/sys/dev/ath/ath_hal/ar5416
Adrian Chadd
adrian at FreeBSD.org
Tue May 21 05:51:49 UTC 2013
Author: adrian
Date: Tue May 21 05:51:49 2013
New Revision: 250841
URL: http://svnweb.freebsd.org/changeset/base/250841
Log:
Extend the TXOP enforce capability to support checking whether it's
supported.
Modified:
head/sys/dev/ath/ath_hal/ar5416/ar5416_misc.c
Modified: head/sys/dev/ath/ath_hal/ar5416/ar5416_misc.c
==============================================================================
--- head/sys/dev/ath/ath_hal/ar5416/ar5416_misc.c Tue May 21 03:05:49 2013 (r250840)
+++ head/sys/dev/ath/ath_hal/ar5416/ar5416_misc.c Tue May 21 05:51:49 2013 (r250841)
@@ -466,6 +466,10 @@ ar5416GetCapability(struct ath_hal *ah,
case HAL_CAP_DIVERSITY: /* disable classic fast diversity */
return HAL_ENXIO;
case HAL_CAP_ENFORCE_TXOP:
+ if (capability == 0)
+ return (HAL_OK);
+ if (capability != 1)
+ return (HAL_ENOTSUPP);
(*result) =
!! (AH5212(ah)->ah_miscMode & AR_PCU_TXOP_TBTT_LIMIT_ENA);
return (HAL_OK);
@@ -499,6 +503,8 @@ ar5416SetCapability(struct ath_hal *ah,
pCap->halTxStreams = 1;
return AH_TRUE;
case HAL_CAP_ENFORCE_TXOP:
+ if (capability != 1)
+ return (HAL_ENOTSUPP);
if (setting) {
AH5212(ah)->ah_miscMode
|= AR_PCU_TXOP_TBTT_LIMIT_ENA;
More information about the svn-src-all
mailing list