Date: Thu, 3 Nov 2011 02:48:15 +0000 (UTC) From: Adrian Chadd <adrian@FreeBSD.org> To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r227046 - user/adrian/if_ath_tx/sys/dev/ath/ath_hal/ar5416 Message-ID: <201111030248.pA32mFp1049343@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: adrian Date: Thu Nov 3 02:48:15 2011 New Revision: 227046 URL: http://svn.freebsd.org/changeset/base/227046 Log: Fix the ANI parameter count logic to properly explore all of the states. Since the values are "max", not "Number of items", using >= means that the last entry in each state would never be checked. Modified: user/adrian/if_ath_tx/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c Modified: user/adrian/if_ath_tx/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c ============================================================================== --- user/adrian/if_ath_tx/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c Thu Nov 3 02:38:32 2011 (r227045) +++ user/adrian/if_ath_tx/sys/dev/ath/ath_hal/ar5416/ar5416_ani.c Thu Nov 3 02:48:15 2011 (r227046) @@ -227,7 +227,7 @@ ar5416AniControl(struct ath_hal *ah, HAL u_int level = param; HALDEBUG(ah, HAL_DEBUG_ANI, "%s: HAL_ANI_NOISE_IMMUNITY_LEVEL: set level = %d\n", __func__, level); - if (level >= params->maxNoiseImmunityLevel) { + if (level > params->maxNoiseImmunityLevel) { HALDEBUG(ah, HAL_DEBUG_ANI, "%s: immunity level out of range (%u > %u)\n", __func__, level, params->maxNoiseImmunityLevel); @@ -314,7 +314,7 @@ ar5416AniControl(struct ath_hal *ah, HAL u_int level = param; HALDEBUG(ah, HAL_DEBUG_ANI, "%s: HAL_ANI_FIRSTEP_LEVEL: level = %d\n", __func__, level); - if (level >= params->maxFirstepLevel) { + if (level > params->maxFirstepLevel) { HALDEBUG(ah, HAL_DEBUG_ANI, "%s: firstep level out of range (%u > %u)\n", __func__, level, params->maxFirstepLevel); @@ -333,7 +333,7 @@ ar5416AniControl(struct ath_hal *ah, HAL u_int level = param; HALDEBUG(ah, HAL_DEBUG_ANI, "%s: HAL_ANI_SPUR_IMMUNITY_LEVEL: level = %d\n", __func__, level); - if (level >= params->maxSpurImmunityLevel) { + if (level > params->maxSpurImmunityLevel) { HALDEBUG(ah, HAL_DEBUG_ANI, "%s: spur immunity level out of range (%u > %u)\n", __func__, level, params->maxSpurImmunityLevel);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201111030248.pA32mFp1049343>