You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
823 B
Diff
28 lines
823 B
Diff
From: Oleksij Rempel <linux@rempel-privat.de>
|
|
Date: Sun, 22 Mar 2015 19:29:59 +0100
|
|
Subject: [PATCH] ath9k: ath9k_hw_analog_shift_rmw: use REG_RMW
|
|
|
|
use REG_RMW in ath9k_hw_analog_shift_rmw.
|
|
It will double execution speed on usb bus.
|
|
|
|
Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
|
|
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
|
|
---
|
|
|
|
--- a/drivers/net/wireless/ath/ath9k/eeprom.c
|
|
+++ b/drivers/net/wireless/ath/ath9k/eeprom.c
|
|
@@ -27,12 +27,7 @@ void ath9k_hw_analog_shift_regwrite(stru
|
|
void ath9k_hw_analog_shift_rmw(struct ath_hw *ah, u32 reg, u32 mask,
|
|
u32 shift, u32 val)
|
|
{
|
|
- u32 regVal;
|
|
-
|
|
- regVal = REG_READ(ah, reg) & ~mask;
|
|
- regVal |= (val << shift) & mask;
|
|
-
|
|
- REG_WRITE(ah, reg, regVal);
|
|
+ REG_RMW(ah, reg, ((val << shift) & mask), mask);
|
|
|
|
if (ah->config.analog_shiftreg)
|
|
udelay(100);
|