summaryrefslogtreecommitdiff
path: root/gsupplicant
diff options
context:
space:
mode:
authorSamuel Ortiz <sameo@linux.intel.com>2011-01-31 16:38:48 +0100
committerSamuel Ortiz <sameo@linux.intel.com>2011-02-02 18:45:36 +0100
commit27724d297b0a11d12f46a121a1982617c9ccf7af (patch)
treeda5bcd43a619090245865d4aa298abbdc1b96f6a /gsupplicant
parent194b06ab47c9f7e493c3bc866b300280695e5a83 (diff)
downloadconnman-27724d297b0a11d12f46a121a1982617c9ccf7af.tar.gz
connman-27724d297b0a11d12f46a121a1982617c9ccf7af.tar.bz2
connman-27724d297b0a11d12f46a121a1982617c9ccf7af.zip
gsupplicant: Add interface mode capability getter
Diffstat (limited to 'gsupplicant')
-rw-r--r--gsupplicant/gsupplicant.h1
-rw-r--r--gsupplicant/supplicant.c8
2 files changed, 9 insertions, 0 deletions
diff --git a/gsupplicant/gsupplicant.h b/gsupplicant/gsupplicant.h
index c2462f4b..2ed8af66 100644
--- a/gsupplicant/gsupplicant.h
+++ b/gsupplicant/gsupplicant.h
@@ -168,6 +168,7 @@ const char *g_supplicant_interface_get_wps_key(GSupplicantInterface *interface);
const void *g_supplicant_interface_get_wps_ssid(GSupplicantInterface *interface,
unsigned int *ssid_len);
GSupplicantWpsState g_supplicant_interface_get_wps_state(GSupplicantInterface *interface);
+unsigned int g_supplicant_interface_get_mode(GSupplicantInterface *interface);
/* Network API */
struct _GSupplicantNetwork;
diff --git a/gsupplicant/supplicant.c b/gsupplicant/supplicant.c
index 2e178688..48a176a0 100644
--- a/gsupplicant/supplicant.c
+++ b/gsupplicant/supplicant.c
@@ -688,6 +688,14 @@ GSupplicantWpsState g_supplicant_interface_get_wps_state(
return interface->wps_state;
}
+unsigned int g_supplicant_interface_get_mode(GSupplicantInterface *interface)
+{
+ if (interface == NULL)
+ return 0;
+
+ return interface->mode_capa;
+}
+
GSupplicantInterface *g_supplicant_network_get_interface(
GSupplicantNetwork *network)
{