CONNMAN_DEVICE_MODE_UNKNOWN = 0,
CONNMAN_DEVICE_MODE_NETWORK_SINGLE = 1,
CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE = 2,
- CONNMAN_DEVICE_MODE_TRANSPORT_IP = 3,
};
struct connman_device;
int connman_device_set_powered(struct connman_device *device,
connman_bool_t powered);
-int connman_device_set_carrier(struct connman_device *device,
- connman_bool_t carrier);
int connman_device_set_scanning(struct connman_device *device,
connman_bool_t scanning);
void connman_device_cleanup_scanning(struct connman_device *device);
enum connman_network_type {
CONNMAN_NETWORK_TYPE_UNKNOWN = 0,
- CONNMAN_NETWORK_TYPE_CABLE = 1,
+ CONNMAN_NETWORK_TYPE_ETHERNET = 1,
CONNMAN_NETWORK_TYPE_WIFI = 2,
CONNMAN_NETWORK_TYPE_WIMAX = 3,
CONNMAN_NETWORK_TYPE_BLUETOOTH_PAN = 8,
int index;
unsigned flags;
unsigned int watch;
+ struct connman_network *network;
};
+static int cable_probe(struct connman_network *network)
+{
+ DBG("network %p", network);
+
+ return 0;
+}
+
+static void cable_remove(struct connman_network *network)
+{
+ DBG("network %p", network);
+}
+
+static int cable_connect(struct connman_network *network)
+{
+ DBG("network %p", network);
+
+ return 0;
+}
+
+static int cable_disconnect(struct connman_network *network)
+{
+ DBG("network %p", network);
+
+ return 0;
+}
+
+static struct connman_network_driver cable_driver = {
+ .name = "cable",
+ .type = CONNMAN_NETWORK_TYPE_ETHERNET,
+ .probe = cable_probe,
+ .remove = cable_remove,
+ .connect = cable_connect,
+ .disconnect = cable_disconnect,
+};
+
+static void add_network(struct connman_device *device)
+{
+ struct connman_network *network;
+ int index;
+
+ network = connman_network_create("carrier",
+ CONNMAN_NETWORK_TYPE_ETHERNET);
+ if (network == NULL)
+ return;
+
+ index = connman_device_get_index(device);
+ connman_network_set_index(network, index);
+
+ connman_network_set_name(network, "Wired");
+ connman_network_set_protocol(network, CONNMAN_NETWORK_PROTOCOL_IP);
+
+ if (connman_device_add_network(device, network) < 0) {
+ connman_network_unref(network);
+ return;
+ }
+
+ connman_network_set_available(network, TRUE);
+ connman_network_set_connected(network, TRUE);
+
+ connman_network_set_group(network, "cable");
+}
+
static void ethernet_newlink(unsigned flags, unsigned change, void *user_data)
{
struct connman_device *device = user_data;
if ((ethernet->flags & IFF_LOWER_UP) != (flags & IFF_LOWER_UP)) {
if (flags & IFF_LOWER_UP) {
DBG("carrier on");
- connman_device_set_carrier(device, TRUE);
+ add_network(device);
} else {
DBG("carrier off");
- connman_device_set_carrier(device, FALSE);
+ connman_device_remove_all_networks(device);
}
}
connman_rtnl_remove_watch(ethernet->watch);
+ connman_device_remove_all_networks(device);
+
g_free(ethernet);
}
return connman_inet_ifdown(ethernet->index);
}
-static int ethernet_connect(struct connman_device *device)
-{
- struct ethernet_data *ethernet = connman_device_get_data(device);
-
- DBG("device %p", device);
-
- if (!(ethernet->flags & IFF_LOWER_UP))
- return -ENOTCONN;
-
- return connman_device_set_connected(device, TRUE);
-}
-
-static int ethernet_disconnect(struct connman_device *device)
-{
- struct ethernet_data *ethernet = connman_device_get_data(device);
-
- DBG("device %p", device);
-
- if (!(ethernet->flags & IFF_LOWER_UP))
- return -ENOTCONN;
-
- return connman_device_set_connected(device, FALSE);
-}
-
static struct connman_device_driver ethernet_driver = {
.name = "ethernet",
.type = CONNMAN_DEVICE_TYPE_ETHERNET,
.remove = ethernet_remove,
.enable = ethernet_enable,
.disable = ethernet_disable,
- .connect = ethernet_connect,
- .disconnect = ethernet_disconnect,
};
static int ethernet_init(void)
{
- return connman_device_driver_register(ðernet_driver);
+ int err;
+
+ err = connman_network_driver_register(&cable_driver);
+ if (err < 0)
+ return err;
+
+ err = connman_device_driver_register(ðernet_driver);
+ if (err < 0) {
+ connman_network_driver_unregister(&cable_driver);
+ return err;
+ }
+
+ return 0;
}
static void ethernet_exit(void)
{
+ connman_network_driver_unregister(&cable_driver);
+
connman_device_driver_unregister(ðernet_driver);
}
void __connman_service_put(struct connman_service *service);
-struct connman_service *__connman_service_lookup_from_device(struct connman_device *device);
-struct connman_service *__connman_service_create_from_device(struct connman_device *device);
-void __connman_service_remove_from_device(struct connman_device *device);
-
struct connman_service *__connman_service_lookup_from_network(struct connman_network *network);
struct connman_service *__connman_service_create_from_network(struct connman_network *network);
void __connman_service_update_from_network(struct connman_network *network);
const char *__connman_service_get_path(struct connman_service *service);
unsigned int __connman_service_get_order(struct connman_service *service);
-int __connman_service_set_carrier(struct connman_service *service,
- connman_bool_t carrier);
int __connman_service_indicate_state(struct connman_service *service,
enum connman_service_state state);
int __connman_service_indicate_error(struct connman_service *service,
connman_bool_t powered;
connman_bool_t powered_pending;
connman_bool_t powered_persistent;
- connman_bool_t carrier;
connman_bool_t scanning;
connman_bool_t disconnected;
connman_bool_t reconnect;
int phyindex;
unsigned int connections;
guint scan_timeout;
- struct connman_ipconfig *ipconfig;
struct connman_device_driver *driver;
void *driver_data;
return CONNMAN_SERVICE_TYPE_UNKNOWN;
}
-static int set_connected(struct connman_device *device,
- connman_bool_t connected)
-{
- if (connected == TRUE) {
- enum connman_element_type type = CONNMAN_ELEMENT_TYPE_UNKNOWN;
- struct connman_element *element;
-
- device->disconnected = TRUE;
-
- switch (device->element.ipv4.method) {
- case CONNMAN_IPCONFIG_METHOD_UNKNOWN:
- case CONNMAN_IPCONFIG_METHOD_IGNORE:
- return 0;
- case CONNMAN_IPCONFIG_METHOD_STATIC:
- type = CONNMAN_ELEMENT_TYPE_IPV4;
- break;
- case CONNMAN_IPCONFIG_METHOD_DHCP:
- type = CONNMAN_ELEMENT_TYPE_DHCP;
- break;
- }
-
- element = connman_element_create(NULL);
- if (element != NULL) {
- struct connman_service *service;
-
- element->type = type;
- element->index = device->element.index;
-
- if (connman_element_register(element,
- &device->element) < 0)
- connman_element_unref(element);
-
- device->disconnected = FALSE;
-
- service = __connman_service_lookup_from_device(device);
- __connman_service_indicate_state(service,
- CONNMAN_SERVICE_STATE_CONFIGURATION);
- }
- } else {
- struct connman_service *service;
-
- connman_element_unregister_children(&device->element);
-
- device->disconnected = TRUE;
-
- service = __connman_service_lookup_from_device(device);
- __connman_service_indicate_state(service,
- CONNMAN_SERVICE_STATE_IDLE);
- }
-
- if (connected == TRUE) {
- enum connman_service_type type;
-
- type = __connman_device_get_service_type(device);
- __connman_notifier_connect(type);
- } else {
- enum connman_service_type type;
-
- type = __connman_device_get_service_type(device);
- __connman_notifier_disconnect(type);
- }
-
- return 0;
-}
-
-static int set_carrier(struct connman_device *device, connman_bool_t carrier)
-{
- if (carrier == TRUE)
- __connman_profile_add_device(device);
- else
- __connman_profile_remove_device(device);
-
- return set_connected(device, carrier);
-}
-
static int powered_changed(struct connman_device *device)
{
DBusMessage *signal;
g_hash_table_remove_all(device->networks);
- set_carrier(device, FALSE);
-
if (driver->disable) {
err = driver->disable(device);
if (err == 0)
switch (device->mode) {
case CONNMAN_DEVICE_MODE_UNKNOWN:
break;
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
- __connman_element_append_ipv4(&device->element, &dict);
- break;
case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
if (device->scan_interval > 0)
switch (device->mode) {
case CONNMAN_DEVICE_MODE_UNKNOWN:
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
- return __connman_error_invalid_arguments(msg);
case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
break;
reset_scan_trigger(device);
}
- } else if (g_str_has_prefix(name, "IPv4.") == TRUE) {
- int err;
-
- if (device->ipconfig == NULL)
- return __connman_error_invalid_property(msg);
-
- switch (device->mode) {
- case CONNMAN_DEVICE_MODE_UNKNOWN:
- case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
- case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
- return __connman_error_invalid_arguments(msg);
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
- break;
- }
-
- err = __connman_ipconfig_set_ipv4(device->ipconfig,
- name + 5, &value);
- if (err < 0)
- return __connman_error_failed(msg, -err);
} else
return __connman_error_invalid_property(msg);
switch (device->mode) {
case CONNMAN_DEVICE_MODE_UNKNOWN:
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
return __connman_error_not_supported(msg);
case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
break;
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
- if (device->carrier == TRUE && device->secondary == FALSE)
- __connman_profile_add_device(device);
- break;
}
if (device->offlinemode == FALSE &&
case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
break;
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
- if (device->secondary == FALSE)
- __connman_profile_remove_device(device);
- break;
}
type = __connman_device_get_service_type(device);
g_free(device->control);
g_free(device->interface);
- if (device->ipconfig != NULL) {
- connman_ipconfig_unref(device->ipconfig);
- device->ipconfig = NULL;
- }
-
g_free(device->last_network);
g_hash_table_destroy(device->networks);
void connman_device_set_index(struct connman_device *device, int index)
{
device->element.index = index;
-
- if (device->ipconfig != NULL) {
- if (index == connman_ipconfig_get_index(device->ipconfig))
- return;
-
- connman_ipconfig_unref(device->ipconfig);
- }
-
- device->ipconfig = connman_ipconfig_create(index);
}
/**
return set_powered(device, powered);
}
-/**
- * connman_device_set_carrier:
- * @device: device structure
- * @carrier: carrier state
- *
- * Change carrier state of device (only for device without scanning)
- */
-int connman_device_set_carrier(struct connman_device *device,
- connman_bool_t carrier)
-{
- DBG("device %p carrier %d", device, carrier);
-
- switch (device->mode) {
- case CONNMAN_DEVICE_MODE_UNKNOWN:
- case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
- case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
- return -EINVAL;
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
- break;
- }
-
- if (device->carrier == carrier)
- return -EALREADY;
-
- device->carrier = carrier;
-
- return set_carrier(device, device->carrier);
-}
-
int __connman_device_scan(struct connman_device *device)
{
if (!device->driver || !device->driver->scan)
switch (device->mode) {
case CONNMAN_DEVICE_MODE_UNKNOWN:
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
return -EINVAL;
case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
}
/**
- * connman_device_set_connected:
- * @device: device structure
- * @connected: connected state
- *
- * Change connected state of device (for Ethernet like devices)
- */
-int connman_device_set_connected(struct connman_device *device,
- connman_bool_t connected)
-{
- DBG("device %p connected %d", device, connected);
-
- switch (device->mode) {
- case CONNMAN_DEVICE_MODE_UNKNOWN:
- case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
- case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
- return -EINVAL;
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
- break;
- }
-
- if (device->carrier == FALSE)
- return -ENOTCONN;
-
- return set_connected(device, connected);
-}
-
-/**
* connman_device_set_string:
* @device: device structure
* @key: unique identifier
DBG("device %p network %p", device, network);
+ if (identifier == NULL)
+ return -EINVAL;
+
switch (device->mode) {
case CONNMAN_DEVICE_MODE_UNKNOWN:
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
return -EINVAL;
case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
switch (device->mode) {
case CONNMAN_DEVICE_MODE_UNKNOWN:
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
break;
case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
switch (device->mode) {
case CONNMAN_DEVICE_MODE_UNKNOWN:
- case CONNMAN_DEVICE_MODE_TRANSPORT_IP:
break;
case CONNMAN_DEVICE_MODE_NETWORK_SINGLE:
case CONNMAN_DEVICE_MODE_NETWORK_MULTIPLE:
case CONNMAN_DEVICE_TYPE_NOVATEL:
break;
case CONNMAN_DEVICE_TYPE_ETHERNET:
- service = __connman_service_lookup_from_device(device);
- break;
case CONNMAN_DEVICE_TYPE_WIFI:
case CONNMAN_DEVICE_TYPE_WIMAX:
case CONNMAN_DEVICE_TYPE_BLUETOOTH:
mode = CONNMAN_DEVICE_MODE_UNKNOWN;
break;
case CONNMAN_DEVICE_TYPE_ETHERNET:
- mode = CONNMAN_DEVICE_MODE_TRANSPORT_IP;
+ mode = CONNMAN_DEVICE_MODE_NETWORK_SINGLE;
ident = index2ident(index, NULL);
break;
case CONNMAN_DEVICE_TYPE_WIFI:
case CONNMAN_NETWORK_TYPE_UNKNOWN:
case CONNMAN_NETWORK_TYPE_VENDOR:
break;
- case CONNMAN_NETWORK_TYPE_CABLE:
- return "cable";
+ case CONNMAN_NETWORK_TYPE_ETHERNET:
+ return "ethernet";
case CONNMAN_NETWORK_TYPE_WIFI:
return "wifi";
case CONNMAN_NETWORK_TYPE_WIMAX:
switch (network->type) {
case CONNMAN_NETWORK_TYPE_UNKNOWN:
- case CONNMAN_NETWORK_TYPE_CABLE:
case CONNMAN_NETWORK_TYPE_VENDOR:
return;
+ case CONNMAN_NETWORK_TYPE_ETHERNET:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_PAN:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_DUN:
case CONNMAN_NETWORK_TYPE_CELLULAR:
switch (network->type) {
case CONNMAN_NETWORK_TYPE_UNKNOWN:
case CONNMAN_NETWORK_TYPE_VENDOR:
- case CONNMAN_NETWORK_TYPE_CABLE:
+ case CONNMAN_NETWORK_TYPE_ETHERNET:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_PAN:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_DUN:
case CONNMAN_NETWORK_TYPE_CELLULAR:
case CONNMAN_NETWORK_TYPE_UNKNOWN:
case CONNMAN_NETWORK_TYPE_VENDOR:
break;
- case CONNMAN_NETWORK_TYPE_CABLE:
+ case CONNMAN_NETWORK_TYPE_ETHERNET:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_PAN:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_DUN:
case CONNMAN_NETWORK_TYPE_CELLULAR:
case CONNMAN_NETWORK_TYPE_UNKNOWN:
case CONNMAN_NETWORK_TYPE_VENDOR:
break;
- case CONNMAN_NETWORK_TYPE_CABLE:
+ case CONNMAN_NETWORK_TYPE_ETHERNET:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_PAN:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_DUN:
case CONNMAN_NETWORK_TYPE_CELLULAR:
changed_timeout = g_timeout_add_seconds(1, services_changed, NULL);
}
-int __connman_profile_add_device(struct connman_device *device)
-{
- struct connman_service *service;
-
- DBG("device %p", device);
-
- service = __connman_service_create_from_device(device);
- if (service == NULL)
- return -EINVAL;
-
- return 0;
-}
-
-int __connman_profile_remove_device(struct connman_device *device)
-{
- DBG("device %p", device);
-
- __connman_service_remove_from_device(device);
-
- return 0;
-}
-
int __connman_profile_add_network(struct connman_network *network)
{
struct connman_service *service;
char *mnc;
connman_bool_t roaming;
struct connman_ipconfig *ipconfig;
- struct connman_device *device;
struct connman_network *network;
DBusMessage *pending;
guint timeout;
if (service->network != NULL)
__connman_network_disconnect(service->network);
- else if (service->device != NULL)
- __connman_device_disconnect(service->device);
__connman_ipconfig_disable(service->ipconfig);
static void set_reconnect_state(struct connman_service *service,
connman_bool_t reconnect)
{
- if (service->network != NULL) {
- struct connman_device *device;
-
- device = connman_network_get_device(service->network);
+ struct connman_device *device;
- __connman_device_set_reconnect(device, reconnect);
+ if (service->network == NULL)
+ return;
+ device = connman_network_get_device(service->network);
+ if (device == NULL)
return;
- }
- if (service->device != NULL)
- __connman_device_set_reconnect(service->device,
- reconnect);
+ __connman_device_set_reconnect(device, reconnect);
}
static connman_bool_t get_reconnect_state(struct connman_service *service)
{
- if (service->network != NULL) {
- struct connman_device *device;
-
- device = connman_network_get_device(service->network);
+ struct connman_device *device;
- return __connman_device_get_reconnect(device);
- }
+ if (service->network == NULL)
+ return FALSE;
- if (service->device != NULL)
- return __connman_device_get_reconnect(service->device);
+ device = connman_network_get_device(service->network);
+ if (device == NULL)
+ return FALSE;
- return FALSE;
+ return __connman_device_get_reconnect(device);
}
static DBusMessage *connect_service(DBusConnection *conn,
if (service == NULL)
return NULL;
- if (service->network != NULL) {
- index = connman_network_get_index(service->network);
- } else if (service->device != NULL) {
- index = connman_device_get_index(service->device);
- } else
+ if (service->network == NULL)
return NULL;
+ index = connman_network_get_index(service->network);
+
return connman_inet_ifname(index);
}
connman_network_set_string(service->network,
"WiFi.Passphrase", service->passphrase);
break;
- case CONNMAN_NETWORK_TYPE_CABLE:
+ case CONNMAN_NETWORK_TYPE_ETHERNET:
case CONNMAN_NETWORK_TYPE_WIMAX:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_PAN:
case CONNMAN_NETWORK_TYPE_BLUETOOTH_DUN:
__connman_ipconfig_enable(service->ipconfig);
err = __connman_network_connect(service->network);
- } else if (service->device != NULL) {
- if (service->favorite == FALSE)
- return -ENOLINK;
-
- __connman_ipconfig_enable(service->ipconfig);
-
- err = __connman_device_connect(service->device);
} else
return -EOPNOTSUPP;
if (service->network != NULL) {
err = __connman_network_disconnect(service->network);
- } else if (service->device != NULL) {
- if (service->favorite == FALSE)
- return -ENOLINK;
- err = __connman_device_disconnect(service->device);
} else
return -EOPNOTSUPP;
}
/**
- * __connman_service_lookup_from_device:
- * @device: device structure
- *
- * Look up a service by device (reference count will not be increased)
- */
-struct connman_service *__connman_service_lookup_from_device(struct connman_device *device)
-{
- struct connman_service *service;
- const char *ident;
- char *name;
-
- ident = __connman_device_get_ident(device);
- if (ident == NULL)
- return NULL;
-
- name = g_strdup_printf("%s_%s",
- __connman_device_get_type(device), ident);
- service = __connman_service_lookup(name);
- g_free(name);
-
- return service;
-}
-
-/**
- * __connman_service_create_from_device:
- * @device: device structure
- *
- * Look up service by device and if not found, create one
- */
-struct connman_service *__connman_service_create_from_device(struct connman_device *device)
-{
- struct connman_service *service;
- const char *ident;
- char *name;
-
- ident = __connman_device_get_ident(device);
- if (ident == NULL)
- return NULL;
-
- name = g_strdup_printf("%s_%s",
- __connman_device_get_type(device), ident);
- service = __connman_service_get(name);
- g_free(name);
-
- if (service == NULL)
- return NULL;
-
- if (service->path != NULL) {
- __connman_profile_changed(TRUE);
- return service;
- }
-
- service->type = __connman_device_get_service_type(device);
-
- service->autoconnect = FALSE;
-
- service->device = device;
-
- setup_ipconfig(service, connman_device_get_index(device));
-
- service_register(service);
-
- __connman_profile_changed(TRUE);
-
- if (service->favorite == TRUE)
- __connman_service_auto_connect();
-
- return service;
-}
-
-void __connman_service_remove_from_device(struct connman_device *device)
-{
- struct connman_service *service;
- enum connman_service_type type;
-
- service = __connman_service_lookup_from_device(device);
- if (service == NULL)
- return;
-
- type = service->type;
-
- __connman_service_put(service);
-
- default_changed();
-
- __connman_notifier_disconnect(type);
-
- __connman_service_auto_connect();
-}
-
-/**
* __connman_service_lookup_from_network:
* @network: network structure
*
const char *ident, *group;
char *name;
+ DBG("network %p", network);
+
ident = __connman_network_get_ident(network);
if (ident == NULL)
return NULL;
case CONNMAN_NETWORK_TYPE_UNKNOWN:
case CONNMAN_NETWORK_TYPE_VENDOR:
break;
- case CONNMAN_NETWORK_TYPE_CABLE:
+ case CONNMAN_NETWORK_TYPE_ETHERNET:
return CONNMAN_SERVICE_TYPE_ETHERNET;
case CONNMAN_NETWORK_TYPE_WIFI:
return CONNMAN_SERVICE_TYPE_WIFI;
GSequenceIter *iter;
const char *str;
+ DBG("service %p network %p", service, network);
+
if (service->state == CONNMAN_SERVICE_STATE_READY)
return;
const char *ident, *group;
char *name;
+ DBG("network %p", network);
+
ident = __connman_network_get_ident(network);
if (ident == NULL)
return NULL;
connman_bool_t roaming;
GSequenceIter *iter;
+ DBG("network %p", network);
+
service = __connman_service_lookup_from_network(network);
if (service == NULL)
return;
{
struct connman_service *service;
+ DBG("network %p", network);
+
service = __connman_service_lookup_from_network(network);
if (service == NULL)
return;
properties = device.GetProperties()
try:
- if properties["Type"] not in ["wifi", "wimax",
- "bluetooth", "cellular"]:
+ if properties["Type"] not in ["ethernet", "wifi", "wimax",
+ "bluetooth", "cellular"]:
continue
except:
continue