Also set the AR5212 HAL power mode tracking in the right spot.

Tested:

* D-Link DWL-G650 NIC (AR2413), STA mode
This commit is contained in:
Adrian Chadd 2014-03-22 03:36:07 +00:00
parent f804336026
commit f857fb4fa3
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=263618

View File

@ -134,20 +134,22 @@ ar5212SetPowerMode(struct ath_hal *ah, HAL_POWER_MODE mode, int setChip)
setChip ? "set chip " : "");
switch (mode) {
case HAL_PM_AWAKE:
ah->ah_powerMode = mode;
status = ar5212SetPowerModeAwake(ah, setChip);
break;
case HAL_PM_FULL_SLEEP:
ar5212SetPowerModeSleep(ah, setChip);
ah->ah_powerMode = mode;
break;
case HAL_PM_NETWORK_SLEEP:
ar5212SetPowerModeNetworkSleep(ah, setChip);
ah->ah_powerMode = mode;
break;
default:
HALDEBUG(ah, HAL_DEBUG_ANY, "%s: unknown power mode %u\n",
__func__, mode);
return AH_FALSE;
}
ah->ah_powerMode = mode;
return status;
}