aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant/wpas_glue.c
diff options
context:
space:
mode:
authorGanesh Prasadh <gprasadh@atheros.com>2010-10-07 07:26:56 (GMT)
committerJouni Malinen <j@w1.fi>2011-03-06 12:53:49 (GMT)
commit281ff0aa76d7b6cec0ecb0d9fa209c57c9066dd0 (patch)
treefe0081cd26e83edaf1074b945b235cae7e82f550 /wpa_supplicant/wpas_glue.c
parent23ab8e863f5add2050cd71ec1205816152ae4f2f (diff)
downloadhostap-281ff0aa76d7b6cec0ecb0d9fa209c57c9066dd0.zip
hostap-281ff0aa76d7b6cec0ecb0d9fa209c57c9066dd0.tar.gz
hostap-281ff0aa76d7b6cec0ecb0d9fa209c57c9066dd0.tar.bz2
TDLS: Add initial support for TDLS (IEEE Std 802.11z-2010)
Diffstat (limited to 'wpa_supplicant/wpas_glue.c')
-rw-r--r--wpa_supplicant/wpas_glue.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/wpa_supplicant/wpas_glue.c b/wpa_supplicant/wpas_glue.c
index 5b7aebe..2662eec 100644
--- a/wpa_supplicant/wpas_glue.c
+++ b/wpa_supplicant/wpas_glue.c
@@ -535,6 +535,28 @@ static int wpa_supplicant_mark_authenticated(void *ctx, const u8 *target_ap)
#endif /* CONFIG_NO_WPA */
+#ifdef CONFIG_TDLS
+
+static int wpa_supplicant_send_tdls_mgmt(void *ctx, const u8 *dst,
+ u8 action_code, u8 dialog_token,
+ u16 status_code, const u8 *buf,
+ size_t len)
+{
+ struct wpa_supplicant *wpa_s = ctx;
+ return wpa_drv_send_tdls_mgmt(wpa_s, dst, action_code, dialog_token,
+ status_code, buf, len);
+}
+
+
+static int wpa_supplicant_tdls_oper(void *ctx, int oper, const u8 *peer)
+{
+ struct wpa_supplicant *wpa_s = ctx;
+ return wpa_drv_tdls_oper(wpa_s, oper, peer);
+}
+
+#endif /* CONFIG_TDLS */
+
+
#ifdef IEEE8021X_EAPOL
#if defined(CONFIG_CTRL_IFACE) || !defined(CONFIG_NO_STDOUT_DEBUG)
static void wpa_supplicant_eap_param_needed(void *ctx, const char *field,
@@ -668,6 +690,10 @@ int wpa_supplicant_init_wpa(struct wpa_supplicant *wpa_s)
ctx->send_ft_action = wpa_supplicant_send_ft_action;
ctx->mark_authenticated = wpa_supplicant_mark_authenticated;
#endif /* CONFIG_IEEE80211R */
+#ifdef CONFIG_TDLS
+ ctx->send_tdls_mgmt = wpa_supplicant_send_tdls_mgmt;
+ ctx->tdls_oper = wpa_supplicant_tdls_oper;
+#endif /* CONFIG_TDLS */
wpa_s->wpa = wpa_sm_init(ctx);
if (wpa_s->wpa == NULL) {