History

Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next

Pull networking updates from David Miller: 1) The addition of nftables. No longer will we need protocol aware firewall filtering modules, it can all live in userspace. At the core of nftables is a, for lack of a better term, virtual machine that executes byte codes to inspect packet or metadata (arriving interface index, etc.) and make verdict decisions. Besides support for loading packet contents and comparing them, the interpreter supports lookups in various datastructures as fundamental operations. For example sets are supports, and therefore one could create a set of whitelist IP address entries which have ACCEPT verdicts attached to them, and use the appropriate byte codes to do such lookups. Since the interpreted code is composed in userspace, userspace can do things like optimize things before giving it to the kernel. Another major improvement is the capability of atomically updating portions of the ruleset. In the existing netfilter implementation, one has to update the entire rule set in order to make a change and this is very expensive. Userspace tools exist to create nftables rules using existing netfilter rule sets, but both kernel implementations will need to co-exist for quite some time as we transition from the old to the new stuff. Kudos to Patrick McHardy, Pablo Neira Ayuso, and others who have worked so hard on this. 2) Daniel Borkmann and Hannes Frederic Sowa made several improvements to our pseudo-random number generator, mostly used for things like UDP port randomization and netfitler, amongst other things. In particular the taus88 generater is updated to taus113, and test cases are added. 3) Support 64-bit rates in HTB and TBF schedulers, from Eric Dumazet and Yang Yingliang. 4) Add support for new 577xx tigon3 chips to tg3 driver, from Nithin Sujir. 5) Fix two fatal flaws in TCP dynamic right sizing, from Eric Dumazet, Neal Cardwell, and Yuchung Cheng. 6) Allow IP_TOS and IP_TTL to be specified in sendmsg() ancillary control message data, much like other socket option attributes. From Francesco Fusco. 7) Allow applications to specify a cap on the rate computed automatically by the kernel for pacing flows, via a new SO_MAX_PACING_RATE socket option. From Eric Dumazet. 8) Make the initial autotuned send buffer sizing in TCP more closely reflect actual needs, from Eric Dumazet. 9) Currently early socket demux only happens for TCP sockets, but we can do it for connected UDP sockets too. Implementation from Shawn Bohrer. 10) Refactor inet socket demux with the goal of improving hash demux performance for listening sockets. With the main goals being able to use RCU lookups on even request sockets, and eliminating the listening lock contention. From Eric Dumazet. 11) The bonding layer has many demuxes in it's fast path, and an RCU conversion was started back in 3.11, several changes here extend the RCU usage to even more locations. From Ding Tianhong and Wang Yufen, based upon suggestions by Nikolay Aleksandrov and Veaceslav Falico. 12) Allow stackability of segmentation offloads to, in particular, allow segmentation offloading over tunnels. From Eric Dumazet. 13) Significantly improve the handling of secret keys we input into the various hash functions in the inet hashtables, TCP fast open, as well as syncookies. From Hannes Frederic Sowa. The key fundamental operation is "net_get_random_once()" which uses static keys. Hannes even extended this to ipv4/ipv6 fragmentation handling and our generic flow dissector. 14) The generic driver layer takes care now to set the driver data to NULL on device removal, so it's no longer necessary for drivers to explicitly set it to NULL any more. Many drivers have been cleaned up in this way, from Jingoo Han. 15) Add a BPF based packet scheduler classifier, from Daniel Borkmann. 16) Improve CRC32 interfaces and generic SKB checksum iterators so that SCTP's checksumming can more cleanly be handled. Also from Daniel Borkmann. 17) Add a new PMTU discovery mode, IP_PMTUDISC_INTERFACE, which forces using the interface MTU value. This helps avoid PMTU attacks, particularly on DNS servers. From Hannes Frederic Sowa. 18) Use generic XPS for transmit queue steering rather than internal (re-)implementation in virtio-net. From Jason Wang. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1622 commits) random32: add test cases for taus113 implementation random32: upgrade taus88 generator to taus113 from errata paper random32: move rnd_state to linux/random.h random32: add prandom_reseed_late() and call when nonblocking pool becomes initialized random32: add periodic reseeding random32: fix off-by-one in seeding requirement PHY: Add RTL8201CP phy_driver to realtek xtsonic: add missing platform_set_drvdata() in xtsonic_probe() macmace: add missing platform_set_drvdata() in mace_probe() ethernet/arc/arc_emac: add missing platform_set_drvdata() in arc_emac_probe() ipv6: protect for_each_sk_fl_rcu in mem_check with rcu_read_lock_bh vlan: Implement vlan_dev_get_egress_qos_mask as an inline. ixgbe: add warning when max_vfs is out of range. igb: Update link modes display in ethtool netfilter: push reasm skb through instead of original frag skbs ip6_output: fragment outgoing reassembled skb properly MAINTAINERS: mv643xx_eth: take over maintainership from Lennart net_sched: tbf: support of 64bit rates ixgbe: deleting dfwd stations out of order can cause null ptr deref ixgbe: fix build err, num_rx_queues is only available with CONFIG_RPS ...

Linus Torvalds committed 13 years ago

Commit 42a2d922 parents 5cbb3d2 75ecab11331 files · +78932 −32379Browse files

Showing the changes to include/uapi/linux (25 of 1331 files). Show all

Unified · Split

25 files
  1. include/uapi/linux/can/bcm.h +32 −0
  2. include/uapi/linux/can/error.h +32 −0
  3. include/uapi/linux/can/gw.h +32 −0
  4. include/uapi/linux/can/netlink.h +8 −0
  5. include/uapi/linux/can/raw.h +32 −0
  6. include/uapi/linux/hsr_netlink.h +50 −0
  7. include/uapi/linux/if.h +1 −0
  8. include/uapi/linux/if_bonding.h +2 −0
  9. include/uapi/linux/if_ether.h +1 −0
  10. include/uapi/linux/if_link.h +24 −0
  11. include/uapi/linux/in.h +5 −0
  12. include/uapi/linux/ip_vs.h +1 −1
  13. include/uapi/linux/netfilter/Kbuild +2 −0
  14. include/uapi/linux/netfilter/ipset/ip_set.h +15 −1
  15. include/uapi/linux/netfilter/nf_conntrack_common.h +4 −0
  16. include/uapi/linux/netfilter/nf_tables.h +718 −0
  17. include/uapi/linux/netfilter/nf_tables_compat.h +38 −0
  18. include/uapi/linux/netfilter/nfnetlink.h +9 −1
  19. include/uapi/linux/netfilter/nfnetlink_cttimeout.h +2 −0
  20. include/uapi/linux/nfc.h +4 −0
  21. include/uapi/linux/nl80211.h +22 −5
  22. include/uapi/linux/openvswitch.h +15 −3
  23. include/uapi/linux/pkt_cls.h +14 −0
  24. include/uapi/linux/pkt_sched.h +4 −0
  25. include/uapi/linux/random.h +0 −7
