summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2014-10-29 00:18:58 +0300
committerJohn W. Linville <linville@tuxdriver.com>2014-10-30 22:26:52 +0300
commit7a1283d8f5298437a454ec477384dcd9f9f88bac (patch)
tree1a0dd00ece0e81c4526540648b535dd8b18a919c /drivers
parent9a06bec9aee0ae54f175b20a8d4f5e14aef24a9f (diff)
downloadlinux-7a1283d8f5298437a454ec477384dcd9f9f88bac.tar.xz
carl9170: Convert byte_rev_table uses to bitrev8
Use the inline function instead of directly indexing the array. This allows some architectures with hardware instructions for bit reversals to eliminate the array. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/wireless/ath/carl9170/phy.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/ath/carl9170/phy.c b/drivers/net/wireless/ath/carl9170/phy.c
index b80b2138ce3c..dca6df13fd5b 100644
--- a/drivers/net/wireless/ath/carl9170/phy.c
+++ b/drivers/net/wireless/ath/carl9170/phy.c
@@ -994,7 +994,7 @@ static int carl9170_init_rf_bank4_pwr(struct ar9170 *ar, bool band5ghz,
refsel0 = 0;
refsel1 = 1;
}
- chansel = byte_rev_table[chansel];
+ chansel = bitrev8(chansel);
} else {
if (freq == 2484) {
chansel = 10 + (freq - 2274) / 5;
@@ -1002,7 +1002,7 @@ static int carl9170_init_rf_bank4_pwr(struct ar9170 *ar, bool band5ghz,
} else
chansel = 16 + (freq - 2272) / 5;
chansel *= 4;
- chansel = byte_rev_table[chansel];
+ chansel = bitrev8(chansel);
}
d1 = chansel;