3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-12-21 11:52:34 +01:00

device: Add device_get_connected_network()

This commit is contained in:
Denis Kenzior 2016-05-11 22:27:31 -05:00
parent 08d72cd213
commit 23fe106cc5
2 changed files with 7 additions and 0 deletions

View File

@ -35,5 +35,7 @@ bool device_watch_remove(uint32_t id);
void __device_watch_call_added(struct netdev *device);
void __device_watch_call_removed(struct netdev *device);
struct network *device_get_connected_network(struct netdev *device);
bool device_init(void);
bool device_exit(void);

View File

@ -194,6 +194,11 @@ const uint8_t *netdev_get_address(struct netdev *netdev)
return netdev->addr;
}
struct network *device_get_connected_network(struct netdev *device)
{
return device->connected_network;
}
static void netdev_enter_state(struct netdev *netdev, enum device_state state)
{
l_debug("Old State: %s, new state: %s",