summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/adm8211.h
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2008-01-24 19:38:38 +0100
committerJohn W. Linville <linville@tuxdriver.com>2008-02-29 15:19:32 -0500
commit8318d78a44d49ac1edf2bdec7299de3617c4232e (patch)
treed434634418edd7399737801615d247be06616fdd /drivers/net/wireless/adm8211.h
parent10b6b80145cc93887dd8aab99bfffa375e9add31 (diff)
cfg80211 API for channels/bitrates, mac80211 and driver conversion
This patch creates new cfg80211 wiphy API for channel and bitrate registration and converts mac80211 and drivers to the new API. The old mac80211 API is completely ripped out. All drivers (except ath5k) are updated to the new API, in many cases I expect that optimisations can be done. Along with the regulatory code I've also ripped out the IEEE80211_HW_DEFAULT_REG_DOMAIN_CONFIGURED flag, I believe it to be unnecessary if the hardware simply gives us whatever channels it wants to support and we then enable/disable them as required, which is pretty much required for travelling. Additionally, the patch adds proper "basic" rate handling for STA mode interface, AP mode interface will have to have new API added to allow userspace to set the basic rate set, currently it'll be empty... However, the basic rate handling will need to be moved to the BSS conf stuff. I do expect there to be bugs in this, especially wrt. transmit power handling where I'm basically clueless about how it should work. Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/adm8211.h')
-rw-r--r--drivers/net/wireless/adm8211.h65
1 files changed, 7 insertions, 58 deletions
diff --git a/drivers/net/wireless/adm8211.h b/drivers/net/wireless/adm8211.h
index ef326fed42e4..8d7c564b3b04 100644
--- a/drivers/net/wireless/adm8211.h
+++ b/drivers/net/wireless/adm8211.h
@@ -534,61 +534,6 @@ struct adm8211_eeprom {
u8 cis_data[0]; /* 0x80, 384 bytes */
} __attribute__ ((packed));
-static const struct ieee80211_rate adm8211_rates[] = {
- { .rate = 10,
- .val = 10,
- .val2 = -10,
- .flags = IEEE80211_RATE_CCK_2 },
- { .rate = 20,
- .val = 20,
- .val2 = -20,
- .flags = IEEE80211_RATE_CCK_2 },
- { .rate = 55,
- .val = 55,
- .val2 = -55,
- .flags = IEEE80211_RATE_CCK_2 },
- { .rate = 110,
- .val = 110,
- .val2 = -110,
- .flags = IEEE80211_RATE_CCK_2 }
-};
-
-struct ieee80211_chan_range {
- u8 min;
- u8 max;
-};
-
-static const struct ieee80211_channel adm8211_channels[] = {
- { .chan = 1,
- .freq = 2412},
- { .chan = 2,
- .freq = 2417},
- { .chan = 3,
- .freq = 2422},
- { .chan = 4,
- .freq = 2427},
- { .chan = 5,
- .freq = 2432},
- { .chan = 6,
- .freq = 2437},
- { .chan = 7,
- .freq = 2442},
- { .chan = 8,
- .freq = 2447},
- { .chan = 9,
- .freq = 2452},
- { .chan = 10,
- .freq = 2457},
- { .chan = 11,
- .freq = 2462},
- { .chan = 12,
- .freq = 2467},
- { .chan = 13,
- .freq = 2472},
- { .chan = 14,
- .freq = 2484},
-};
-
struct adm8211_priv {
struct pci_dev *pdev;
spinlock_t lock;
@@ -603,9 +548,8 @@ struct adm8211_priv {
unsigned int cur_tx, dirty_tx, cur_rx;
struct ieee80211_low_level_stats stats;
- struct ieee80211_hw_mode modes[1];
- struct ieee80211_channel channels[ARRAY_SIZE(adm8211_channels)];
- struct ieee80211_rate rates[ARRAY_SIZE(adm8211_rates)];
+ struct ieee80211_supported_band band;
+ struct ieee80211_channel channels[14];
int mode;
int channel;
@@ -643,6 +587,11 @@ struct adm8211_priv {
} transceiver_type;
};
+struct ieee80211_chan_range {
+ u8 min;
+ u8 max;
+};
+
static const struct ieee80211_chan_range cranges[] = {
{1, 11}, /* FCC */
{1, 11}, /* IC */