include/uapi/linux/can/bcm.h+32−0
@@ -7,6 +7,38 @@ · 6 unmodified lines
77 * Copyright (c) 2002-2007 Volkswagen Group Electronic Research
88 * All rights reserved.
99 *
10+ * Redistribution and use in source and binary forms, with or without
11+ * modification, are permitted provided that the following conditions
12+ * are met:
13+ * 1. Redistributions of source code must retain the above copyright
14+ * notice, this list of conditions and the following disclaimer.
15+ * 2. Redistributions in binary form must reproduce the above copyright
16+ * notice, this list of conditions and the following disclaimer in the
17+ * documentation and/or other materials provided with the distribution.
18+ * 3. Neither the name of Volkswagen nor the names of its contributors
19+ * may be used to endorse or promote products derived from this software
20+ * without specific prior written permission.
21+ *
22+ * Alternatively, provided that this notice is retained in full, this
23+ * software may be distributed under the terms of the GNU General
24+ * Public License ("GPL") version 2, in which case the provisions of the
25+ * GPL apply INSTEAD OF those given above.
26+ *
27+ * The provided data structures and external interfaces from this code
28+ * are not restricted to be used by modules with a GPL compatible license.
29+ *
30+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
31+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
32+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
33+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
34+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
35+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
36+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
37+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
38+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
39+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
40+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
41+ * DAMAGE.
1042 */
1143
1244 #ifndef CAN_BCM_H
include/uapi/linux/can/error.h+32−0
@@ -7,6 +7,38 @@ · 6 unmodified lines
77 * Copyright (c) 2002-2007 Volkswagen Group Electronic Research
88 * All rights reserved.
99 *
10+ * Redistribution and use in source and binary forms, with or without
11+ * modification, are permitted provided that the following conditions
12+ * are met:
13+ * 1. Redistributions of source code must retain the above copyright
14+ * notice, this list of conditions and the following disclaimer.
15+ * 2. Redistributions in binary form must reproduce the above copyright
16+ * notice, this list of conditions and the following disclaimer in the
17+ * documentation and/or other materials provided with the distribution.
18+ * 3. Neither the name of Volkswagen nor the names of its contributors
19+ * may be used to endorse or promote products derived from this software
20+ * without specific prior written permission.
21+ *
22+ * Alternatively, provided that this notice is retained in full, this
23+ * software may be distributed under the terms of the GNU General
24+ * Public License ("GPL") version 2, in which case the provisions of the
25+ * GPL apply INSTEAD OF those given above.
26+ *
27+ * The provided data structures and external interfaces from this code
28+ * are not restricted to be used by modules with a GPL compatible license.
29+ *
30+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
31+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
32+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
33+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
34+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
35+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
36+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
37+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
38+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
39+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
40+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
41+ * DAMAGE.
1042 */
1143
1244 #ifndef CAN_ERROR_H
include/uapi/linux/can/gw.h+32−0
@@ -7,6 +7,38 @@ · 6 unmodified lines
77 * Copyright (c) 2011 Volkswagen Group Electronic Research
88 * All rights reserved.
99 *
10+ * Redistribution and use in source and binary forms, with or without
11+ * modification, are permitted provided that the following conditions
12+ * are met:
13+ * 1. Redistributions of source code must retain the above copyright
14+ * notice, this list of conditions and the following disclaimer.
15+ * 2. Redistributions in binary form must reproduce the above copyright
16+ * notice, this list of conditions and the following disclaimer in the
17+ * documentation and/or other materials provided with the distribution.
18+ * 3. Neither the name of Volkswagen nor the names of its contributors
19+ * may be used to endorse or promote products derived from this software
20+ * without specific prior written permission.
21+ *
22+ * Alternatively, provided that this notice is retained in full, this
23+ * software may be distributed under the terms of the GNU General
24+ * Public License ("GPL") version 2, in which case the provisions of the
25+ * GPL apply INSTEAD OF those given above.
26+ *
27+ * The provided data structures and external interfaces from this code
28+ * are not restricted to be used by modules with a GPL compatible license.
29+ *
30+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
31+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
32+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
33+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
34+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
35+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
36+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
37+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
38+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
39+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
40+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
41+ * DAMAGE.
1042 */
1143
1244 #ifndef CAN_GW_H
include/uapi/linux/can/netlink.h+8−0
@@ -5,6 +5,14 @@ · 4 unmodified lines
55 *
66 * Copyright (c) 2009 Wolfgang Grandegger <wg@grandegger.com>
77 *
8+ * This program is free software; you can redistribute it and/or modify
9+ * it under the terms of the version 2 of the GNU General Public License
10+ * as published by the Free Software Foundation
11+ *
12+ * This program is distributed in the hope that it will be useful,
13+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
14+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15+ * GNU General Public License for more details.
816 */
917
1018 #ifndef CAN_NETLINK_H
include/uapi/linux/can/raw.h+32−0
@@ -8,6 +8,38 @@ · 7 unmodified lines
88 * Copyright (c) 2002-2007 Volkswagen Group Electronic Research
99 * All rights reserved.
1010 *
11+ * Redistribution and use in source and binary forms, with or without
12+ * modification, are permitted provided that the following conditions
13+ * are met:
14+ * 1. Redistributions of source code must retain the above copyright
15+ * notice, this list of conditions and the following disclaimer.
16+ * 2. Redistributions in binary form must reproduce the above copyright
17+ * notice, this list of conditions and the following disclaimer in the
18+ * documentation and/or other materials provided with the distribution.
19+ * 3. Neither the name of Volkswagen nor the names of its contributors
20+ * may be used to endorse or promote products derived from this software
21+ * without specific prior written permission.
22+ *
23+ * Alternatively, provided that this notice is retained in full, this
24+ * software may be distributed under the terms of the GNU General
25+ * Public License ("GPL") version 2, in which case the provisions of the
26+ * GPL apply INSTEAD OF those given above.
27+ *
28+ * The provided data structures and external interfaces from this code
29+ * are not restricted to be used by modules with a GPL compatible license.
30+ *
31+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
32+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
33+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
34+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
35+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
36+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
37+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
38+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
39+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
40+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
41+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
42+ * DAMAGE.
1143 */
1244
1345 #ifndef CAN_RAW_H
include/uapi/linux/hsr_netlink.h+50−0
@@ -0,0 +1,50 @@
1+/*
2+ * Copyright 2011-2013 Autronica Fire and Security AS
3+ *
4+ * This program is free software; you can redistribute it and/or modify it
5+ * under the terms of the GNU General Public License as published by the Free
6+ * Software Foundation; either version 2 of the License, or (at your option)
7+ * any later version.
8+ *
9+ * Author(s):
10+ * 2011-2013 Arvid Brodin, arvid.brodin@xdin.com
11+ */
12+
13+#ifndef __UAPI_HSR_NETLINK_H
14+#define __UAPI_HSR_NETLINK_H
15+
16+/* Generic Netlink HSR family definition
17+ */
18+
19+/* attributes */
20+enum {
21+ HSR_A_UNSPEC,
22+ HSR_A_NODE_ADDR,
23+ HSR_A_IFINDEX,
24+ HSR_A_IF1_AGE,
25+ HSR_A_IF2_AGE,
26+ HSR_A_NODE_ADDR_B,
27+ HSR_A_IF1_SEQ,
28+ HSR_A_IF2_SEQ,
29+ HSR_A_IF1_IFINDEX,
30+ HSR_A_IF2_IFINDEX,
31+ HSR_A_ADDR_B_IFINDEX,
32+ __HSR_A_MAX,
33+};
34+#define HSR_A_MAX (__HSR_A_MAX - 1)
35+
36+
37+/* commands */
38+enum {
39+ HSR_C_UNSPEC,
40+ HSR_C_RING_ERROR,
41+ HSR_C_NODE_DOWN,
42+ HSR_C_GET_NODE_STATUS,
43+ HSR_C_SET_NODE_STATUS,
44+ HSR_C_GET_NODE_LIST,
45+ HSR_C_SET_NODE_LIST,
46+ __HSR_C_MAX,
47+};
48+#define HSR_C_MAX (__HSR_C_MAX - 1)
49+
50+#endif /* __UAPI_HSR_NETLINK_H */
include/uapi/linux/if.h+1−0
@@ -83,6 +83,7 @@ · 82 unmodified lines
8383 #define IFF_SUPP_NOFCS 0x80000 /* device supports sending custom FCS */
8484 #define IFF_LIVE_ADDR_CHANGE 0x100000 /* device supports hardware address
8585 * change when it's running */
86+#define IFF_MACVLAN 0x200000 /* Macvlan device */
8687
8788
8889 #define IF_GET_IFACE 0x0001 /* for querying only */
include/uapi/linux/if_bonding.h+2−0
@@ -91,6 +91,8 @@ · 90 unmodified lines
9191 #define BOND_XMIT_POLICY_LAYER2 0 /* layer 2 (MAC only), default */
9292 #define BOND_XMIT_POLICY_LAYER34 1 /* layer 3+4 (IP ^ (TCP || UDP)) */
9393 #define BOND_XMIT_POLICY_LAYER23 2 /* layer 2+3 (IP ^ MAC) */
94+#define BOND_XMIT_POLICY_ENCAP23 3 /* encapsulated layer 2+3 */
95+#define BOND_XMIT_POLICY_ENCAP34 4 /* encapsulated layer 3+4 */
9496
9597 typedef struct ifbond {
9698 __s32 bond_mode;
include/uapi/linux/if_ether.h+1−0
@@ -85,6 +85,7 @@ · 84 unmodified lines
8585 #define ETH_P_8021AH 0x88E7 /* 802.1ah Backbone Service Tag */
8686 #define ETH_P_MVRP 0x88F5 /* 802.1Q MVRP */
8787 #define ETH_P_1588 0x88F7 /* IEEE 1588 Timesync */
88+#define ETH_P_PRP 0x88FB /* IEC 62439-3 PRP/HSRv0 */
8889 #define ETH_P_FCOE 0x8906 /* Fibre Channel over Ethernet */
8990 #define ETH_P_TDLS 0x890D /* TDLS */
9091 #define ETH_P_FIP 0x8914 /* FCoE Initialization Protocol */
include/uapi/linux/if_link.h+24−0
@@ -325,6 +325,17 @@ struct ifla_vxlan_port_range { · 324 unmodified lines
325325 __be16 high;
326326 };
327327
328+/* Bonding section */
329+
330+enum {
331+ IFLA_BOND_UNSPEC,
332+ IFLA_BOND_MODE,
333+ IFLA_BOND_ACTIVE_SLAVE,
334+ __IFLA_BOND_MAX,
335+};
336+
337+#define IFLA_BOND_MAX (__IFLA_BOND_MAX - 1)
338+
328339 /* SR-IOV virtual function management section */
329340
330341 enum {
@@ -470,4 +481,17 @@ enum { · 139 unmodified lines
470481
471482 #define IFLA_IPOIB_MAX (__IFLA_IPOIB_MAX - 1)
472483
484+
485+/* HSR section */
486+
487+enum {
488+ IFLA_HSR_UNSPEC,
489+ IFLA_HSR_SLAVE1,
490+ IFLA_HSR_SLAVE2,
491+ IFLA_HSR_MULTICAST_SPEC,
492+ __IFLA_HSR_MAX,
493+};
494+
495+#define IFLA_HSR_MAX (__IFLA_HSR_MAX - 1)
496+
473497 #endif /* _UAPI_LINUX_IF_LINK_H */
include/uapi/linux/in.h+5−0
@@ -115,6 +115,11 @@ struct in_addr { · 114 unmodified lines
115115 #define IP_PMTUDISC_WANT 1 /* Use per route hints */
116116 #define IP_PMTUDISC_DO 2 /* Always DF */
117117 #define IP_PMTUDISC_PROBE 3 /* Ignore dst pmtu */
118+/* Always use interface mtu (ignores dst pmtu) but don't set DF flag.
119+ * Also incoming ICMP frag_needed notifications will be ignored on
120+ * this socket to prevent accepting spoofed ones.
121+ */
122+#define IP_PMTUDISC_INTERFACE 4
118123
119124 #define IP_MULTICAST_IF 32
120125 #define IP_MULTICAST_TTL 33
include/uapi/linux/ip_vs.h+1−1
@@ -334,7 +334,7 @@ enum { · 333 unmodified lines
334334 __IPVS_CMD_ATTR_MAX,
335335 };
336336
337−#define IPVS_CMD_ATTR_MAX (__IPVS_SVC_ATTR_MAX - 1)
337+#define IPVS_CMD_ATTR_MAX (__IPVS_CMD_ATTR_MAX - 1)
338338
339339 /*
340340 * Attributes used to describe a service
include/uapi/linux/netfilter/Kbuild+2−0
@@ -5,6 +5,8 @@ header-y += nf_conntrack_ftp.h · 4 unmodified lines
55 header-y += nf_conntrack_sctp.h
66 header-y += nf_conntrack_tcp.h
77 header-y += nf_conntrack_tuple_common.h
8+header-y += nf_tables.h
9+header-y += nf_tables_compat.h
810 header-y += nf_nat.h
911 header-y += nfnetlink.h
1012 header-y += nfnetlink_acct.h
include/uapi/linux/netfilter/ipset/ip_set.h+15−1
@@ -10,12 +10,14 @@ · 9 unmodified lines
1010 #ifndef _UAPI_IP_SET_H
1111 #define _UAPI_IP_SET_H
1212
13−
1413 #include <linux/types.h>
1514
1615 /* The protocol version */
1716 #define IPSET_PROTOCOL 6
1817
18+/* The maximum permissible comment length we will accept over netlink */
19+#define IPSET_MAX_COMMENT_SIZE 255
20+
1921 /* The max length of strings including NUL: set and type identifiers */
2022 #define IPSET_MAXNAMELEN 32
2123
@@ -110,6 +112,7 @@ enum { · 88 unmodified lines
110112 IPSET_ATTR_IFACE,
111113 IPSET_ATTR_BYTES,
112114 IPSET_ATTR_PACKETS,
115+ IPSET_ATTR_COMMENT,
113116 __IPSET_ATTR_ADT_MAX,
114117 };
115118 #define IPSET_ATTR_ADT_MAX (__IPSET_ATTR_ADT_MAX - 1)
@@ -140,6 +143,7 @@ enum ipset_errno { · 24 unmodified lines
140143 IPSET_ERR_IPADDR_IPV4,
141144 IPSET_ERR_IPADDR_IPV6,
142145 IPSET_ERR_COUNTER,
146+ IPSET_ERR_COMMENT,
143147
144148 /* Type specific error codes */
145149 IPSET_ERR_TYPE_SPECIFIC = 4352,
@@ -176,6 +180,8 @@ enum ipset_cadt_flags { · 30 unmodified lines
176180 IPSET_FLAG_NOMATCH = (1 << IPSET_FLAG_BIT_NOMATCH),
177181 IPSET_FLAG_BIT_WITH_COUNTERS = 3,
178182 IPSET_FLAG_WITH_COUNTERS = (1 << IPSET_FLAG_BIT_WITH_COUNTERS),
183+ IPSET_FLAG_BIT_WITH_COMMENT = 4,
184+ IPSET_FLAG_WITH_COMMENT = (1 << IPSET_FLAG_BIT_WITH_COMMENT),
179185 IPSET_FLAG_CADT_MAX = 15,
180186 };
181187
@@ -250,6 +256,14 @@ struct ip_set_req_get_set { · 68 unmodified lines
250256 #define IP_SET_OP_GET_BYINDEX 0x00000007 /* Get set name by index */
251257 /* Uses ip_set_req_get_set */
252258
259+#define IP_SET_OP_GET_FNAME 0x00000008 /* Get set index and family */
260+struct ip_set_req_get_set_family {
261+ unsigned int op;
262+ unsigned int version;
263+ unsigned int family;
264+ union ip_set_name_index set;
265+};
266+
253267 #define IP_SET_OP_VERSION 0x00000100 /* Ask kernel version */
254268 struct ip_set_req_version {
255269 unsigned int op;
include/uapi/linux/netfilter/nf_conntrack_common.h+4−0
@@ -25,6 +25,10 @@ enum ip_conntrack_info { · 24 unmodified lines
2525 IP_CT_NUMBER = IP_CT_IS_REPLY * 2 - 1
2626 };
2727
28+#define NF_CT_STATE_INVALID_BIT (1 << 0)
29+#define NF_CT_STATE_BIT(ctinfo) (1 << ((ctinfo) % IP_CT_IS_REPLY + 1))
30+#define NF_CT_STATE_UNTRACKED_BIT (1 << (IP_CT_NUMBER + 1))
31+
2832 /* Bitset representing status of connection. */
2933 enum ip_conntrack_status {
3034 /* It's an expected connection: bit 0 set. This bit never changed */
include/uapi/linux/netfilter/nf_tables.h+718−0
@@ -0,0 +1,718 @@
1+#ifndef _LINUX_NF_TABLES_H
2+#define _LINUX_NF_TABLES_H
3+
4+#define NFT_CHAIN_MAXNAMELEN 32
5+
6+enum nft_registers {
7+ NFT_REG_VERDICT,
8+ NFT_REG_1,
9+ NFT_REG_2,
10+ NFT_REG_3,
11+ NFT_REG_4,
12+ __NFT_REG_MAX
13+};
14+#define NFT_REG_MAX (__NFT_REG_MAX - 1)
15+
16+/**
17+ * enum nft_verdicts - nf_tables internal verdicts
18+ *
19+ * @NFT_CONTINUE: continue evaluation of the current rule
20+ * @NFT_BREAK: terminate evaluation of the current rule
21+ * @NFT_JUMP: push the current chain on the jump stack and jump to a chain
22+ * @NFT_GOTO: jump to a chain without pushing the current chain on the jump stack
23+ * @NFT_RETURN: return to the topmost chain on the jump stack
24+ *
25+ * The nf_tables verdicts share their numeric space with the netfilter verdicts.
26+ */
27+enum nft_verdicts {
28+ NFT_CONTINUE = -1,
29+ NFT_BREAK = -2,
30+ NFT_JUMP = -3,
31+ NFT_GOTO = -4,
32+ NFT_RETURN = -5,
33+};
34+
35+/**
36+ * enum nf_tables_msg_types - nf_tables netlink message types
37+ *
38+ * @NFT_MSG_NEWTABLE: create a new table (enum nft_table_attributes)
39+ * @NFT_MSG_GETTABLE: get a table (enum nft_table_attributes)
40+ * @NFT_MSG_DELTABLE: delete a table (enum nft_table_attributes)
41+ * @NFT_MSG_NEWCHAIN: create a new chain (enum nft_chain_attributes)
42+ * @NFT_MSG_GETCHAIN: get a chain (enum nft_chain_attributes)
43+ * @NFT_MSG_DELCHAIN: delete a chain (enum nft_chain_attributes)
44+ * @NFT_MSG_NEWRULE: create a new rule (enum nft_rule_attributes)
45+ * @NFT_MSG_GETRULE: get a rule (enum nft_rule_attributes)
46+ * @NFT_MSG_DELRULE: delete a rule (enum nft_rule_attributes)
47+ * @NFT_MSG_NEWSET: create a new set (enum nft_set_attributes)
48+ * @NFT_MSG_GETSET: get a set (enum nft_set_attributes)
49+ * @NFT_MSG_DELSET: delete a set (enum nft_set_attributes)
50+ * @NFT_MSG_NEWSETELEM: create a new set element (enum nft_set_elem_attributes)
51+ * @NFT_MSG_GETSETELEM: get a set element (enum nft_set_elem_attributes)
52+ * @NFT_MSG_DELSETELEM: delete a set element (enum nft_set_elem_attributes)
53+ */
54+enum nf_tables_msg_types {
55+ NFT_MSG_NEWTABLE,
56+ NFT_MSG_GETTABLE,
57+ NFT_MSG_DELTABLE,
58+ NFT_MSG_NEWCHAIN,
59+ NFT_MSG_GETCHAIN,
60+ NFT_MSG_DELCHAIN,
61+ NFT_MSG_NEWRULE,
62+ NFT_MSG_GETRULE,
63+ NFT_MSG_DELRULE,
64+ NFT_MSG_NEWSET,
65+ NFT_MSG_GETSET,
66+ NFT_MSG_DELSET,
67+ NFT_MSG_NEWSETELEM,
68+ NFT_MSG_GETSETELEM,
69+ NFT_MSG_DELSETELEM,
70+ NFT_MSG_MAX,
71+};
72+
73+/**
74+ * enum nft_list_attributes - nf_tables generic list netlink attributes
75+ *
76+ * @NFTA_LIST_ELEM: list element (NLA_NESTED)
77+ */
78+enum nft_list_attributes {
79+ NFTA_LIST_UNPEC,
80+ NFTA_LIST_ELEM,
81+ __NFTA_LIST_MAX
82+};
83+#define NFTA_LIST_MAX (__NFTA_LIST_MAX - 1)
84+
85+/**
86+ * enum nft_hook_attributes - nf_tables netfilter hook netlink attributes
87+ *
88+ * @NFTA_HOOK_HOOKNUM: netfilter hook number (NLA_U32)
89+ * @NFTA_HOOK_PRIORITY: netfilter hook priority (NLA_U32)
90+ */
91+enum nft_hook_attributes {
92+ NFTA_HOOK_UNSPEC,
93+ NFTA_HOOK_HOOKNUM,
94+ NFTA_HOOK_PRIORITY,
95+ __NFTA_HOOK_MAX
96+};
97+#define NFTA_HOOK_MAX (__NFTA_HOOK_MAX - 1)
98+
99+/**
100+ * enum nft_table_flags - nf_tables table flags
101+ *
102+ * @NFT_TABLE_F_DORMANT: this table is not active
103+ */
104+enum nft_table_flags {
105+ NFT_TABLE_F_DORMANT = 0x1,
106+};
107+
108+/**
109+ * enum nft_table_attributes - nf_tables table netlink attributes
110+ *
111+ * @NFTA_TABLE_NAME: name of the table (NLA_STRING)
112+ * @NFTA_TABLE_FLAGS: bitmask of enum nft_table_flags (NLA_U32)
113+ */
114+enum nft_table_attributes {
115+ NFTA_TABLE_UNSPEC,
116+ NFTA_TABLE_NAME,
117+ NFTA_TABLE_FLAGS,
118+ __NFTA_TABLE_MAX
119+};
120+#define NFTA_TABLE_MAX (__NFTA_TABLE_MAX - 1)
121+
122+/**
123+ * enum nft_chain_attributes - nf_tables chain netlink attributes
124+ *
125+ * @NFTA_CHAIN_TABLE: name of the table containing the chain (NLA_STRING)
126+ * @NFTA_CHAIN_HANDLE: numeric handle of the chain (NLA_U64)
127+ * @NFTA_CHAIN_NAME: name of the chain (NLA_STRING)
128+ * @NFTA_CHAIN_HOOK: hook specification for basechains (NLA_NESTED: nft_hook_attributes)
129+ * @NFTA_CHAIN_POLICY: numeric policy of the chain (NLA_U32)
130+ * @NFTA_CHAIN_USE: number of references to this chain (NLA_U32)
131+ * @NFTA_CHAIN_TYPE: type name of the string (NLA_NUL_STRING)
132+ * @NFTA_CHAIN_COUNTERS: counter specification of the chain (NLA_NESTED: nft_counter_attributes)
133+ */
134+enum nft_chain_attributes {
135+ NFTA_CHAIN_UNSPEC,
136+ NFTA_CHAIN_TABLE,
137+ NFTA_CHAIN_HANDLE,
138+ NFTA_CHAIN_NAME,
139+ NFTA_CHAIN_HOOK,
140+ NFTA_CHAIN_POLICY,
141+ NFTA_CHAIN_USE,
142+ NFTA_CHAIN_TYPE,
143+ NFTA_CHAIN_COUNTERS,
144+ __NFTA_CHAIN_MAX
145+};
146+#define NFTA_CHAIN_MAX (__NFTA_CHAIN_MAX - 1)
147+
148+/**
149+ * enum nft_rule_attributes - nf_tables rule netlink attributes
150+ *
151+ * @NFTA_RULE_TABLE: name of the table containing the rule (NLA_STRING)
152+ * @NFTA_RULE_CHAIN: name of the chain containing the rule (NLA_STRING)
153+ * @NFTA_RULE_HANDLE: numeric handle of the rule (NLA_U64)
154+ * @NFTA_RULE_EXPRESSIONS: list of expressions (NLA_NESTED: nft_expr_attributes)
155+ * @NFTA_RULE_COMPAT: compatibility specifications of the rule (NLA_NESTED: nft_rule_compat_attributes)
156+ * @NFTA_RULE_POSITION: numeric handle of the previous rule (NLA_U64)
157+ */
158+enum nft_rule_attributes {
159+ NFTA_RULE_UNSPEC,
160+ NFTA_RULE_TABLE,
161+ NFTA_RULE_CHAIN,
162+ NFTA_RULE_HANDLE,
163+ NFTA_RULE_EXPRESSIONS,
164+ NFTA_RULE_COMPAT,
165+ NFTA_RULE_POSITION,
166+ __NFTA_RULE_MAX
167+};
168+#define NFTA_RULE_MAX (__NFTA_RULE_MAX - 1)
169+
170+/**
171+ * enum nft_rule_compat_flags - nf_tables rule compat flags
172+ *
173+ * @NFT_RULE_COMPAT_F_INV: invert the check result
174+ */
175+enum nft_rule_compat_flags {
176+ NFT_RULE_COMPAT_F_INV = (1 << 1),
177+ NFT_RULE_COMPAT_F_MASK = NFT_RULE_COMPAT_F_INV,
178+};
179+
180+/**
181+ * enum nft_rule_compat_attributes - nf_tables rule compat attributes
182+ *
183+ * @NFTA_RULE_COMPAT_PROTO: numerice value of handled protocol (NLA_U32)
184+ * @NFTA_RULE_COMPAT_FLAGS: bitmask of enum nft_rule_compat_flags (NLA_U32)
185+ */
186+enum nft_rule_compat_attributes {
187+ NFTA_RULE_COMPAT_UNSPEC,
188+ NFTA_RULE_COMPAT_PROTO,
189+ NFTA_RULE_COMPAT_FLAGS,
190+ __NFTA_RULE_COMPAT_MAX
191+};
192+#define NFTA_RULE_COMPAT_MAX (__NFTA_RULE_COMPAT_MAX - 1)
193+
194+/**
195+ * enum nft_set_flags - nf_tables set flags
196+ *
197+ * @NFT_SET_ANONYMOUS: name allocation, automatic cleanup on unlink
198+ * @NFT_SET_CONSTANT: set contents may not change while bound
199+ * @NFT_SET_INTERVAL: set contains intervals
200+ * @NFT_SET_MAP: set is used as a dictionary
201+ */
202+enum nft_set_flags {
203+ NFT_SET_ANONYMOUS = 0x1,
204+ NFT_SET_CONSTANT = 0x2,
205+ NFT_SET_INTERVAL = 0x4,
206+ NFT_SET_MAP = 0x8,
207+};
208+
209+/**
210+ * enum nft_set_attributes - nf_tables set netlink attributes
211+ *
212+ * @NFTA_SET_TABLE: table name (NLA_STRING)
213+ * @NFTA_SET_NAME: set name (NLA_STRING)
214+ * @NFTA_SET_FLAGS: bitmask of enum nft_set_flags (NLA_U32)
215+ * @NFTA_SET_KEY_TYPE: key data type, informational purpose only (NLA_U32)
216+ * @NFTA_SET_KEY_LEN: key data length (NLA_U32)
217+ * @NFTA_SET_DATA_TYPE: mapping data type (NLA_U32)
218+ * @NFTA_SET_DATA_LEN: mapping data length (NLA_U32)
219+ */
220+enum nft_set_attributes {
221+ NFTA_SET_UNSPEC,
222+ NFTA_SET_TABLE,
223+ NFTA_SET_NAME,
224+ NFTA_SET_FLAGS,
225+ NFTA_SET_KEY_TYPE,
226+ NFTA_SET_KEY_LEN,
227+ NFTA_SET_DATA_TYPE,
228+ NFTA_SET_DATA_LEN,
229+ __NFTA_SET_MAX
230+};
231+#define NFTA_SET_MAX (__NFTA_SET_MAX - 1)
232+
233+/**
234+ * enum nft_set_elem_flags - nf_tables set element flags
235+ *
236+ * @NFT_SET_ELEM_INTERVAL_END: element ends the previous interval
237+ */
238+enum nft_set_elem_flags {
239+ NFT_SET_ELEM_INTERVAL_END = 0x1,
240+};
241+
242+/**
243+ * enum nft_set_elem_attributes - nf_tables set element netlink attributes
244+ *
245+ * @NFTA_SET_ELEM_KEY: key value (NLA_NESTED: nft_data)
246+ * @NFTA_SET_ELEM_DATA: data value of mapping (NLA_NESTED: nft_data_attributes)
247+ * @NFTA_SET_ELEM_FLAGS: bitmask of nft_set_elem_flags (NLA_U32)
248+ */
249+enum nft_set_elem_attributes {
250+ NFTA_SET_ELEM_UNSPEC,
251+ NFTA_SET_ELEM_KEY,
252+ NFTA_SET_ELEM_DATA,
253+ NFTA_SET_ELEM_FLAGS,
254+ __NFTA_SET_ELEM_MAX
255+};
256+#define NFTA_SET_ELEM_MAX (__NFTA_SET_ELEM_MAX - 1)
257+
258+/**
259+ * enum nft_set_elem_list_attributes - nf_tables set element list netlink attributes
260+ *
261+ * @NFTA_SET_ELEM_LIST_TABLE: table of the set to be changed (NLA_STRING)
262+ * @NFTA_SET_ELEM_LIST_SET: name of the set to be changed (NLA_STRING)
263+ * @NFTA_SET_ELEM_LIST_ELEMENTS: list of set elements (NLA_NESTED: nft_set_elem_attributes)
264+ */
265+enum nft_set_elem_list_attributes {
266+ NFTA_SET_ELEM_LIST_UNSPEC,
267+ NFTA_SET_ELEM_LIST_TABLE,
268+ NFTA_SET_ELEM_LIST_SET,
269+ NFTA_SET_ELEM_LIST_ELEMENTS,
270+ __NFTA_SET_ELEM_LIST_MAX
271+};
272+#define NFTA_SET_ELEM_LIST_MAX (__NFTA_SET_ELEM_LIST_MAX - 1)
273+
274+/**
275+ * enum nft_data_types - nf_tables data types
276+ *
277+ * @NFT_DATA_VALUE: generic data
278+ * @NFT_DATA_VERDICT: netfilter verdict
279+ *
280+ * The type of data is usually determined by the kernel directly and is not
281+ * explicitly specified by userspace. The only difference are sets, where
282+ * userspace specifies the key and mapping data types.
283+ *
284+ * The values 0xffffff00-0xffffffff are reserved for internally used types.
285+ * The remaining range can be freely used by userspace to encode types, all
286+ * values are equivalent to NFT_DATA_VALUE.
287+ */
288+enum nft_data_types {
289+ NFT_DATA_VALUE,
290+ NFT_DATA_VERDICT = 0xffffff00U,
291+};
292+
293+#define NFT_DATA_RESERVED_MASK 0xffffff00U
294+
295+/**
296+ * enum nft_data_attributes - nf_tables data netlink attributes
297+ *
298+ * @NFTA_DATA_VALUE: generic data (NLA_BINARY)
299+ * @NFTA_DATA_VERDICT: nf_tables verdict (NLA_NESTED: nft_verdict_attributes)
300+ */
301+enum nft_data_attributes {
302+ NFTA_DATA_UNSPEC,
303+ NFTA_DATA_VALUE,
304+ NFTA_DATA_VERDICT,
305+ __NFTA_DATA_MAX
306+};
307+#define NFTA_DATA_MAX (__NFTA_DATA_MAX - 1)
308+
309+/**
310+ * enum nft_verdict_attributes - nf_tables verdict netlink attributes
311+ *
312+ * @NFTA_VERDICT_CODE: nf_tables verdict (NLA_U32: enum nft_verdicts)
313+ * @NFTA_VERDICT_CHAIN: jump target chain name (NLA_STRING)
314+ */
315+enum nft_verdict_attributes {
316+ NFTA_VERDICT_UNSPEC,
317+ NFTA_VERDICT_CODE,
318+ NFTA_VERDICT_CHAIN,
319+ __NFTA_VERDICT_MAX
320+};
321+#define NFTA_VERDICT_MAX (__NFTA_VERDICT_MAX - 1)
322+
323+/**
324+ * enum nft_expr_attributes - nf_tables expression netlink attributes
325+ *
326+ * @NFTA_EXPR_NAME: name of the expression type (NLA_STRING)
327+ * @NFTA_EXPR_DATA: type specific data (NLA_NESTED)
328+ */
329+enum nft_expr_attributes {
330+ NFTA_EXPR_UNSPEC,
331+ NFTA_EXPR_NAME,
332+ NFTA_EXPR_DATA,
333+ __NFTA_EXPR_MAX
334+};
335+#define NFTA_EXPR_MAX (__NFTA_EXPR_MAX - 1)
336+
337+/**
338+ * enum nft_immediate_attributes - nf_tables immediate expression netlink attributes
339+ *
340+ * @NFTA_IMMEDIATE_DREG: destination register to load data into (NLA_U32)
341+ * @NFTA_IMMEDIATE_DATA: data to load (NLA_NESTED: nft_data_attributes)
342+ */
343+enum nft_immediate_attributes {
344+ NFTA_IMMEDIATE_UNSPEC,
345+ NFTA_IMMEDIATE_DREG,
346+ NFTA_IMMEDIATE_DATA,
347+ __NFTA_IMMEDIATE_MAX
348+};
349+#define NFTA_IMMEDIATE_MAX (__NFTA_IMMEDIATE_MAX - 1)
350+
351+/**
352+ * enum nft_bitwise_attributes - nf_tables bitwise expression netlink attributes
353+ *
354+ * @NFTA_BITWISE_SREG: source register (NLA_U32: nft_registers)
355+ * @NFTA_BITWISE_DREG: destination register (NLA_U32: nft_registers)
356+ * @NFTA_BITWISE_LEN: length of operands (NLA_U32)
357+ * @NFTA_BITWISE_MASK: mask value (NLA_NESTED: nft_data_attributes)
358+ * @NFTA_BITWISE_XOR: xor value (NLA_NESTED: nft_data_attributes)
359+ *
360+ * The bitwise expression performs the following operation:
361+ *
362+ * dreg = (sreg & mask) ^ xor
363+ *
364+ * which allow to express all bitwise operations:
365+ *
366+ * mask xor
367+ * NOT: 1 1
368+ * OR: 0 x
369+ * XOR: 1 x
370+ * AND: x 0
371+ */
372+enum nft_bitwise_attributes {
373+ NFTA_BITWISE_UNSPEC,
374+ NFTA_BITWISE_SREG,
375+ NFTA_BITWISE_DREG,
376+ NFTA_BITWISE_LEN,
377+ NFTA_BITWISE_MASK,
378+ NFTA_BITWISE_XOR,
379+ __NFTA_BITWISE_MAX
380+};
381+#define NFTA_BITWISE_MAX (__NFTA_BITWISE_MAX - 1)
382+
383+/**
384+ * enum nft_byteorder_ops - nf_tables byteorder operators
385+ *
386+ * @NFT_BYTEORDER_NTOH: network to host operator
387+ * @NFT_BYTEORDER_HTON: host to network opertaor
388+ */
389+enum nft_byteorder_ops {
390+ NFT_BYTEORDER_NTOH,
391+ NFT_BYTEORDER_HTON,
392+};
393+
394+/**
395+ * enum nft_byteorder_attributes - nf_tables byteorder expression netlink attributes
396+ *
397+ * @NFTA_BYTEORDER_SREG: source register (NLA_U32: nft_registers)
398+ * @NFTA_BYTEORDER_DREG: destination register (NLA_U32: nft_registers)
399+ * @NFTA_BYTEORDER_OP: operator (NLA_U32: enum nft_byteorder_ops)
400+ * @NFTA_BYTEORDER_LEN: length of the data (NLA_U32)
401+ * @NFTA_BYTEORDER_SIZE: data size in bytes (NLA_U32: 2 or 4)
402+ */
403+enum nft_byteorder_attributes {
404+ NFTA_BYTEORDER_UNSPEC,
405+ NFTA_BYTEORDER_SREG,
406+ NFTA_BYTEORDER_DREG,
407+ NFTA_BYTEORDER_OP,
408+ NFTA_BYTEORDER_LEN,
409+ NFTA_BYTEORDER_SIZE,
410+ __NFTA_BYTEORDER_MAX
411+};
412+#define NFTA_BYTEORDER_MAX (__NFTA_BYTEORDER_MAX - 1)
413+
414+/**
415+ * enum nft_cmp_ops - nf_tables relational operator
416+ *
417+ * @NFT_CMP_EQ: equal
418+ * @NFT_CMP_NEQ: not equal
419+ * @NFT_CMP_LT: less than
420+ * @NFT_CMP_LTE: less than or equal to
421+ * @NFT_CMP_GT: greater than
422+ * @NFT_CMP_GTE: greater than or equal to
423+ */
424+enum nft_cmp_ops {
425+ NFT_CMP_EQ,
426+ NFT_CMP_NEQ,
427+ NFT_CMP_LT,
428+ NFT_CMP_LTE,
429+ NFT_CMP_GT,
430+ NFT_CMP_GTE,
431+};
432+
433+/**
434+ * enum nft_cmp_attributes - nf_tables cmp expression netlink attributes
435+ *
436+ * @NFTA_CMP_SREG: source register of data to compare (NLA_U32: nft_registers)
437+ * @NFTA_CMP_OP: cmp operation (NLA_U32: nft_cmp_ops)
438+ * @NFTA_CMP_DATA: data to compare against (NLA_NESTED: nft_data_attributes)
439+ */
440+enum nft_cmp_attributes {
441+ NFTA_CMP_UNSPEC,
442+ NFTA_CMP_SREG,
443+ NFTA_CMP_OP,
444+ NFTA_CMP_DATA,
445+ __NFTA_CMP_MAX
446+};
447+#define NFTA_CMP_MAX (__NFTA_CMP_MAX - 1)
448+
449+/**
450+ * enum nft_lookup_attributes - nf_tables set lookup expression netlink attributes
451+ *
452+ * @NFTA_LOOKUP_SET: name of the set where to look for (NLA_STRING)
453+ * @NFTA_LOOKUP_SREG: source register of the data to look for (NLA_U32: nft_registers)
454+ * @NFTA_LOOKUP_DREG: destination register (NLA_U32: nft_registers)
455+ */
456+enum nft_lookup_attributes {
457+ NFTA_LOOKUP_UNSPEC,
458+ NFTA_LOOKUP_SET,
459+ NFTA_LOOKUP_SREG,
460+ NFTA_LOOKUP_DREG,
461+ __NFTA_LOOKUP_MAX
462+};
463+#define NFTA_LOOKUP_MAX (__NFTA_LOOKUP_MAX - 1)
464+
465+/**
466+ * enum nft_payload_bases - nf_tables payload expression offset bases
467+ *
468+ * @NFT_PAYLOAD_LL_HEADER: link layer header
469+ * @NFT_PAYLOAD_NETWORK_HEADER: network header
470+ * @NFT_PAYLOAD_TRANSPORT_HEADER: transport header
471+ */
472+enum nft_payload_bases {
473+ NFT_PAYLOAD_LL_HEADER,
474+ NFT_PAYLOAD_NETWORK_HEADER,
475+ NFT_PAYLOAD_TRANSPORT_HEADER,
476+};
477+
478+/**
479+ * enum nft_payload_attributes - nf_tables payload expression netlink attributes
480+ *
481+ * @NFTA_PAYLOAD_DREG: destination register to load data into (NLA_U32: nft_registers)
482+ * @NFTA_PAYLOAD_BASE: payload base (NLA_U32: nft_payload_bases)
483+ * @NFTA_PAYLOAD_OFFSET: payload offset relative to base (NLA_U32)
484+ * @NFTA_PAYLOAD_LEN: payload length (NLA_U32)
485+ */
486+enum nft_payload_attributes {
487+ NFTA_PAYLOAD_UNSPEC,
488+ NFTA_PAYLOAD_DREG,
489+ NFTA_PAYLOAD_BASE,
490+ NFTA_PAYLOAD_OFFSET,
491+ NFTA_PAYLOAD_LEN,
492+ __NFTA_PAYLOAD_MAX
493+};
494+#define NFTA_PAYLOAD_MAX (__NFTA_PAYLOAD_MAX - 1)
495+
496+/**
497+ * enum nft_exthdr_attributes - nf_tables IPv6 extension header expression netlink attributes
498+ *
499+ * @NFTA_EXTHDR_DREG: destination register (NLA_U32: nft_registers)
500+ * @NFTA_EXTHDR_TYPE: extension header type (NLA_U8)
501+ * @NFTA_EXTHDR_OFFSET: extension header offset (NLA_U32)
502+ * @NFTA_EXTHDR_LEN: extension header length (NLA_U32)
503+ */
504+enum nft_exthdr_attributes {
505+ NFTA_EXTHDR_UNSPEC,
506+ NFTA_EXTHDR_DREG,
507+ NFTA_EXTHDR_TYPE,
508+ NFTA_EXTHDR_OFFSET,
509+ NFTA_EXTHDR_LEN,
510+ __NFTA_EXTHDR_MAX
511+};
512+#define NFTA_EXTHDR_MAX (__NFTA_EXTHDR_MAX - 1)
513+
514+/**
515+ * enum nft_meta_keys - nf_tables meta expression keys
516+ *
517+ * @NFT_META_LEN: packet length (skb->len)
518+ * @NFT_META_PROTOCOL: packet ethertype protocol (skb->protocol), invalid in OUTPUT
519+ * @NFT_META_PRIORITY: packet priority (skb->priority)
520+ * @NFT_META_MARK: packet mark (skb->mark)
521+ * @NFT_META_IIF: packet input interface index (dev->ifindex)
522+ * @NFT_META_OIF: packet output interface index (dev->ifindex)
523+ * @NFT_META_IIFNAME: packet input interface name (dev->name)
524+ * @NFT_META_OIFNAME: packet output interface name (dev->name)
525+ * @NFT_META_IIFTYPE: packet input interface type (dev->type)
526+ * @NFT_META_OIFTYPE: packet output interface type (dev->type)
527+ * @NFT_META_SKUID: originating socket UID (fsuid)
528+ * @NFT_META_SKGID: originating socket GID (fsgid)
529+ * @NFT_META_NFTRACE: packet nftrace bit
530+ * @NFT_META_RTCLASSID: realm value of packet's route (skb->dst->tclassid)
531+ * @NFT_META_SECMARK: packet secmark (skb->secmark)
532+ */
533+enum nft_meta_keys {
534+ NFT_META_LEN,
535+ NFT_META_PROTOCOL,
536+ NFT_META_PRIORITY,
537+ NFT_META_MARK,
538+ NFT_META_IIF,
539+ NFT_META_OIF,
540+ NFT_META_IIFNAME,
541+ NFT_META_OIFNAME,
542+ NFT_META_IIFTYPE,
543+ NFT_META_OIFTYPE,
544+ NFT_META_SKUID,
545+ NFT_META_SKGID,
546+ NFT_META_NFTRACE,
547+ NFT_META_RTCLASSID,
548+ NFT_META_SECMARK,
549+};
550+
551+/**
552+ * enum nft_meta_attributes - nf_tables meta expression netlink attributes
553+ *
554+ * @NFTA_META_DREG: destination register (NLA_U32)
555+ * @NFTA_META_KEY: meta data item to load (NLA_U32: nft_meta_keys)
556+ */
557+enum nft_meta_attributes {
558+ NFTA_META_UNSPEC,
559+ NFTA_META_DREG,
560+ NFTA_META_KEY,
561+ __NFTA_META_MAX
562+};
563+#define NFTA_META_MAX (__NFTA_META_MAX - 1)
564+
565+/**
566+ * enum nft_ct_keys - nf_tables ct expression keys
567+ *
568+ * @NFT_CT_STATE: conntrack state (bitmask of enum ip_conntrack_info)
569+ * @NFT_CT_DIRECTION: conntrack direction (enum ip_conntrack_dir)
570+ * @NFT_CT_STATUS: conntrack status (bitmask of enum ip_conntrack_status)
571+ * @NFT_CT_MARK: conntrack mark value
572+ * @NFT_CT_SECMARK: conntrack secmark value
573+ * @NFT_CT_EXPIRATION: relative conntrack expiration time in ms
574+ * @NFT_CT_HELPER: connection tracking helper assigned to conntrack
575+ * @NFT_CT_L3PROTOCOL: conntrack layer 3 protocol
576+ * @NFT_CT_SRC: conntrack layer 3 protocol source (IPv4/IPv6 address)
577+ * @NFT_CT_DST: conntrack layer 3 protocol destination (IPv4/IPv6 address)
578+ * @NFT_CT_PROTOCOL: conntrack layer 4 protocol
579+ * @NFT_CT_PROTO_SRC: conntrack layer 4 protocol source
580+ * @NFT_CT_PROTO_DST: conntrack layer 4 protocol destination
581+ */
582+enum nft_ct_keys {
583+ NFT_CT_STATE,
584+ NFT_CT_DIRECTION,
585+ NFT_CT_STATUS,
586+ NFT_CT_MARK,
587+ NFT_CT_SECMARK,
588+ NFT_CT_EXPIRATION,
589+ NFT_CT_HELPER,
590+ NFT_CT_L3PROTOCOL,
591+ NFT_CT_SRC,
592+ NFT_CT_DST,
593+ NFT_CT_PROTOCOL,
594+ NFT_CT_PROTO_SRC,
595+ NFT_CT_PROTO_DST,
596+};
597+
598+/**
599+ * enum nft_ct_attributes - nf_tables ct expression netlink attributes
600+ *
601+ * @NFTA_CT_DREG: destination register (NLA_U32)
602+ * @NFTA_CT_KEY: conntrack data item to load (NLA_U32: nft_ct_keys)
603+ * @NFTA_CT_DIRECTION: direction in case of directional keys (NLA_U8)
604+ */
605+enum nft_ct_attributes {
606+ NFTA_CT_UNSPEC,
607+ NFTA_CT_DREG,
608+ NFTA_CT_KEY,
609+ NFTA_CT_DIRECTION,
610+ __NFTA_CT_MAX
611+};
612+#define NFTA_CT_MAX (__NFTA_CT_MAX - 1)
613+
614+/**
615+ * enum nft_limit_attributes - nf_tables limit expression netlink attributes
616+ *
617+ * @NFTA_LIMIT_RATE: refill rate (NLA_U64)
618+ * @NFTA_LIMIT_UNIT: refill unit (NLA_U64)
619+ */
620+enum nft_limit_attributes {
621+ NFTA_LIMIT_UNSPEC,
622+ NFTA_LIMIT_RATE,
623+ NFTA_LIMIT_UNIT,
624+ __NFTA_LIMIT_MAX
625+};
626+#define NFTA_LIMIT_MAX (__NFTA_LIMIT_MAX - 1)
627+
628+/**
629+ * enum nft_counter_attributes - nf_tables counter expression netlink attributes
630+ *
631+ * @NFTA_COUNTER_BYTES: number of bytes (NLA_U64)
632+ * @NFTA_COUNTER_PACKETS: number of packets (NLA_U64)
633+ */
634+enum nft_counter_attributes {
635+ NFTA_COUNTER_UNSPEC,
636+ NFTA_COUNTER_BYTES,
637+ NFTA_COUNTER_PACKETS,
638+ __NFTA_COUNTER_MAX
639+};
640+#define NFTA_COUNTER_MAX (__NFTA_COUNTER_MAX - 1)
641+
642+/**
643+ * enum nft_log_attributes - nf_tables log expression netlink attributes
644+ *
645+ * @NFTA_LOG_GROUP: netlink group to send messages to (NLA_U32)
646+ * @NFTA_LOG_PREFIX: prefix to prepend to log messages (NLA_STRING)
647+ * @NFTA_LOG_SNAPLEN: length of payload to include in netlink message (NLA_U32)
648+ * @NFTA_LOG_QTHRESHOLD: queue threshold (NLA_U32)
649+ */
650+enum nft_log_attributes {
651+ NFTA_LOG_UNSPEC,
652+ NFTA_LOG_GROUP,
653+ NFTA_LOG_PREFIX,
654+ NFTA_LOG_SNAPLEN,
655+ NFTA_LOG_QTHRESHOLD,
656+ __NFTA_LOG_MAX
657+};
658+#define NFTA_LOG_MAX (__NFTA_LOG_MAX - 1)
659+
660+/**
661+ * enum nft_reject_types - nf_tables reject expression reject types
662+ *
663+ * @NFT_REJECT_ICMP_UNREACH: reject using ICMP unreachable
664+ * @NFT_REJECT_TCP_RST: reject using TCP RST
665+ */
666+enum nft_reject_types {
667+ NFT_REJECT_ICMP_UNREACH,
668+ NFT_REJECT_TCP_RST,
669+};
670+
671+/**
672+ * enum nft_reject_attributes - nf_tables reject expression netlink attributes
673+ *
674+ * @NFTA_REJECT_TYPE: packet type to use (NLA_U32: nft_reject_types)
675+ * @NFTA_REJECT_ICMP_CODE: ICMP code to use (NLA_U8)
676+ */
677+enum nft_reject_attributes {
678+ NFTA_REJECT_UNSPEC,
679+ NFTA_REJECT_TYPE,
680+ NFTA_REJECT_ICMP_CODE,
681+ __NFTA_REJECT_MAX
682+};
683+#define NFTA_REJECT_MAX (__NFTA_REJECT_MAX - 1)
684+
685+/**
686+ * enum nft_nat_types - nf_tables nat expression NAT types
687+ *
688+ * @NFT_NAT_SNAT: source NAT
689+ * @NFT_NAT_DNAT: destination NAT
690+ */
691+enum nft_nat_types {
692+ NFT_NAT_SNAT,
693+ NFT_NAT_DNAT,
694+};
695+
696+/**
697+ * enum nft_nat_attributes - nf_tables nat expression netlink attributes
698+ *
699+ * @NFTA_NAT_TYPE: NAT type (NLA_U32: nft_nat_types)
700+ * @NFTA_NAT_FAMILY: NAT family (NLA_U32)
701+ * @NFTA_NAT_REG_ADDR_MIN: source register of address range start (NLA_U32: nft_registers)
702+ * @NFTA_NAT_REG_ADDR_MAX: source register of address range end (NLA_U32: nft_registers)
703+ * @NFTA_NAT_REG_PROTO_MIN: source register of proto range start (NLA_U32: nft_registers)
704+ * @NFTA_NAT_REG_PROTO_MAX: source register of proto range end (NLA_U32: nft_registers)
705+ */
706+enum nft_nat_attributes {
707+ NFTA_NAT_UNSPEC,
708+ NFTA_NAT_TYPE,
709+ NFTA_NAT_FAMILY,
710+ NFTA_NAT_REG_ADDR_MIN,
711+ NFTA_NAT_REG_ADDR_MAX,
712+ NFTA_NAT_REG_PROTO_MIN,
713+ NFTA_NAT_REG_PROTO_MAX,
714+ __NFTA_NAT_MAX
715+};
716+#define NFTA_NAT_MAX (__NFTA_NAT_MAX - 1)
717+
718+#endif /* _LINUX_NF_TABLES_H */
include/uapi/linux/netfilter/nf_tables_compat.h+38−0
@@ -0,0 +1,38 @@
1+#ifndef _NFT_COMPAT_NFNETLINK_H_
2+#define _NFT_COMPAT_NFNETLINK_H_
3+
4+enum nft_target_attributes {
5+ NFTA_TARGET_UNSPEC,
6+ NFTA_TARGET_NAME,
7+ NFTA_TARGET_REV,
8+ NFTA_TARGET_INFO,
9+ __NFTA_TARGET_MAX
10+};
11+#define NFTA_TARGET_MAX (__NFTA_TARGET_MAX - 1)
12+
13+enum nft_match_attributes {
14+ NFTA_MATCH_UNSPEC,
15+ NFTA_MATCH_NAME,
16+ NFTA_MATCH_REV,
17+ NFTA_MATCH_INFO,
18+ __NFTA_MATCH_MAX
19+};
20+#define NFTA_MATCH_MAX (__NFTA_MATCH_MAX - 1)
21+
22+#define NFT_COMPAT_NAME_MAX 32
23+
24+enum {
25+ NFNL_MSG_COMPAT_GET,
26+ NFNL_MSG_COMPAT_MAX
27+};
28+
29+enum {
30+ NFTA_COMPAT_UNSPEC = 0,
31+ NFTA_COMPAT_NAME,
32+ NFTA_COMPAT_REV,
33+ NFTA_COMPAT_TYPE,
34+ __NFTA_COMPAT_MAX,
35+};
36+#define NFTA_COMPAT_MAX (__NFTA_COMPAT_MAX - 1)
37+
38+#endif
include/uapi/linux/netfilter/nfnetlink.h+9−1
@@ -18,6 +18,8 @@ enum nfnetlink_groups { · 17 unmodified lines
1818 #define NFNLGRP_CONNTRACK_EXP_UPDATE NFNLGRP_CONNTRACK_EXP_UPDATE
1919 NFNLGRP_CONNTRACK_EXP_DESTROY,
2020 #define NFNLGRP_CONNTRACK_EXP_DESTROY NFNLGRP_CONNTRACK_EXP_DESTROY
21+ NFNLGRP_NFTABLES,
22+#define NFNLGRP_NFTABLES NFNLGRP_NFTABLES
2123 __NFNLGRP_MAX,
2224 };
2325 #define NFNLGRP_MAX (__NFNLGRP_MAX - 1)
@@ -51,6 +53,12 @@ struct nfgenmsg { · 27 unmodified lines
5153 #define NFNL_SUBSYS_ACCT 7
5254 #define NFNL_SUBSYS_CTNETLINK_TIMEOUT 8
5355 #define NFNL_SUBSYS_CTHELPER 9
54−#define NFNL_SUBSYS_COUNT 10
56+#define NFNL_SUBSYS_NFTABLES 10
57+#define NFNL_SUBSYS_NFT_COMPAT 11
58+#define NFNL_SUBSYS_COUNT 12
59+
60+/* Reserved control nfnetlink messages */
61+#define NFNL_MSG_BATCH_BEGIN NLMSG_MIN_TYPE
62+#define NFNL_MSG_BATCH_END NLMSG_MIN_TYPE+1
5563
5664 #endif /* _UAPI_NFNETLINK_H */
include/uapi/linux/netfilter/nfnetlink_cttimeout.h+2−0
@@ -6,6 +6,8 @@ enum ctnl_timeout_msg_types { · 5 unmodified lines
66 IPCTNL_MSG_TIMEOUT_NEW,
77 IPCTNL_MSG_TIMEOUT_GET,
88 IPCTNL_MSG_TIMEOUT_DELETE,
9+ IPCTNL_MSG_TIMEOUT_DEFAULT_SET,
10+ IPCTNL_MSG_TIMEOUT_DEFAULT_GET,
911
1012 IPCTNL_MSG_TIMEOUT_MAX
1113 };
include/uapi/linux/nfc.h+4−0
@@ -85,6 +85,7 @@ · 84 unmodified lines
8585 * a specific SE notifies us about the end of a transaction. The parameter
8686 * for this event is the application ID (AID).
8787 * @NFC_CMD_GET_SE: Dump all discovered secure elements from an NFC controller.
88+ * @NFC_CMD_SE_IO: Send/Receive APDUs to/from the selected secure element.
8889 */
8990 enum nfc_commands {
9091 NFC_CMD_UNSPEC,
@@ -114,6 +115,7 @@ enum nfc_commands { · 23 unmodified lines
114115 NFC_EVENT_SE_CONNECTIVITY,
115116 NFC_EVENT_SE_TRANSACTION,
116117 NFC_CMD_GET_SE,
118+ NFC_CMD_SE_IO,
117119 /* private: internal use only */
118120 __NFC_CMD_AFTER_LAST
119121 };
@@ -147,6 +149,7 @@ enum nfc_commands { · 27 unmodified lines
147149 * @NFC_ATTR_SE_INDEX: Secure element index
148150 * @NFC_ATTR_SE_TYPE: Secure element type (UICC or EMBEDDED)
149151 * @NFC_ATTR_FIRMWARE_DOWNLOAD_STATUS: Firmware download operation status
152+ * @NFC_ATTR_APDU: Secure element APDU
150153 */
151154 enum nfc_attrs {
152155 NFC_ATTR_UNSPEC,
@@ -174,6 +177,7 @@ enum nfc_attrs { · 21 unmodified lines
174177 NFC_ATTR_SE_TYPE,
175178 NFC_ATTR_SE_AID,
176179 NFC_ATTR_FIRMWARE_DOWNLOAD_STATUS,
180+ NFC_ATTR_SE_APDU,
177181 /* private: internal use only */
178182 __NFC_ATTR_AFTER_LAST
179183 };
include/uapi/linux/nl80211.h+22−5
@@ -988,7 +988,7 @@ enum nl80211_commands { · 987 unmodified lines
988988 * to query the CRDA to retrieve one regulatory domain. This attribute can
989989 * also be used by userspace to query the kernel for the currently set
990990 * regulatory domain. We chose an alpha2 as that is also used by the
991− * IEEE-802.11d country information element to identify a country.
991+ * IEEE-802.11 country information element to identify a country.
992992 * Users can also simply ask the wireless core to set regulatory domain
993993 * to a specific alpha2.
994994 * @NL80211_ATTR_REG_RULES: a nested array of regulatory domain regulatory
@@ -1496,6 +1496,18 @@ enum nl80211_commands { · 501 unmodified lines
14961496 * @NL80211_ATTR_RXMGMT_FLAGS: flags for nl80211_send_mgmt(), u32.
14971497 * As specified in the &enum nl80211_rxmgmt_flags.
14981498 *
1499+ * @NL80211_ATTR_STA_SUPPORTED_CHANNELS: array of supported channels.
1500+ *
1501+ * @NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES: array of supported
1502+ * supported operating classes.
1503+ *
1504+ * @NL80211_ATTR_HANDLE_DFS: A flag indicating whether user space
1505+ * controls DFS operation in IBSS mode. If the flag is included in
1506+ * %NL80211_CMD_JOIN_IBSS request, the driver will allow use of DFS
1507+ * channels and reports radar events to userspace. Userspace is required
1508+ * to react to radar events, e.g. initiate a channel switch or leave the
1509+ * IBSS network.
1510+ *
14991511 * @NL80211_ATTR_MAX: highest attribute number currently defined
15001512 * @__NL80211_ATTR_AFTER_LAST: internal use
15011513 */
@@ -1806,6 +1818,12 @@ enum nl80211_attrs { · 304 unmodified lines
18061818
18071819 NL80211_ATTR_RXMGMT_FLAGS,
18081820
1821+ NL80211_ATTR_STA_SUPPORTED_CHANNELS,
1822+
1823+ NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES,
1824+
1825+ NL80211_ATTR_HANDLE_DFS,
1826+
18091827 /* add attributes here, update the policy in nl80211.c */
18101828
18111829 __NL80211_ATTR_AFTER_LAST,
@@ -3860,13 +3878,12 @@ enum nl80211_radar_event { · 2048 unmodified lines
38603878 *
38613879 * Channel states used by the DFS code.
38623880 *
3863− * @IEEE80211_DFS_USABLE: The channel can be used, but channel availability
3881+ * @NL80211_DFS_USABLE: The channel can be used, but channel availability
38643882 * check (CAC) must be performed before using it for AP or IBSS.
3865− * @IEEE80211_DFS_UNAVAILABLE: A radar has been detected on this channel, it
3883+ * @NL80211_DFS_UNAVAILABLE: A radar has been detected on this channel, it
38663884 * is therefore marked as not available.
3867− * @IEEE80211_DFS_AVAILABLE: The channel has been CAC checked and is available.
3885+ * @NL80211_DFS_AVAILABLE: The channel has been CAC checked and is available.
38683886 */
3869−
38703887 enum nl80211_dfs_state {
38713888 NL80211_DFS_USABLE,
38723889 NL80211_DFS_UNAVAILABLE,
include/uapi/linux/openvswitch.h+15−3
@@ -63,15 +63,18 @@ enum ovs_datapath_cmd { · 62 unmodified lines
6363 * not be sent.
6464 * @OVS_DP_ATTR_STATS: Statistics about packets that have passed through the
6565 * datapath. Always present in notifications.
66+ * @OVS_DP_ATTR_MEGAFLOW_STATS: Statistics about mega flow masks usage for the
67+ * datapath. Always present in notifications.
6668 *
6769 * These attributes follow the &struct ovs_header within the Generic Netlink
6870 * payload for %OVS_DP_* commands.
6971 */
7072 enum ovs_datapath_attr {
7173 OVS_DP_ATTR_UNSPEC,
72− OVS_DP_ATTR_NAME, /* name of dp_ifindex netdev */
73− OVS_DP_ATTR_UPCALL_PID, /* Netlink PID to receive upcalls */
74− OVS_DP_ATTR_STATS, /* struct ovs_dp_stats */
74+ OVS_DP_ATTR_NAME, /* name of dp_ifindex netdev */
75+ OVS_DP_ATTR_UPCALL_PID, /* Netlink PID to receive upcalls */
76+ OVS_DP_ATTR_STATS, /* struct ovs_dp_stats */
77+ OVS_DP_ATTR_MEGAFLOW_STATS, /* struct ovs_dp_megaflow_stats */
7578 __OVS_DP_ATTR_MAX
7679 };
7780
@@ -84,6 +87,14 @@ struct ovs_dp_stats { · 6 unmodified lines
8487 __u64 n_flows; /* Number of flows present */
8588 };
8689
90+struct ovs_dp_megaflow_stats {
91+ __u64 n_mask_hit; /* Number of masks used for flow lookups. */
92+ __u32 n_masks; /* Number of masks for the datapath. */
93+ __u32 pad0; /* Pad for future expension. */
94+ __u64 pad1; /* Pad for future expension. */
95+ __u64 pad2; /* Pad for future expension. */
96+};
97+
8798 struct ovs_vport_stats {
8899 __u64 rx_packets; /* total packets received */
89100 __u64 tx_packets; /* total packets transmitted */
@@ -260,6 +271,7 @@ enum ovs_key_attr { · 170 unmodified lines
260271 OVS_KEY_ATTR_SKB_MARK, /* u32 skb mark */
261272 OVS_KEY_ATTR_TUNNEL, /* Nested set of ovs_tunnel attributes */
262273 OVS_KEY_ATTR_SCTP, /* struct ovs_key_sctp */
274+ OVS_KEY_ATTR_TCP_FLAGS, /* be16 TCP flags. */
263275
264276 #ifdef __KERNEL__
265277 OVS_KEY_ATTR_IPV4_TUNNEL, /* struct ovs_key_ipv4_tunnel */
include/uapi/linux/pkt_cls.h+14−0
@@ -388,6 +388,20 @@ enum { · 387 unmodified lines
388388
389389 #define TCA_CGROUP_MAX (__TCA_CGROUP_MAX - 1)
390390
391+/* BPF classifier */
392+
393+enum {
394+ TCA_BPF_UNSPEC,
395+ TCA_BPF_ACT,
396+ TCA_BPF_POLICE,
397+ TCA_BPF_CLASSID,
398+ TCA_BPF_OPS_LEN,
399+ TCA_BPF_OPS,
400+ __TCA_BPF_MAX,
401+};
402+
403+#define TCA_BPF_MAX (__TCA_BPF_MAX - 1)
404+
391405 /* Extended Matches */
392406
393407 struct tcf_ematch_tree_hdr {
include/uapi/linux/pkt_sched.h+4−0
@@ -171,6 +171,8 @@ enum { · 170 unmodified lines
171171 TCA_TBF_PARMS,
172172 TCA_TBF_RTAB,
173173 TCA_TBF_PTAB,
174+ TCA_TBF_RATE64,
175+ TCA_TBF_PRATE64,
174176 __TCA_TBF_MAX,
175177 };
176178
@@ -357,6 +359,8 @@ enum { · 180 unmodified lines
357359 TCA_HTB_CTAB,
358360 TCA_HTB_RTAB,
359361 TCA_HTB_DIRECT_QLEN,
362+ TCA_HTB_RATE64,
363+ TCA_HTB_CEIL64,
360364 __TCA_HTB_MAX,
361365 };
362366
include/uapi/linux/random.h+0−7
@@ -40,11 +40,4 @@ struct rand_pool_info { · 39 unmodified lines
4040 __u32 buf[0];
4141 };
4242
43−struct rnd_state {
44− __u32 s1, s2, s3;
45−};
46−
47−/* Exported functions */
48−
49−
5043 #endif /* _UAPI_LINUX_RANDOM_H */