Commit 9696a159 authored by Larry Finger's avatar Larry Finger Committed by Kalle Valo

rtlwifi: Prepare for reworking 5G channels

There are 3 drivers in this family that have 5G radios. Each of them
defines local copies of the available channels. This patch adds the
two arrays to the core driver.
Signed-off-by: default avatarLarry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent ccf5fa4f
...@@ -35,6 +35,22 @@ ...@@ -35,6 +35,22 @@
#include <linux/export.h> #include <linux/export.h>
#include <net/cfg80211.h> #include <net/cfg80211.h>
u8 channel5g[CHANNEL_MAX_NUMBER_5G] = {
36, 38, 40, 42, 44, 46, 48, /* Band 1 */
52, 54, 56, 58, 60, 62, 64, /* Band 2 */
100, 102, 104, 106, 108, 110, 112, /* Band 3 */
116, 118, 120, 122, 124, 126, 128, /* Band 3 */
132, 134, 136, 138, 140, 142, 144, /* Band 3 */
149, 151, 153, 155, 157, 159, 161, /* Band 4 */
165, 167, 169, 171, 173, 175, 177 /* Band 4 */
};
EXPORT_SYMBOL(channel5g);
u8 channel5g_80m[CHANNEL_MAX_NUMBER_5G_80M] = {
42, 58, 106, 122, 138, 155, 171
};
EXPORT_SYMBOL(channel5g_80m);
void rtl_addr_delay(u32 addr) void rtl_addr_delay(u32 addr)
{ {
if (addr == 0xfe) if (addr == 0xfe)
......
...@@ -122,11 +122,6 @@ ...@@ -122,11 +122,6 @@
*/ */
#define CHANNEL_MAX_NUMBER_5G_80M 7 #define CHANNEL_MAX_NUMBER_5G_80M 7
#define CHANNEL_GROUP_MAX (3 + 9) /* ch1~3, 4~9, 10~14 = three groups */ #define CHANNEL_GROUP_MAX (3 + 9) /* ch1~3, 4~9, 10~14 = three groups */
#define CHANNEL_MAX_NUMBER_5G 54 /* Please refer to
*"phy_GetChnlGroup8812A" and
* "Hal_ReadTxPowerInfo8812A"
*/
#define CHANNEL_MAX_NUMBER_5G_80M 7
#define MAX_PG_GROUP 13 #define MAX_PG_GROUP 13
#define CHANNEL_GROUP_MAX_2G 3 #define CHANNEL_GROUP_MAX_2G 3
#define CHANNEL_GROUP_IDX_5GL 3 #define CHANNEL_GROUP_IDX_5GL 3
...@@ -2904,6 +2899,10 @@ value to host byte ordering.*/ ...@@ -2904,6 +2899,10 @@ value to host byte ordering.*/
#define STBC_VHT_TEST_TX_ENABLE BIT(2) #define STBC_VHT_TEST_TX_ENABLE BIT(2)
#define STBC_VHT_CAP_TX BIT(3) #define STBC_VHT_CAP_TX BIT(3)
extern u8 channel5g[CHANNEL_MAX_NUMBER_5G];
extern u8 channel5g_80m[CHANNEL_MAX_NUMBER_5G_80M];
static inline u8 rtl_read_byte(struct rtl_priv *rtlpriv, u32 addr) static inline u8 rtl_read_byte(struct rtl_priv *rtlpriv, u32 addr)
{ {
return rtlpriv->io.read8_sync(rtlpriv, addr); return rtlpriv->io.read8_sync(rtlpriv, addr);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment