mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-11-16 17:09:24 +01:00
wired: Update to the new l_netlink_send API
This commit is contained in:
parent
993e48cab2
commit
d7f669dd7c
@ -723,7 +723,8 @@ static void setup_adapter_interface(struct l_dbus_interface *interface)
|
|||||||
|
|
||||||
bool ethdev_init(const char *whitelist, const char *blacklist)
|
bool ethdev_init(const char *whitelist, const char *blacklist)
|
||||||
{
|
{
|
||||||
struct ifinfomsg msg;
|
struct ifinfomsg ifi;
|
||||||
|
struct l_netlink_message *nlm;
|
||||||
|
|
||||||
if (rtnl)
|
if (rtnl)
|
||||||
return false;
|
return false;
|
||||||
@ -760,10 +761,11 @@ bool ethdev_init(const char *whitelist, const char *blacklist)
|
|||||||
if (blacklist)
|
if (blacklist)
|
||||||
blacklist_filter = l_strsplit(blacklist, ',');
|
blacklist_filter = l_strsplit(blacklist, ',');
|
||||||
|
|
||||||
memset(&msg, 0, sizeof(msg));
|
memset(&ifi, 0, sizeof(ifi));
|
||||||
|
nlm = l_netlink_message_new_sized(RTM_GETLINK, NLM_F_DUMP, sizeof(ifi));
|
||||||
|
l_netlink_message_add_header(nlm, &ifi, sizeof(ifi));
|
||||||
|
|
||||||
l_netlink_send(rtnl, RTM_GETLINK, NLM_F_DUMP, &msg, sizeof(msg),
|
l_netlink_send(rtnl, nlm, getlink_callback, NULL, NULL);
|
||||||
getlink_callback, NULL, NULL);
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user