aboutsummaryrefslogtreecommitdiff
path: root/src/mm-netlink.c
AgeCommit message (Collapse)Author
2025-02-18netlink: add RTM_GETLINK support to read MAC addressDan Williams
Since we're also now reading responses we need to check sender credentials to make sure we're talking to the kernel, and not some other process spoofing netlink. Signed-off-by: Dan Williams <dan@ioncontrol.co>
2022-03-28mm-netlink: use unaligned netlink attribute lengthBjørn Mork
Alignment padding is not accounted for in the netlink attribute length. Fix to avoid warnings later if we add shorter fixed length attributes, even though it currently makes no difference since we only add a 4 byte attribute Signed-off-by: Bjørn Mork <bjorn@mork.no>
2022-03-28mm-netlink: only change IFF_UP flagBjørn Mork
This fixes the missing NOARP flag on the second and following VLAN sub-interfaces when multiplexing over the cdc_mbim driver. ifi_change specifies all the flags we want to change. Any listed flag which isn't set in ifi_flags will be cleared by the kernel: if (ifm->ifi_change) flags = (flags & ifm->ifi_change) | (rtnl_dev_get_flags(dev) & ~ifm->ifi_change); Drivers like cdc_mbim set some netdev flags by default, indicating supported or unsupported features. The driver emulates an ethernet netdev but it doesn't implement ARP. Clearing NOARP on cdc_mbim netdevs will block IP transmissions, waiting for an ARP reply we never will receive. Signed-off-by: Bjørn Mork <bjorn@mork.no>
2021-03-10port-net: new 'MMPortNet' object with netlink capabilitiesAleksander Morgado
Right now just with the support to setup link properties like up/down state or the link mtu. This features are required when using QMAP based multiplexing with the qmi_wwan kernel driver.