summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorPacket Please <pktpls@systemli.org>2023-09-22 23:33:54 +0200
committerPacket Please <pktpls@systemli.org>2023-09-22 23:36:12 +0200
commitd3941744f6c103573a3bf9a3739d19dcb1884ba7 (patch)
tree4765d9057955449ab16edc3a287f37ca93089694
parent12277333d0895231db94eb58604391d7a754b2d6 (diff)
rtnl: add IFLA_TARGET_NETNSID for operating in other namespaces
Signed-off-by: Packet Please <pktpls@systemli.org>
-rw-r--r--lib/rtnl.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/rtnl.c b/lib/rtnl.c
index e5efa25..99a0983 100644
--- a/lib/rtnl.c
+++ b/lib/rtnl.c
@@ -713,7 +713,7 @@ static const uc_nl_nested_spec_t link_attrs_stats64_rta = {
static const uc_nl_nested_spec_t link_msg = {
.headsize = NLA_ALIGN(sizeof(struct ifinfomsg)),
- .nattrs = 25,
+ .nattrs = 26,
.attrs = {
{ IFLA_UNSPEC, "family", DT_U8, 0, MEMBER(ifinfomsg, ifi_family) },
{ IFLA_UNSPEC, "type", DT_U16, 0, MEMBER(ifinfomsg, ifi_type) },
@@ -735,6 +735,7 @@ static const uc_nl_nested_spec_t link_msg = {
{ IFLA_NUM_RX_QUEUES, "num_rx_queues", DT_U32, 0, NULL },
{ IFLA_AF_SPEC, "af_spec", DT_AFSPEC, 0, NULL },
{ IFLA_LINK_NETNSID, "link_netnsid", DT_U32, 0, NULL },
+ { IFLA_TARGET_NETNSID, "target_netnsid", DT_S32, 0, NULL },
{ IFLA_PROTO_DOWN, "proto_down", DT_BOOL, 0, NULL },
{ IFLA_GROUP, "group", DT_U32, 0, NULL },
{ IFLA_LINK, "link", DT_NETDEV, 0, NULL },