projects
/
framework
/
connectivity
/
connman.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
aae3b73
)
wifi: Regulatory domain setting implementation
author
Samuel Ortiz
<sameo@linux.intel.com>
Thu, 9 Dec 2010 00:37:02 +0000
(
01:37
+0100)
committer
Samuel Ortiz
<sameo@linux.intel.com>
Wed, 15 Dec 2010 19:43:49 +0000
(20:43 +0100)
plugins/wifi.c
patch
|
blob
|
history
diff --git
a/plugins/wifi.c
b/plugins/wifi.c
index
b12aa06
..
2b43deb
100644
(file)
--- a/
plugins/wifi.c
+++ b/
plugins/wifi.c
@@
-53,6
+53,8
@@
#define CLEANUP_TIMEOUT 8 /* in seconds */
#define INACTIVE_TIMEOUT 12 /* in seconds */
#define CLEANUP_TIMEOUT 8 /* in seconds */
#define INACTIVE_TIMEOUT 12 /* in seconds */
+struct connman_technology *wifi_technology = NULL;
+
struct wifi_data {
char *identifier;
struct connman_device *device;
struct wifi_data {
char *identifier;
struct connman_device *device;
@@
-635,16
+637,31
@@
static struct connman_network_driver network_driver = {
static int tech_probe(struct connman_technology *technology)
{
static int tech_probe(struct connman_technology *technology)
{
+ wifi_technology = technology;
+
return 0;
}
static void tech_remove(struct connman_technology *technology)
{
return 0;
}
static void tech_remove(struct connman_technology *technology)
{
+ wifi_technology = NULL;
+}
+
+static void regdom_callback(void *user_data)
+{
+ char *alpha2 = user_data;
+
+ DBG("");
+
+ if (wifi_technology == NULL)
+ return;
+
+ connman_technology_regdom_notify(wifi_technology, alpha2);
}
static int tech_set_regdom(struct connman_technology *technology, const char *alpha2)
{
}
static int tech_set_regdom(struct connman_technology *technology, const char *alpha2)
{
- return
0
;
+ return
g_supplicant_set_country(alpha2, regdom_callback, alpha2)
;
}
static struct connman_technology_driver tech_driver = {
}
static struct connman_technology_driver tech_driver = {