2013-10-17 01:09:24 +02:00
|
|
|
/****************************************************************************
|
|
|
|
****************************************************************************
|
|
|
|
***
|
|
|
|
*** This header was automatically generated from a Linux kernel header
|
|
|
|
*** of the same name, to make information necessary for userspace to
|
|
|
|
*** call into the kernel available to libc. It contains only constants,
|
|
|
|
*** structures, and macros generated from the original header, and thus,
|
|
|
|
*** contains no copyrightable information.
|
|
|
|
***
|
|
|
|
*** To edit the content of this header, modify the corresponding
|
|
|
|
*** source file (e.g. under external/kernel-headers/original/) then
|
|
|
|
*** run bionic/libc/kernel/tools/update_all.py
|
|
|
|
***
|
|
|
|
*** Any manual change here will be lost the next time this script will
|
|
|
|
*** be run. You've been warned!
|
|
|
|
***
|
|
|
|
****************************************************************************
|
|
|
|
****************************************************************************/
|
|
|
|
#ifndef _UAPI__LINUX_RTNETLINK_H
|
|
|
|
#define _UAPI__LINUX_RTNETLINK_H
|
|
|
|
#include <linux/types.h>
|
|
|
|
#include <linux/netlink.h>
|
|
|
|
#include <linux/if_link.h>
|
|
|
|
#include <linux/if_addr.h>
|
|
|
|
#include <linux/neighbour.h>
|
|
|
|
#define RTNL_FAMILY_IPMR 128
|
|
|
|
#define RTNL_FAMILY_IP6MR 129
|
|
|
|
#define RTNL_FAMILY_MAX 129
|
|
|
|
enum {
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_BASE = 16,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_BASE RTM_BASE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWLINK = 16,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWLINK RTM_NEWLINK
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELLINK,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELLINK RTM_DELLINK
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETLINK,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETLINK RTM_GETLINK
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_SETLINK,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_SETLINK RTM_SETLINK
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWADDR = 20,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWADDR RTM_NEWADDR
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELADDR,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELADDR RTM_DELADDR
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETADDR,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETADDR RTM_GETADDR
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWROUTE = 24,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWROUTE RTM_NEWROUTE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELROUTE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELROUTE RTM_DELROUTE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETROUTE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETROUTE RTM_GETROUTE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWNEIGH = 28,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWNEIGH RTM_NEWNEIGH
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELNEIGH,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELNEIGH RTM_DELNEIGH
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETNEIGH,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETNEIGH RTM_GETNEIGH
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWRULE = 32,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWRULE RTM_NEWRULE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELRULE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELRULE RTM_DELRULE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETRULE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETRULE RTM_GETRULE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWQDISC = 36,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWQDISC RTM_NEWQDISC
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELQDISC,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELQDISC RTM_DELQDISC
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETQDISC,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETQDISC RTM_GETQDISC
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWTCLASS = 40,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWTCLASS RTM_NEWTCLASS
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELTCLASS,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELTCLASS RTM_DELTCLASS
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETTCLASS,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETTCLASS RTM_GETTCLASS
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWTFILTER = 44,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWTFILTER RTM_NEWTFILTER
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELTFILTER,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELTFILTER RTM_DELTFILTER
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETTFILTER,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETTFILTER RTM_GETTFILTER
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWACTION = 48,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWACTION RTM_NEWACTION
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELACTION,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELACTION RTM_DELACTION
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETACTION,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETACTION RTM_GETACTION
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWPREFIX = 52,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWPREFIX RTM_NEWPREFIX
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETMULTICAST = 58,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETMULTICAST RTM_GETMULTICAST
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETANYCAST = 62,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETANYCAST RTM_GETANYCAST
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWNEIGHTBL = 64,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWNEIGHTBL RTM_NEWNEIGHTBL
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETNEIGHTBL = 66,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETNEIGHTBL RTM_GETNEIGHTBL
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_SETNEIGHTBL,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_SETNEIGHTBL RTM_SETNEIGHTBL
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWNDUSEROPT = 68,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWNDUSEROPT RTM_NEWNDUSEROPT
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWADDRLABEL = 72,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWADDRLABEL RTM_NEWADDRLABEL
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELADDRLABEL,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELADDRLABEL RTM_DELADDRLABEL
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETADDRLABEL,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETADDRLABEL RTM_GETADDRLABEL
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETDCB = 78,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETDCB RTM_GETDCB
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_SETDCB,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_SETDCB RTM_SETDCB
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWNETCONF = 80,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWNETCONF RTM_NEWNETCONF
|
2017-07-26 22:12:53 +02:00
|
|
|
RTM_DELNETCONF,
|
|
|
|
#define RTM_DELNETCONF RTM_DELNETCONF
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETNETCONF = 82,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETNETCONF RTM_GETNETCONF
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_NEWMDB = 84,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_NEWMDB RTM_NEWMDB
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_DELMDB = 85,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_DELMDB RTM_DELMDB
|
2015-01-28 19:07:51 +01:00
|
|
|
RTM_GETMDB = 86,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_GETMDB RTM_GETMDB
|
2016-02-04 22:16:38 +01:00
|
|
|
RTM_NEWNSID = 88,
|
|
|
|
#define RTM_NEWNSID RTM_NEWNSID
|
|
|
|
RTM_DELNSID = 89,
|
|
|
|
#define RTM_DELNSID RTM_DELNSID
|
|
|
|
RTM_GETNSID = 90,
|
|
|
|
#define RTM_GETNSID RTM_GETNSID
|
2016-08-24 21:15:38 +02:00
|
|
|
RTM_NEWSTATS = 92,
|
|
|
|
#define RTM_NEWSTATS RTM_NEWSTATS
|
|
|
|
RTM_GETSTATS = 94,
|
|
|
|
#define RTM_GETSTATS RTM_GETSTATS
|
2022-06-08 22:31:52 +02:00
|
|
|
RTM_SETSTATS,
|
|
|
|
#define RTM_SETSTATS RTM_SETSTATS
|
2017-11-15 02:32:13 +01:00
|
|
|
RTM_NEWCACHEREPORT = 96,
|
|
|
|
#define RTM_NEWCACHEREPORT RTM_NEWCACHEREPORT
|
2018-10-25 21:11:39 +02:00
|
|
|
RTM_NEWCHAIN = 100,
|
|
|
|
#define RTM_NEWCHAIN RTM_NEWCHAIN
|
|
|
|
RTM_DELCHAIN,
|
|
|
|
#define RTM_DELCHAIN RTM_DELCHAIN
|
|
|
|
RTM_GETCHAIN,
|
|
|
|
#define RTM_GETCHAIN RTM_GETCHAIN
|
2019-10-03 03:29:20 +02:00
|
|
|
RTM_NEWNEXTHOP = 104,
|
|
|
|
#define RTM_NEWNEXTHOP RTM_NEWNEXTHOP
|
|
|
|
RTM_DELNEXTHOP,
|
|
|
|
#define RTM_DELNEXTHOP RTM_DELNEXTHOP
|
|
|
|
RTM_GETNEXTHOP,
|
|
|
|
#define RTM_GETNEXTHOP RTM_GETNEXTHOP
|
2020-02-05 01:16:51 +01:00
|
|
|
RTM_NEWLINKPROP = 108,
|
|
|
|
#define RTM_NEWLINKPROP RTM_NEWLINKPROP
|
|
|
|
RTM_DELLINKPROP,
|
|
|
|
#define RTM_DELLINKPROP RTM_DELLINKPROP
|
|
|
|
RTM_GETLINKPROP,
|
|
|
|
#define RTM_GETLINKPROP RTM_GETLINKPROP
|
2020-04-06 20:38:04 +02:00
|
|
|
RTM_NEWVLAN = 112,
|
|
|
|
#define RTM_NEWNVLAN RTM_NEWVLAN
|
|
|
|
RTM_DELVLAN,
|
|
|
|
#define RTM_DELVLAN RTM_DELVLAN
|
|
|
|
RTM_GETVLAN,
|
|
|
|
#define RTM_GETVLAN RTM_GETVLAN
|
2021-07-01 03:30:21 +02:00
|
|
|
RTM_NEWNEXTHOPBUCKET = 116,
|
|
|
|
#define RTM_NEWNEXTHOPBUCKET RTM_NEWNEXTHOPBUCKET
|
|
|
|
RTM_DELNEXTHOPBUCKET,
|
|
|
|
#define RTM_DELNEXTHOPBUCKET RTM_DELNEXTHOPBUCKET
|
|
|
|
RTM_GETNEXTHOPBUCKET,
|
|
|
|
#define RTM_GETNEXTHOPBUCKET RTM_GETNEXTHOPBUCKET
|
2022-06-08 22:31:52 +02:00
|
|
|
RTM_NEWTUNNEL = 120,
|
|
|
|
#define RTM_NEWTUNNEL RTM_NEWTUNNEL
|
|
|
|
RTM_DELTUNNEL,
|
|
|
|
#define RTM_DELTUNNEL RTM_DELTUNNEL
|
|
|
|
RTM_GETTUNNEL,
|
|
|
|
#define RTM_GETTUNNEL RTM_GETTUNNEL
|
2016-02-04 22:16:38 +01:00
|
|
|
__RTM_MAX,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTM_MAX (((__RTM_MAX + 3) & ~3) - 1)
|
|
|
|
};
|
|
|
|
#define RTM_NR_MSGTYPES (RTM_MAX + 1 - RTM_BASE)
|
|
|
|
#define RTM_NR_FAMILIES (RTM_NR_MSGTYPES >> 2)
|
|
|
|
#define RTM_FAM(cmd) (((cmd) - RTM_BASE) >> 2)
|
|
|
|
struct rtattr {
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned short rta_len;
|
|
|
|
unsigned short rta_type;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2016-02-04 22:16:38 +01:00
|
|
|
#define RTA_ALIGNTO 4U
|
2015-01-28 19:07:51 +01:00
|
|
|
#define RTA_ALIGN(len) (((len) + RTA_ALIGNTO - 1) & ~(RTA_ALIGNTO - 1))
|
|
|
|
#define RTA_OK(rta,len) ((len) >= (int) sizeof(struct rtattr) && (rta)->rta_len >= sizeof(struct rtattr) && (rta)->rta_len <= (len))
|
|
|
|
#define RTA_NEXT(rta,attrlen) ((attrlen) -= RTA_ALIGN((rta)->rta_len), (struct rtattr *) (((char *) (rta)) + RTA_ALIGN((rta)->rta_len)))
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTA_LENGTH(len) (RTA_ALIGN(sizeof(struct rtattr)) + (len))
|
|
|
|
#define RTA_SPACE(len) RTA_ALIGN(RTA_LENGTH(len))
|
2015-01-28 19:07:51 +01:00
|
|
|
#define RTA_DATA(rta) ((void *) (((char *) (rta)) + RTA_LENGTH(0)))
|
|
|
|
#define RTA_PAYLOAD(rta) ((int) ((rta)->rta_len) - RTA_LENGTH(0))
|
2013-10-17 01:09:24 +02:00
|
|
|
struct rtmsg {
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned char rtm_family;
|
|
|
|
unsigned char rtm_dst_len;
|
|
|
|
unsigned char rtm_src_len;
|
|
|
|
unsigned char rtm_tos;
|
|
|
|
unsigned char rtm_table;
|
|
|
|
unsigned char rtm_protocol;
|
|
|
|
unsigned char rtm_scope;
|
|
|
|
unsigned char rtm_type;
|
|
|
|
unsigned rtm_flags;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
|
|
|
enum {
|
2015-01-28 19:07:51 +01:00
|
|
|
RTN_UNSPEC,
|
|
|
|
RTN_UNICAST,
|
|
|
|
RTN_LOCAL,
|
|
|
|
RTN_BROADCAST,
|
|
|
|
RTN_ANYCAST,
|
|
|
|
RTN_MULTICAST,
|
|
|
|
RTN_BLACKHOLE,
|
|
|
|
RTN_UNREACHABLE,
|
|
|
|
RTN_PROHIBIT,
|
|
|
|
RTN_THROW,
|
|
|
|
RTN_NAT,
|
|
|
|
RTN_XRESOLVE,
|
|
|
|
__RTN_MAX
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
|
|
|
#define RTN_MAX (__RTN_MAX - 1)
|
|
|
|
#define RTPROT_UNSPEC 0
|
|
|
|
#define RTPROT_REDIRECT 1
|
|
|
|
#define RTPROT_KERNEL 2
|
|
|
|
#define RTPROT_BOOT 3
|
|
|
|
#define RTPROT_STATIC 4
|
|
|
|
#define RTPROT_GATED 8
|
|
|
|
#define RTPROT_RA 9
|
|
|
|
#define RTPROT_MRT 10
|
|
|
|
#define RTPROT_ZEBRA 11
|
|
|
|
#define RTPROT_BIRD 12
|
|
|
|
#define RTPROT_DNROUTED 13
|
|
|
|
#define RTPROT_XORP 14
|
|
|
|
#define RTPROT_NTK 15
|
|
|
|
#define RTPROT_DHCP 16
|
|
|
|
#define RTPROT_MROUTED 17
|
2020-10-15 02:42:58 +02:00
|
|
|
#define RTPROT_KEEPALIVED 18
|
2016-02-04 22:16:38 +01:00
|
|
|
#define RTPROT_BABEL 42
|
2021-07-01 03:30:21 +02:00
|
|
|
#define RTPROT_OPENR 99
|
2018-10-25 21:11:39 +02:00
|
|
|
#define RTPROT_BGP 186
|
|
|
|
#define RTPROT_ISIS 187
|
|
|
|
#define RTPROT_OSPF 188
|
|
|
|
#define RTPROT_RIP 189
|
|
|
|
#define RTPROT_EIGRP 192
|
2013-10-17 01:09:24 +02:00
|
|
|
enum rt_scope_t {
|
2015-01-28 19:07:51 +01:00
|
|
|
RT_SCOPE_UNIVERSE = 0,
|
|
|
|
RT_SCOPE_SITE = 200,
|
|
|
|
RT_SCOPE_LINK = 253,
|
|
|
|
RT_SCOPE_HOST = 254,
|
|
|
|
RT_SCOPE_NOWHERE = 255
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
|
|
|
#define RTM_F_NOTIFY 0x100
|
|
|
|
#define RTM_F_CLONED 0x200
|
|
|
|
#define RTM_F_EQUALIZE 0x400
|
|
|
|
#define RTM_F_PREFIX 0x800
|
2016-02-04 22:16:38 +01:00
|
|
|
#define RTM_F_LOOKUP_TABLE 0x1000
|
2017-11-15 02:32:13 +01:00
|
|
|
#define RTM_F_FIB_MATCH 0x2000
|
2020-04-06 20:38:04 +02:00
|
|
|
#define RTM_F_OFFLOAD 0x4000
|
|
|
|
#define RTM_F_TRAP 0x8000
|
2021-05-03 23:02:49 +02:00
|
|
|
#define RTM_F_OFFLOAD_FAILED 0x20000000
|
2013-10-17 01:09:24 +02:00
|
|
|
enum rt_class_t {
|
2015-01-28 19:07:51 +01:00
|
|
|
RT_TABLE_UNSPEC = 0,
|
|
|
|
RT_TABLE_COMPAT = 252,
|
|
|
|
RT_TABLE_DEFAULT = 253,
|
|
|
|
RT_TABLE_MAIN = 254,
|
|
|
|
RT_TABLE_LOCAL = 255,
|
|
|
|
RT_TABLE_MAX = 0xFFFFFFFF
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
|
|
|
enum rtattr_type_t {
|
2015-01-28 19:07:51 +01:00
|
|
|
RTA_UNSPEC,
|
|
|
|
RTA_DST,
|
|
|
|
RTA_SRC,
|
|
|
|
RTA_IIF,
|
|
|
|
RTA_OIF,
|
|
|
|
RTA_GATEWAY,
|
|
|
|
RTA_PRIORITY,
|
|
|
|
RTA_PREFSRC,
|
|
|
|
RTA_METRICS,
|
|
|
|
RTA_MULTIPATH,
|
|
|
|
RTA_PROTOINFO,
|
|
|
|
RTA_FLOW,
|
|
|
|
RTA_CACHEINFO,
|
|
|
|
RTA_SESSION,
|
|
|
|
RTA_MP_ALGO,
|
|
|
|
RTA_TABLE,
|
|
|
|
RTA_MARK,
|
|
|
|
RTA_MFC_STATS,
|
2016-02-04 22:16:38 +01:00
|
|
|
RTA_VIA,
|
|
|
|
RTA_NEWDST,
|
|
|
|
RTA_PREF,
|
|
|
|
RTA_ENCAP_TYPE,
|
|
|
|
RTA_ENCAP,
|
2016-08-24 21:15:38 +02:00
|
|
|
RTA_EXPIRES,
|
|
|
|
RTA_PAD,
|
2017-02-21 21:35:09 +01:00
|
|
|
RTA_UID,
|
2017-07-26 22:12:53 +02:00
|
|
|
RTA_TTL_PROPAGATE,
|
2018-10-25 21:11:39 +02:00
|
|
|
RTA_IP_PROTO,
|
|
|
|
RTA_SPORT,
|
|
|
|
RTA_DPORT,
|
2019-10-03 03:29:20 +02:00
|
|
|
RTA_NH_ID,
|
2015-01-28 19:07:51 +01:00
|
|
|
__RTA_MAX
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2016-02-04 22:16:38 +01:00
|
|
|
#define RTA_MAX (__RTA_MAX - 1)
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTM_RTA(r) ((struct rtattr *) (((char *) (r)) + NLMSG_ALIGN(sizeof(struct rtmsg))))
|
2015-01-28 19:07:51 +01:00
|
|
|
#define RTM_PAYLOAD(n) NLMSG_PAYLOAD(n, sizeof(struct rtmsg))
|
2013-10-17 01:09:24 +02:00
|
|
|
struct rtnexthop {
|
2016-02-04 22:16:38 +01:00
|
|
|
unsigned short rtnh_len;
|
2017-02-21 21:35:09 +01:00
|
|
|
unsigned char rtnh_flags;
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned char rtnh_hops;
|
|
|
|
int rtnh_ifindex;
|
2016-02-04 22:16:38 +01:00
|
|
|
};
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTNH_F_DEAD 1
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNH_F_PERVASIVE 2
|
|
|
|
#define RTNH_F_ONLINK 4
|
2016-02-04 22:16:38 +01:00
|
|
|
#define RTNH_F_OFFLOAD 8
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTNH_F_LINKDOWN 16
|
2017-07-26 22:12:53 +02:00
|
|
|
#define RTNH_F_UNRESOLVED 32
|
2021-02-17 01:01:34 +01:00
|
|
|
#define RTNH_F_TRAP 64
|
|
|
|
#define RTNH_COMPARE_MASK (RTNH_F_DEAD | RTNH_F_LINKDOWN | RTNH_F_OFFLOAD | RTNH_F_TRAP)
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNH_ALIGNTO 4
|
2015-01-28 19:07:51 +01:00
|
|
|
#define RTNH_ALIGN(len) (((len) + RTNH_ALIGNTO - 1) & ~(RTNH_ALIGNTO - 1))
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTNH_OK(rtnh,len) ((rtnh)->rtnh_len >= sizeof(struct rtnexthop) && ((int) (rtnh)->rtnh_len) <= (len))
|
2015-01-28 19:07:51 +01:00
|
|
|
#define RTNH_NEXT(rtnh) ((struct rtnexthop *) (((char *) (rtnh)) + RTNH_ALIGN((rtnh)->rtnh_len)))
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNH_LENGTH(len) (RTNH_ALIGN(sizeof(struct rtnexthop)) + (len))
|
|
|
|
#define RTNH_SPACE(len) RTNH_ALIGN(RTNH_LENGTH(len))
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTNH_DATA(rtnh) ((struct rtattr *) (((char *) (rtnh)) + RTNH_LENGTH(0)))
|
2016-02-04 22:16:38 +01:00
|
|
|
struct rtvia {
|
|
|
|
__kernel_sa_family_t rtvia_family;
|
2022-10-05 03:24:44 +02:00
|
|
|
__u8 rtvia_addr[];
|
2017-02-21 21:35:09 +01:00
|
|
|
};
|
2013-10-17 01:09:24 +02:00
|
|
|
struct rta_cacheinfo {
|
2015-01-28 19:07:51 +01:00
|
|
|
__u32 rta_clntref;
|
|
|
|
__u32 rta_lastuse;
|
2017-02-21 21:35:09 +01:00
|
|
|
__s32 rta_expires;
|
2015-01-28 19:07:51 +01:00
|
|
|
__u32 rta_error;
|
|
|
|
__u32 rta_used;
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNETLINK_HAVE_PEERINFO 1
|
2017-02-21 21:35:09 +01:00
|
|
|
__u32 rta_id;
|
2015-01-28 19:07:51 +01:00
|
|
|
__u32 rta_ts;
|
|
|
|
__u32 rta_tsage;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2017-02-21 21:35:09 +01:00
|
|
|
enum {
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_UNSPEC,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTAX_UNSPEC RTAX_UNSPEC
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_LOCK,
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTAX_LOCK RTAX_LOCK
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_MTU,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTAX_MTU RTAX_MTU
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_WINDOW,
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTAX_WINDOW RTAX_WINDOW
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_RTT,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTAX_RTT RTAX_RTT
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_RTTVAR,
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTAX_RTTVAR RTAX_RTTVAR
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_SSTHRESH,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTAX_SSTHRESH RTAX_SSTHRESH
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_CWND,
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTAX_CWND RTAX_CWND
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_ADVMSS,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTAX_ADVMSS RTAX_ADVMSS
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_REORDERING,
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTAX_REORDERING RTAX_REORDERING
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_HOPLIMIT,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTAX_HOPLIMIT RTAX_HOPLIMIT
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_INITCWND,
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTAX_INITCWND RTAX_INITCWND
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_FEATURES,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTAX_FEATURES RTAX_FEATURES
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_RTO_MIN,
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTAX_RTO_MIN RTAX_RTO_MIN
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_INITRWND,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTAX_INITRWND RTAX_INITRWND
|
2015-01-28 19:07:51 +01:00
|
|
|
RTAX_QUICKACK,
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTAX_QUICKACK RTAX_QUICKACK
|
2016-02-04 22:16:38 +01:00
|
|
|
RTAX_CC_ALGO,
|
|
|
|
#define RTAX_CC_ALGO RTAX_CC_ALGO
|
2018-02-01 00:29:16 +01:00
|
|
|
RTAX_FASTOPEN_NO_COOKIE,
|
|
|
|
#define RTAX_FASTOPEN_NO_COOKIE RTAX_FASTOPEN_NO_COOKIE
|
2015-01-28 19:07:51 +01:00
|
|
|
__RTAX_MAX
|
2017-02-21 21:35:09 +01:00
|
|
|
};
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTAX_MAX (__RTAX_MAX - 1)
|
2016-02-04 22:16:38 +01:00
|
|
|
#define RTAX_FEATURE_ECN (1 << 0)
|
|
|
|
#define RTAX_FEATURE_SACK (1 << 1)
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTAX_FEATURE_TIMESTAMP (1 << 2)
|
2016-02-04 22:16:38 +01:00
|
|
|
#define RTAX_FEATURE_ALLFRAG (1 << 3)
|
|
|
|
#define RTAX_FEATURE_MASK (RTAX_FEATURE_ECN | RTAX_FEATURE_SACK | RTAX_FEATURE_TIMESTAMP | RTAX_FEATURE_ALLFRAG)
|
2013-10-17 01:09:24 +02:00
|
|
|
struct rta_session {
|
2017-02-21 21:35:09 +01:00
|
|
|
__u8 proto;
|
2015-01-28 19:07:51 +01:00
|
|
|
__u8 pad1;
|
|
|
|
__u16 pad2;
|
|
|
|
union {
|
2017-02-21 21:35:09 +01:00
|
|
|
struct {
|
2015-01-28 19:07:51 +01:00
|
|
|
__u16 sport;
|
|
|
|
__u16 dport;
|
|
|
|
} ports;
|
2017-02-21 21:35:09 +01:00
|
|
|
struct {
|
2015-01-28 19:07:51 +01:00
|
|
|
__u8 type;
|
|
|
|
__u8 code;
|
|
|
|
__u16 ident;
|
2017-02-21 21:35:09 +01:00
|
|
|
} icmpt;
|
2015-01-28 19:07:51 +01:00
|
|
|
__u32 spi;
|
|
|
|
} u;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2017-02-21 21:35:09 +01:00
|
|
|
struct rta_mfc_stats {
|
2015-01-28 19:07:51 +01:00
|
|
|
__u64 mfcs_packets;
|
|
|
|
__u64 mfcs_bytes;
|
|
|
|
__u64 mfcs_wrong_if;
|
2017-02-21 21:35:09 +01:00
|
|
|
};
|
2013-10-17 01:09:24 +02:00
|
|
|
struct rtgenmsg {
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned char rtgen_family;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2017-02-21 21:35:09 +01:00
|
|
|
struct ifinfomsg {
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned char ifi_family;
|
|
|
|
unsigned char __ifi_pad;
|
|
|
|
unsigned short ifi_type;
|
2017-02-21 21:35:09 +01:00
|
|
|
int ifi_index;
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned ifi_flags;
|
|
|
|
unsigned ifi_change;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2017-02-21 21:35:09 +01:00
|
|
|
struct prefixmsg {
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned char prefix_family;
|
|
|
|
unsigned char prefix_pad1;
|
|
|
|
unsigned short prefix_pad2;
|
2017-02-21 21:35:09 +01:00
|
|
|
int prefix_ifindex;
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned char prefix_type;
|
|
|
|
unsigned char prefix_len;
|
|
|
|
unsigned char prefix_flags;
|
2017-02-21 21:35:09 +01:00
|
|
|
unsigned char prefix_pad3;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2015-01-28 19:07:51 +01:00
|
|
|
enum {
|
|
|
|
PREFIX_UNSPEC,
|
2017-02-21 21:35:09 +01:00
|
|
|
PREFIX_ADDRESS,
|
2015-01-28 19:07:51 +01:00
|
|
|
PREFIX_CACHEINFO,
|
|
|
|
__PREFIX_MAX
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2017-02-21 21:35:09 +01:00
|
|
|
#define PREFIX_MAX (__PREFIX_MAX - 1)
|
2013-10-17 01:09:24 +02:00
|
|
|
struct prefix_cacheinfo {
|
2015-01-28 19:07:51 +01:00
|
|
|
__u32 preferred_time;
|
|
|
|
__u32 valid_time;
|
2017-02-21 21:35:09 +01:00
|
|
|
};
|
2013-10-17 01:09:24 +02:00
|
|
|
struct tcmsg {
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned char tcm_family;
|
|
|
|
unsigned char tcm__pad1;
|
2017-02-21 21:35:09 +01:00
|
|
|
unsigned short tcm__pad2;
|
2015-01-28 19:07:51 +01:00
|
|
|
int tcm_ifindex;
|
|
|
|
__u32 tcm_handle;
|
|
|
|
__u32 tcm_parent;
|
2018-06-27 23:12:29 +02:00
|
|
|
#define tcm_block_index tcm_parent
|
2017-02-21 21:35:09 +01:00
|
|
|
__u32 tcm_info;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2018-06-27 23:12:29 +02:00
|
|
|
#define TCM_IFINDEX_MAGIC_BLOCK (0xFFFFFFFFU)
|
2015-01-28 19:07:51 +01:00
|
|
|
enum {
|
|
|
|
TCA_UNSPEC,
|
2017-02-21 21:35:09 +01:00
|
|
|
TCA_KIND,
|
2015-01-28 19:07:51 +01:00
|
|
|
TCA_OPTIONS,
|
|
|
|
TCA_STATS,
|
|
|
|
TCA_XSTATS,
|
2017-02-21 21:35:09 +01:00
|
|
|
TCA_RATE,
|
2015-01-28 19:07:51 +01:00
|
|
|
TCA_FCNT,
|
|
|
|
TCA_STATS2,
|
|
|
|
TCA_STAB,
|
2017-02-21 21:35:09 +01:00
|
|
|
TCA_PAD,
|
2017-07-26 22:12:53 +02:00
|
|
|
TCA_DUMP_INVISIBLE,
|
2017-11-15 02:32:13 +01:00
|
|
|
TCA_CHAIN,
|
2018-02-01 00:29:16 +01:00
|
|
|
TCA_HW_OFFLOAD,
|
2018-06-27 23:12:29 +02:00
|
|
|
TCA_INGRESS_BLOCK,
|
|
|
|
TCA_EGRESS_BLOCK,
|
2020-08-03 20:53:55 +02:00
|
|
|
TCA_DUMP_FLAGS,
|
2015-01-28 19:07:51 +01:00
|
|
|
__TCA_MAX
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2015-01-28 19:07:51 +01:00
|
|
|
#define TCA_MAX (__TCA_MAX - 1)
|
2020-08-03 20:53:55 +02:00
|
|
|
#define TCA_DUMP_FLAGS_TERSE (1 << 0)
|
2017-02-21 21:35:09 +01:00
|
|
|
#define TCA_RTA(r) ((struct rtattr *) (((char *) (r)) + NLMSG_ALIGN(sizeof(struct tcmsg))))
|
2015-01-28 19:07:51 +01:00
|
|
|
#define TCA_PAYLOAD(n) NLMSG_PAYLOAD(n, sizeof(struct tcmsg))
|
2013-10-17 01:09:24 +02:00
|
|
|
struct nduseroptmsg {
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned char nduseropt_family;
|
2017-02-21 21:35:09 +01:00
|
|
|
unsigned char nduseropt_pad1;
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned short nduseropt_opts_len;
|
|
|
|
int nduseropt_ifindex;
|
|
|
|
__u8 nduseropt_icmp_type;
|
2017-02-21 21:35:09 +01:00
|
|
|
__u8 nduseropt_icmp_code;
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned short nduseropt_pad2;
|
|
|
|
unsigned int nduseropt_pad3;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2017-02-21 21:35:09 +01:00
|
|
|
enum {
|
2015-01-28 19:07:51 +01:00
|
|
|
NDUSEROPT_UNSPEC,
|
|
|
|
NDUSEROPT_SRCADDR,
|
|
|
|
__NDUSEROPT_MAX
|
2017-02-21 21:35:09 +01:00
|
|
|
};
|
2013-10-17 01:09:24 +02:00
|
|
|
#define NDUSEROPT_MAX (__NDUSEROPT_MAX - 1)
|
|
|
|
#define RTMGRP_LINK 1
|
|
|
|
#define RTMGRP_NOTIFY 2
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTMGRP_NEIGH 4
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTMGRP_TC 8
|
|
|
|
#define RTMGRP_IPV4_IFADDR 0x10
|
|
|
|
#define RTMGRP_IPV4_MROUTE 0x20
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTMGRP_IPV4_ROUTE 0x40
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTMGRP_IPV4_RULE 0x80
|
|
|
|
#define RTMGRP_IPV6_IFADDR 0x100
|
|
|
|
#define RTMGRP_IPV6_MROUTE 0x200
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTMGRP_IPV6_ROUTE 0x400
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTMGRP_IPV6_IFINFO 0x800
|
|
|
|
#define RTMGRP_DECnet_IFADDR 0x1000
|
|
|
|
#define RTMGRP_DECnet_ROUTE 0x4000
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTMGRP_IPV6_PREFIX 0x20000
|
2013-10-17 01:09:24 +02:00
|
|
|
enum rtnetlink_groups {
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_NONE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_NONE RTNLGRP_NONE
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_LINK,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_LINK RTNLGRP_LINK
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_NOTIFY,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_NOTIFY RTNLGRP_NOTIFY
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_NEIGH,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_NEIGH RTNLGRP_NEIGH
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_TC,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_TC RTNLGRP_TC
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_IPV4_IFADDR,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV4_IFADDR RTNLGRP_IPV4_IFADDR
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_IPV4_MROUTE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV4_MROUTE RTNLGRP_IPV4_MROUTE
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_IPV4_ROUTE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV4_ROUTE RTNLGRP_IPV4_ROUTE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_IPV4_RULE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV4_RULE RTNLGRP_IPV4_RULE
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_IPV6_IFADDR,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV6_IFADDR RTNLGRP_IPV6_IFADDR
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_IPV6_MROUTE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV6_MROUTE RTNLGRP_IPV6_MROUTE
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_IPV6_ROUTE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV6_ROUTE RTNLGRP_IPV6_ROUTE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_IPV6_IFINFO,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV6_IFINFO RTNLGRP_IPV6_IFINFO
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_DECnet_IFADDR,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_DECnet_IFADDR RTNLGRP_DECnet_IFADDR
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_NOP2,
|
|
|
|
RTNLGRP_DECnet_ROUTE,
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTNLGRP_DECnet_ROUTE RTNLGRP_DECnet_ROUTE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_DECnet_RULE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_DECnet_RULE RTNLGRP_DECnet_RULE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_NOP4,
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_IPV6_PREFIX,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV6_PREFIX RTNLGRP_IPV6_PREFIX
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_IPV6_RULE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV6_RULE RTNLGRP_IPV6_RULE
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_ND_USEROPT,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_ND_USEROPT RTNLGRP_ND_USEROPT
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_PHONET_IFADDR,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_PHONET_IFADDR RTNLGRP_PHONET_IFADDR
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_PHONET_ROUTE,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_PHONET_ROUTE RTNLGRP_PHONET_ROUTE
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_DCB,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_DCB RTNLGRP_DCB
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_IPV4_NETCONF,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV4_NETCONF RTNLGRP_IPV4_NETCONF
|
2015-01-28 19:07:51 +01:00
|
|
|
RTNLGRP_IPV6_NETCONF,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_IPV6_NETCONF RTNLGRP_IPV6_NETCONF
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_MDB,
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTNLGRP_MDB RTNLGRP_MDB
|
2016-02-04 22:16:38 +01:00
|
|
|
RTNLGRP_MPLS_ROUTE,
|
|
|
|
#define RTNLGRP_MPLS_ROUTE RTNLGRP_MPLS_ROUTE
|
2017-02-21 21:35:09 +01:00
|
|
|
RTNLGRP_NSID,
|
2016-02-04 22:16:38 +01:00
|
|
|
#define RTNLGRP_NSID RTNLGRP_NSID
|
2017-07-26 22:12:53 +02:00
|
|
|
RTNLGRP_MPLS_NETCONF,
|
|
|
|
#define RTNLGRP_MPLS_NETCONF RTNLGRP_MPLS_NETCONF
|
2017-11-15 02:32:13 +01:00
|
|
|
RTNLGRP_IPV4_MROUTE_R,
|
|
|
|
#define RTNLGRP_IPV4_MROUTE_R RTNLGRP_IPV4_MROUTE_R
|
|
|
|
RTNLGRP_IPV6_MROUTE_R,
|
|
|
|
#define RTNLGRP_IPV6_MROUTE_R RTNLGRP_IPV6_MROUTE_R
|
2019-10-03 03:29:20 +02:00
|
|
|
RTNLGRP_NEXTHOP,
|
|
|
|
#define RTNLGRP_NEXTHOP RTNLGRP_NEXTHOP
|
2020-04-06 20:38:04 +02:00
|
|
|
RTNLGRP_BRVLAN,
|
|
|
|
#define RTNLGRP_BRVLAN RTNLGRP_BRVLAN
|
2022-03-23 00:06:25 +01:00
|
|
|
RTNLGRP_MCTP_IFADDR,
|
|
|
|
#define RTNLGRP_MCTP_IFADDR RTNLGRP_MCTP_IFADDR
|
2022-06-08 22:31:52 +02:00
|
|
|
RTNLGRP_TUNNEL,
|
|
|
|
#define RTNLGRP_TUNNEL RTNLGRP_TUNNEL
|
|
|
|
RTNLGRP_STATS,
|
|
|
|
#define RTNLGRP_STATS RTNLGRP_STATS
|
2016-02-04 22:16:38 +01:00
|
|
|
__RTNLGRP_MAX
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTNLGRP_MAX (__RTNLGRP_MAX - 1)
|
2013-10-17 01:09:24 +02:00
|
|
|
struct tcamsg {
|
2015-01-28 19:07:51 +01:00
|
|
|
unsigned char tca_family;
|
|
|
|
unsigned char tca__pad1;
|
2017-02-21 21:35:09 +01:00
|
|
|
unsigned short tca__pad2;
|
2013-10-17 01:09:24 +02:00
|
|
|
};
|
2017-11-15 02:32:13 +01:00
|
|
|
enum {
|
|
|
|
TCA_ROOT_UNSPEC,
|
|
|
|
TCA_ROOT_TAB,
|
|
|
|
#define TCA_ACT_TAB TCA_ROOT_TAB
|
|
|
|
#define TCAA_MAX TCA_ROOT_TAB
|
|
|
|
TCA_ROOT_FLAGS,
|
|
|
|
TCA_ROOT_COUNT,
|
|
|
|
TCA_ROOT_TIME_DELTA,
|
|
|
|
__TCA_ROOT_MAX,
|
|
|
|
#define TCA_ROOT_MAX (__TCA_ROOT_MAX - 1)
|
|
|
|
};
|
2015-01-28 19:07:51 +01:00
|
|
|
#define TA_RTA(r) ((struct rtattr *) (((char *) (r)) + NLMSG_ALIGN(sizeof(struct tcamsg))))
|
|
|
|
#define TA_PAYLOAD(n) NLMSG_PAYLOAD(n, sizeof(struct tcamsg))
|
2017-11-15 02:32:13 +01:00
|
|
|
#define TCA_FLAG_LARGE_DUMP_ON (1 << 0)
|
2021-02-17 01:01:34 +01:00
|
|
|
#define TCA_ACT_FLAG_LARGE_DUMP_ON TCA_FLAG_LARGE_DUMP_ON
|
|
|
|
#define TCA_ACT_FLAG_TERSE_DUMP (1 << 1)
|
2013-10-17 01:09:24 +02:00
|
|
|
#define RTEXT_FILTER_VF (1 << 0)
|
|
|
|
#define RTEXT_FILTER_BRVLAN (1 << 1)
|
2017-02-21 21:35:09 +01:00
|
|
|
#define RTEXT_FILTER_BRVLAN_COMPRESSED (1 << 2)
|
2016-02-04 22:16:38 +01:00
|
|
|
#define RTEXT_FILTER_SKIP_STATS (1 << 3)
|
2020-10-15 02:42:58 +02:00
|
|
|
#define RTEXT_FILTER_MRP (1 << 4)
|
2021-02-17 01:01:34 +01:00
|
|
|
#define RTEXT_FILTER_CFM_CONFIG (1 << 5)
|
|
|
|
#define RTEXT_FILTER_CFM_STATUS (1 << 6)
|
2022-06-08 22:31:52 +02:00
|
|
|
#define RTEXT_FILTER_MST (1 << 7)
|
2013-10-17 01:09:24 +02:00
|
|
|
#endif
|