431856c8 | 26-Aug-2025 |
Aymeric Wibo <obiwac@FreeBSD.org> |
netlink: Bypass refcounting when setting promiscuity
When asking for IFF_PROMISC when modifying interfaces with netlink, set permanent flag instead (IFF_PPROMISC) as netlink interface modification h
netlink: Bypass refcounting when setting promiscuity
When asking for IFF_PROMISC when modifying interfaces with netlink, set permanent flag instead (IFF_PPROMISC) as netlink interface modification has no way of doing promiscuity reference counting through ifpromisc(). We can't do reference counting because every netlink interface modification necessarily either sets or unsets IFF_PROMISC in ifi_flags, and ifi_change is usually set to 0xFFFFFFFF.
This logic was the same between this and SIOCSIFFLAGS, so factor out if_setppromisc() function.
Reviewed by: melifaro, saheed, kp, mckusick (mentor) Approved by: melifaro, saheed, mckusick (mentor) Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52056
show more ...
|
5bd5774f | 26-Aug-2025 |
Aymeric Wibo <obiwac@FreeBSD.org> |
netlink: Handle `ifhwioctl(SIOCSIFMTU)` failure
Print out error message if setting MTU fails when modifying interface using netlink.
Reviewed by: saheed, melifaro, mckusick (mentor) Approved by: sa
netlink: Handle `ifhwioctl(SIOCSIFMTU)` failure
Print out error message if setting MTU fails when modifying interface using netlink.
Reviewed by: saheed, melifaro, mckusick (mentor) Approved by: saheed, melifaro, mckusick (mentor) Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D52132
show more ...
|
f34aca55 | 21-Jun-2024 |
Gleb Smirnoff <glebius@FreeBSD.org> |
netlink/route: provide pre-2.6.19 Linux compat shim
The old Linux used 8-bit rtm_table field of the RTM_NEWROUTE message to specify routing table id. Modern netlink uses RTA_TABLE 32-bit attribute.
netlink/route: provide pre-2.6.19 Linux compat shim
The old Linux used 8-bit rtm_table field of the RTM_NEWROUTE message to specify routing table id. Modern netlink uses RTA_TABLE 32-bit attribute.
Unfortunately, there is modern software (namely bird) that would prefer the old API as long as the routing table id fits into 8-bit.
PR: 279662
show more ...
|