diff options
author | Jouni Malinen <jouni.malinen@atheros.com> | 2009-11-23 20:22:38 +0200 |
---|---|---|
committer | Jouni Malinen <j@w1.fi> | 2009-11-23 20:22:38 +0200 |
commit | 4a867032aeba4825cd18ddf14199dd81f760e81a (patch) | |
tree | b4cf8b4d8522416fb7b3f60b0445b269a8ab6a2c /src/drivers/driver_madwifi.c | |
parent | 331c12086fdcc0b45a35d6dbba567462c14b3612 (diff) | |
download | external_wpa_supplicant_8_ti-4a867032aeba4825cd18ddf14199dd81f760e81a.zip external_wpa_supplicant_8_ti-4a867032aeba4825cd18ddf14199dd81f760e81a.tar.gz external_wpa_supplicant_8_ti-4a867032aeba4825cd18ddf14199dd81f760e81a.tar.bz2 |
Remove deprecated driver_ops handlers
This gets rid of previously deprecated driver_ops handlers set_wpa,
set_drop_unencrypted, set_auth_alg, set_mode. The same functionality
can be achieved by using the init/deinit/associate handlers.
Diffstat (limited to 'src/drivers/driver_madwifi.c')
-rw-r--r-- | src/drivers/driver_madwifi.c | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/src/drivers/driver_madwifi.c b/src/drivers/driver_madwifi.c index bf61fc5..6c2fec9 100644 --- a/src/drivers/driver_madwifi.c +++ b/src/drivers/driver_madwifi.c @@ -1386,6 +1386,9 @@ struct wpa_driver_madwifi_data { int sock; }; +static int wpa_driver_madwifi_set_auth_alg(void *priv, int auth_alg); + + static int set80211priv(struct wpa_driver_madwifi_data *drv, int op, void *data, int len, int show_err) @@ -1634,15 +1637,6 @@ wpa_driver_madwifi_set_countermeasures(void *priv, int enabled) return set80211param(drv, IEEE80211_PARAM_COUNTERMEASURES, enabled, 1); } - -static int -wpa_driver_madwifi_set_drop_unencrypted(void *priv, int enabled) -{ - struct wpa_driver_madwifi_data *drv = priv; - wpa_printf(MSG_DEBUG, "%s: enabled=%d", __FUNCTION__, enabled); - return set80211param(drv, IEEE80211_PARAM_DROPUNENCRYPTED, enabled, 1); -} - static int wpa_driver_madwifi_deauthenticate(void *priv, const u8 *addr, int reason_code) { @@ -1679,6 +1673,12 @@ wpa_driver_madwifi_associate(void *priv, wpa_printf(MSG_DEBUG, "%s", __FUNCTION__); + if (set80211param(drv, IEEE80211_PARAM_DROPUNENCRYPTED, + params->drop_unencrypted, 1) < 0) + ret = -1; + if (wpa_driver_madwifi_set_auth_alg(drv, params->auth_alg) < 0) + ret = -1; + /* * NB: Don't need to set the freq or cipher-related state as * this is implied by the bssid which is used to locate @@ -1943,13 +1943,11 @@ const struct wpa_driver_ops wpa_driver_madwifi_ops = { .init = wpa_driver_madwifi_init, .deinit = wpa_driver_madwifi_deinit, .set_countermeasures = wpa_driver_madwifi_set_countermeasures, - .set_drop_unencrypted = wpa_driver_madwifi_set_drop_unencrypted, .scan = wpa_driver_madwifi_scan, .get_scan_results2 = wpa_driver_madwifi_get_scan_results, .deauthenticate = wpa_driver_madwifi_deauthenticate, .disassociate = wpa_driver_madwifi_disassociate, .associate = wpa_driver_madwifi_associate, - .set_auth_alg = wpa_driver_madwifi_set_auth_alg, .set_operstate = wpa_driver_madwifi_set_operstate, .set_probe_req_ie = wpa_driver_madwifi_set_probe_req_ie, #endif /* HOSTAPD */ |