diff options
author | Mohamed Abbas <mohamed.abbas@intel.com> | 2011-09-13 09:55:13 +0300 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2011-09-13 10:53:00 +0200 |
commit | f5af5715d88a0525e6bc6323d196bd78680e67d1 (patch) | |
tree | 7a2194af07467dc98d9a74376e5b2c3a665391e8 /gsupplicant/supplicant.c | |
parent | 434890b2816e24d5ec93ad1044fbf21eb6b10903 (diff) | |
download | connman-f5af5715d88a0525e6bc6323d196bd78680e67d1.tar.gz connman-f5af5715d88a0525e6bc6323d196bd78680e67d1.tar.bz2 connman-f5af5715d88a0525e6bc6323d196bd78680e67d1.zip |
service: Add frequency support to service
Get the frequncy of gsupplicant network on connman network
creation, and always save the frequency of the wifi service.
Diffstat (limited to 'gsupplicant/supplicant.c')
-rw-r--r-- | gsupplicant/supplicant.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/gsupplicant/supplicant.c b/gsupplicant/supplicant.c index 30bdd811..dda2c923 100644 --- a/gsupplicant/supplicant.c +++ b/gsupplicant/supplicant.c @@ -197,6 +197,7 @@ struct _GSupplicantNetwork { unsigned char ssid[32]; unsigned int ssid_len; dbus_int16_t signal; + dbus_uint16_t frequency; struct g_supplicant_bss *best_bss; GSupplicantMode mode; GSupplicantSecurity security; @@ -795,6 +796,14 @@ dbus_int16_t g_supplicant_network_get_signal(GSupplicantNetwork *network) return network->signal; } +dbus_uint16_t g_supplicant_network_get_frequency(GSupplicantNetwork *network) +{ + if (network == NULL) + return 0; + + return network->frequency; +} + dbus_bool_t g_supplicant_network_get_wps(GSupplicantNetwork *network) { if (network == NULL) @@ -1019,6 +1028,7 @@ static void add_bss_to_network(struct g_supplicant_bss *bss) network->ssid_len = bss->ssid_len; memcpy(network->ssid, bss->ssid, bss->ssid_len); network->signal = bss->signal; + network->frequency = bss->frequency; network->best_bss = bss; network->wps = FALSE; |