diff options
author | Oleksij Rempel <linux@rempel-privat.de> | 2015-03-22 14:30:02 -0400 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2015-03-30 04:31:40 -0400 |
commit | b1c1a26461a79a289e08d0c04bf8520e305bf05d (patch) | |
tree | 6bef736ab352198d0ebeffedccbf73529e66df55 /drivers/net/wireless/ath/ath9k | |
parent | 2dfc0247f0ff755296ab72ab3ddb8309fb35c660 (diff) |
ath9k: use REG_RMW and rmw buffer in ath9k_hw_4k_set_board_values
replace REG_WRITE to REG_RMW and place every thing in one
RMW buffer.
Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/eeprom_4k.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/drivers/net/wireless/ath/ath9k/eeprom_4k.c b/drivers/net/wireless/ath/ath9k/eeprom_4k.c index 38dc965605d8..4773da6dc6f2 100644 --- a/drivers/net/wireless/ath/ath9k/eeprom_4k.c +++ b/drivers/net/wireless/ath/ath9k/eeprom_4k.c | |||
@@ -1037,17 +1037,17 @@ static void ath9k_hw_4k_set_board_values(struct ath_hw *ah, | |||
1037 | } | 1037 | } |
1038 | REG_RMW_BUFFER_FLUSH(ah); | 1038 | REG_RMW_BUFFER_FLUSH(ah); |
1039 | 1039 | ||
1040 | 1040 | ENABLE_REG_RMW_BUFFER(ah); | |
1041 | REG_RMW_FIELD(ah, AR_PHY_SETTLING, AR_PHY_SETTLING_SWITCH, | 1041 | REG_RMW_FIELD(ah, AR_PHY_SETTLING, AR_PHY_SETTLING_SWITCH, |
1042 | pModal->switchSettling); | 1042 | pModal->switchSettling); |
1043 | REG_RMW_FIELD(ah, AR_PHY_DESIRED_SZ, AR_PHY_DESIRED_SZ_ADC, | 1043 | REG_RMW_FIELD(ah, AR_PHY_DESIRED_SZ, AR_PHY_DESIRED_SZ_ADC, |
1044 | pModal->adcDesiredSize); | 1044 | pModal->adcDesiredSize); |
1045 | 1045 | ||
1046 | REG_WRITE(ah, AR_PHY_RF_CTL4, | 1046 | REG_RMW(ah, AR_PHY_RF_CTL4, |
1047 | SM(pModal->txEndToXpaOff, AR_PHY_RF_CTL4_TX_END_XPAA_OFF) | | 1047 | SM(pModal->txEndToXpaOff, AR_PHY_RF_CTL4_TX_END_XPAA_OFF) | |
1048 | SM(pModal->txEndToXpaOff, AR_PHY_RF_CTL4_TX_END_XPAB_OFF) | | 1048 | SM(pModal->txEndToXpaOff, AR_PHY_RF_CTL4_TX_END_XPAB_OFF) | |
1049 | SM(pModal->txFrameToXpaOn, AR_PHY_RF_CTL4_FRAME_XPAA_ON) | | 1049 | SM(pModal->txFrameToXpaOn, AR_PHY_RF_CTL4_FRAME_XPAA_ON) | |
1050 | SM(pModal->txFrameToXpaOn, AR_PHY_RF_CTL4_FRAME_XPAB_ON)); | 1050 | SM(pModal->txFrameToXpaOn, AR_PHY_RF_CTL4_FRAME_XPAB_ON), 0); |
1051 | 1051 | ||
1052 | REG_RMW_FIELD(ah, AR_PHY_RF_CTL3, AR_PHY_TX_END_TO_A2_RX_ON, | 1052 | REG_RMW_FIELD(ah, AR_PHY_RF_CTL3, AR_PHY_TX_END_TO_A2_RX_ON, |
1053 | pModal->txEndToRxOn); | 1053 | pModal->txEndToRxOn); |
@@ -1076,6 +1076,8 @@ static void ath9k_hw_4k_set_board_values(struct ath_hw *ah, | |||
1076 | pModal->swSettleHt40); | 1076 | pModal->swSettleHt40); |
1077 | } | 1077 | } |
1078 | 1078 | ||
1079 | REG_RMW_BUFFER_FLUSH(ah); | ||
1080 | |||
1079 | bb_desired_scale = (pModal->bb_scale_smrt_antenna & | 1081 | bb_desired_scale = (pModal->bb_scale_smrt_antenna & |
1080 | EEP_4K_BB_DESIRED_SCALE_MASK); | 1082 | EEP_4K_BB_DESIRED_SCALE_MASK); |
1081 | if ((pBase->txGainType == 0) && (bb_desired_scale != 0)) { | 1083 | if ((pBase->txGainType == 0) && (bb_desired_scale != 0)) { |