aboutsummaryrefslogtreecommitdiffstats
path: root/include/uapi
diff options
context:
space:
mode:
Diffstat (limited to 'include/uapi')
-rw-r--r--include/uapi/linux/Kbuild1
-rw-r--r--include/uapi/linux/can/gw.h9
-rw-r--r--include/uapi/linux/dn.h3
-rw-r--r--include/uapi/linux/fib_rules.h4
-rw-r--r--include/uapi/linux/icmpv6.h2
-rw-r--r--include/uapi/linux/if_bridge.h3
-rw-r--r--include/uapi/linux/if_link.h3
-rw-r--r--include/uapi/linux/if_packet.h1
-rw-r--r--include/uapi/linux/if_pppox.h2
-rw-r--r--include/uapi/linux/if_tun.h6
-rw-r--r--include/uapi/linux/in.h49
-rw-r--r--include/uapi/linux/in6.h36
-rw-r--r--include/uapi/linux/ip.h2
-rw-r--r--include/uapi/linux/ipv6.h3
-rw-r--r--include/uapi/linux/libc-compat.h103
-rw-r--r--include/uapi/linux/netfilter/Kbuild2
-rw-r--r--include/uapi/linux/netfilter/nf_conntrack_common.h3
-rw-r--r--include/uapi/linux/netfilter/nfnetlink_conntrack.h15
-rw-r--r--include/uapi/linux/netfilter/nfnetlink_queue.h1
-rw-r--r--include/uapi/linux/netfilter/xt_HMARK.h50
-rw-r--r--include/uapi/linux/netfilter/xt_SYNPROXY.h16
-rw-r--r--include/uapi/linux/netfilter/xt_rpfilter.h23
-rw-r--r--include/uapi/linux/netfilter_bridge/ebt_802_3.h5
-rw-r--r--include/uapi/linux/netfilter_ipv4/ipt_CLUSTERIP.h3
-rw-r--r--include/uapi/linux/nfc.h20
-rw-r--r--include/uapi/linux/nl80211.h199
-rw-r--r--include/uapi/linux/openvswitch.h26
-rw-r--r--include/uapi/linux/pkt_sched.h41
-rw-r--r--include/uapi/linux/sctp.h2
-rw-r--r--include/uapi/linux/snmp.h4
-rw-r--r--include/uapi/linux/tcp.h1
-rw-r--r--include/uapi/linux/virtio_net.h6
-rw-r--r--include/uapi/linux/wimax/i2400m.h4
33 files changed, 590 insertions, 58 deletions
diff --git a/include/uapi/linux/Kbuild b/include/uapi/linux/Kbuild
index 997f9f2f0963..e7c94eeb9475 100644
--- a/include/uapi/linux/Kbuild
+++ b/include/uapi/linux/Kbuild
@@ -227,6 +227,7 @@ header-y += kvm_para.h
227endif 227endif
228 228
229header-y += l2tp.h 229header-y += l2tp.h
230header-y += libc-compat.h
230header-y += limits.h 231header-y += limits.h
231header-y += llc.h 232header-y += llc.h
232header-y += loop.h 233header-y += loop.h
diff --git a/include/uapi/linux/can/gw.h b/include/uapi/linux/can/gw.h
index ae07bec74f4b..4e27c82b564a 100644
--- a/include/uapi/linux/can/gw.h
+++ b/include/uapi/linux/can/gw.h
@@ -45,6 +45,7 @@ enum {
45 CGW_DST_IF, /* ifindex of destination network interface */ 45 CGW_DST_IF, /* ifindex of destination network interface */
46 CGW_FILTER, /* specify struct can_filter on source CAN device */ 46 CGW_FILTER, /* specify struct can_filter on source CAN device */
47 CGW_DELETED, /* number of deleted CAN frames (see max_hops param) */ 47 CGW_DELETED, /* number of deleted CAN frames (see max_hops param) */
48 CGW_LIM_HOPS, /* limit the number of hops of this specific rule */
48 __CGW_MAX 49 __CGW_MAX
49}; 50};
50 51
@@ -116,13 +117,19 @@ enum {
116 * Sets a CAN receive filter for the gateway job specified by the 117 * Sets a CAN receive filter for the gateway job specified by the
117 * struct can_filter described in include/linux/can.h 118 * struct can_filter described in include/linux/can.h
118 * 119 *
119 * CGW_MOD_XXX (length 17 bytes): 120 * CGW_MOD_(AND|OR|XOR|SET) (length 17 bytes):
120 * Specifies a modification that's done to a received CAN frame before it is 121 * Specifies a modification that's done to a received CAN frame before it is
121 * send out to the destination interface. 122 * send out to the destination interface.
122 * 123 *
123 * <struct can_frame> data used as operator 124 * <struct can_frame> data used as operator
124 * <u8> affected CAN frame elements 125 * <u8> affected CAN frame elements
125 * 126 *
127 * CGW_LIM_HOPS (length 1 byte):
128 * Limit the number of hops of this specific rule. Usually the received CAN
129 * frame can be processed as much as 'max_hops' times (which is given at module
130 * load time of the can-gw module). This value is used to reduce the number of
131 * possible hops for this gateway rule to a value smaller then max_hops.
132 *
126 * CGW_CS_XOR (length 4 bytes): 133 * CGW_CS_XOR (length 4 bytes):
127 * Set a simple XOR checksum starting with an initial value into 134 * Set a simple XOR checksum starting with an initial value into
128 * data[result-idx] using data[start-idx] .. data[end-idx] 135 * data[result-idx] using data[start-idx] .. data[end-idx]
diff --git a/include/uapi/linux/dn.h b/include/uapi/linux/dn.h
index 9c50445462d9..5fbdd3d49eba 100644
--- a/include/uapi/linux/dn.h
+++ b/include/uapi/linux/dn.h
@@ -2,6 +2,7 @@
2#define _LINUX_DN_H 2#define _LINUX_DN_H
3 3
4#include <linux/types.h> 4#include <linux/types.h>
5#include <linux/if_ether.h>
5 6
6/* 7/*
7 8
@@ -120,7 +121,7 @@ struct linkinfo_dn {
120 * Ethernet address format (for DECnet) 121 * Ethernet address format (for DECnet)
121 */ 122 */
122union etheraddress { 123union etheraddress {
123 __u8 dne_addr[6]; /* Full ethernet address */ 124 __u8 dne_addr[ETH_ALEN]; /* Full ethernet address */
124 struct { 125 struct {
125 __u8 dne_hiord[4]; /* DECnet HIORD prefix */ 126 __u8 dne_hiord[4]; /* DECnet HIORD prefix */
126 __u8 dne_nodeaddr[2]; /* DECnet node address */ 127 __u8 dne_nodeaddr[2]; /* DECnet node address */
diff --git a/include/uapi/linux/fib_rules.h b/include/uapi/linux/fib_rules.h
index 51da65b68b85..2b82d7e30974 100644
--- a/include/uapi/linux/fib_rules.h
+++ b/include/uapi/linux/fib_rules.h
@@ -44,8 +44,8 @@ enum {
44 FRA_FWMARK, /* mark */ 44 FRA_FWMARK, /* mark */
45 FRA_FLOW, /* flow/class id */ 45 FRA_FLOW, /* flow/class id */
46 FRA_UNUSED6, 46 FRA_UNUSED6,
47 FRA_UNUSED7, 47 FRA_SUPPRESS_IFGROUP,
48 FRA_UNUSED8, 48 FRA_SUPPRESS_PREFIXLEN,
49 FRA_TABLE, /* Extended table id */ 49 FRA_TABLE, /* Extended table id */
50 FRA_FWMASK, /* mask for netfilter mark */ 50 FRA_FWMASK, /* mask for netfilter mark */
51 FRA_OIFNAME, 51 FRA_OIFNAME,
diff --git a/include/uapi/linux/icmpv6.h b/include/uapi/linux/icmpv6.h
index e0133c73c304..590beda78ea0 100644
--- a/include/uapi/linux/icmpv6.h
+++ b/include/uapi/linux/icmpv6.h
@@ -115,6 +115,8 @@ struct icmp6hdr {
115#define ICMPV6_NOT_NEIGHBOUR 2 115#define ICMPV6_NOT_NEIGHBOUR 2
116#define ICMPV6_ADDR_UNREACH 3 116#define ICMPV6_ADDR_UNREACH 3
117#define ICMPV6_PORT_UNREACH 4 117#define ICMPV6_PORT_UNREACH 4
118#define ICMPV6_POLICY_FAIL 5
119#define ICMPV6_REJECT_ROUTE 6
118 120
119/* 121/*
120 * Codes for Time Exceeded 122 * Codes for Time Exceeded
diff --git a/include/uapi/linux/if_bridge.h b/include/uapi/linux/if_bridge.h
index 2d70d79ce2fd..39f621a9fe82 100644
--- a/include/uapi/linux/if_bridge.h
+++ b/include/uapi/linux/if_bridge.h
@@ -14,6 +14,7 @@
14#define _UAPI_LINUX_IF_BRIDGE_H 14#define _UAPI_LINUX_IF_BRIDGE_H
15 15
16#include <linux/types.h> 16#include <linux/types.h>
17#include <linux/if_ether.h>
17 18
18#define SYSFS_BRIDGE_ATTR "bridge" 19#define SYSFS_BRIDGE_ATTR "bridge"
19#define SYSFS_BRIDGE_FDB "brforward" 20#define SYSFS_BRIDGE_FDB "brforward"
@@ -88,7 +89,7 @@ struct __port_info {
88}; 89};
89 90
90struct __fdb_entry { 91struct __fdb_entry {
91 __u8 mac_addr[6]; 92 __u8 mac_addr[ETH_ALEN];
92 __u8 port_no; 93 __u8 port_no;
93 __u8 is_local; 94 __u8 is_local;
94 __u32 ageing_timer_value; 95 __u32 ageing_timer_value;
diff --git a/include/uapi/linux/if_link.h b/include/uapi/linux/if_link.h
index 03f6170ab337..80394e8dc3a3 100644
--- a/include/uapi/linux/if_link.h
+++ b/include/uapi/linux/if_link.h
@@ -143,6 +143,7 @@ enum {
143 IFLA_NUM_TX_QUEUES, 143 IFLA_NUM_TX_QUEUES,
144 IFLA_NUM_RX_QUEUES, 144 IFLA_NUM_RX_QUEUES,
145 IFLA_CARRIER, 145 IFLA_CARRIER,
146 IFLA_PHYS_PORT_ID,
146 __IFLA_MAX 147 __IFLA_MAX
147}; 148};
148 149
@@ -313,6 +314,8 @@ enum {
313 IFLA_VXLAN_L2MISS, 314 IFLA_VXLAN_L2MISS,
314 IFLA_VXLAN_L3MISS, 315 IFLA_VXLAN_L3MISS,
315 IFLA_VXLAN_PORT, /* destination port */ 316 IFLA_VXLAN_PORT, /* destination port */
317 IFLA_VXLAN_GROUP6,
318 IFLA_VXLAN_LOCAL6,
316 __IFLA_VXLAN_MAX 319 __IFLA_VXLAN_MAX
317}; 320};
318#define IFLA_VXLAN_MAX (__IFLA_VXLAN_MAX - 1) 321#define IFLA_VXLAN_MAX (__IFLA_VXLAN_MAX - 1)
diff --git a/include/uapi/linux/if_packet.h b/include/uapi/linux/if_packet.h
index b950c02030c0..dbf06667394b 100644
--- a/include/uapi/linux/if_packet.h
+++ b/include/uapi/linux/if_packet.h
@@ -56,6 +56,7 @@ struct sockaddr_ll {
56#define PACKET_FANOUT_LB 1 56#define PACKET_FANOUT_LB 1
57#define PACKET_FANOUT_CPU 2 57#define PACKET_FANOUT_CPU 2
58#define PACKET_FANOUT_ROLLOVER 3 58#define PACKET_FANOUT_ROLLOVER 3
59#define PACKET_FANOUT_RND 4
59#define PACKET_FANOUT_FLAG_ROLLOVER 0x1000 60#define PACKET_FANOUT_FLAG_ROLLOVER 0x1000
60#define PACKET_FANOUT_FLAG_DEFRAG 0x8000 61#define PACKET_FANOUT_FLAG_DEFRAG 0x8000
61 62
diff --git a/include/uapi/linux/if_pppox.h b/include/uapi/linux/if_pppox.h
index e36a4aecd311..e128769331b5 100644
--- a/include/uapi/linux/if_pppox.h
+++ b/include/uapi/linux/if_pppox.h
@@ -46,7 +46,7 @@ struct pppoe_addr {
46 * PPTP addressing definition 46 * PPTP addressing definition
47 */ 47 */
48struct pptp_addr { 48struct pptp_addr {
49 __be16 call_id; 49 __u16 call_id;
50 struct in_addr sin_addr; 50 struct in_addr sin_addr;
51}; 51};
52 52
diff --git a/include/uapi/linux/if_tun.h b/include/uapi/linux/if_tun.h
index 82334f88967e..e9502dd1ee2c 100644
--- a/include/uapi/linux/if_tun.h
+++ b/include/uapi/linux/if_tun.h
@@ -56,6 +56,8 @@
56#define TUNGETVNETHDRSZ _IOR('T', 215, int) 56#define TUNGETVNETHDRSZ _IOR('T', 215, int)
57#define TUNSETVNETHDRSZ _IOW('T', 216, int) 57#define TUNSETVNETHDRSZ _IOW('T', 216, int)
58#define TUNSETQUEUE _IOW('T', 217, int) 58#define TUNSETQUEUE _IOW('T', 217, int)
59#define TUNSETIFINDEX _IOW('T', 218, unsigned int)
60#define TUNGETFILTER _IOR('T', 219, struct sock_fprog)
59 61
60/* TUNSETIFF ifr flags */ 62/* TUNSETIFF ifr flags */
61#define IFF_TUN 0x0001 63#define IFF_TUN 0x0001
@@ -70,6 +72,10 @@
70#define IFF_DETACH_QUEUE 0x0400 72#define IFF_DETACH_QUEUE 0x0400
71/* read-only flag */ 73/* read-only flag */
72#define IFF_PERSIST 0x0800 74#define IFF_PERSIST 0x0800
75#define IFF_NOFILTER 0x1000
76
77/* Socket options */
78#define TUN_TX_TIMESTAMP 1
73 79
74/* Features for GSO (TUNSETOFFLOAD). */ 80/* Features for GSO (TUNSETOFFLOAD). */
75#define TUN_F_CSUM 0x01 /* You can hand me unchecksummed packets. */ 81#define TUN_F_CSUM 0x01 /* You can hand me unchecksummed packets. */
diff --git a/include/uapi/linux/in.h b/include/uapi/linux/in.h
index 9edb441df827..f9e8e496ae5d 100644
--- a/include/uapi/linux/in.h
+++ b/include/uapi/linux/in.h
@@ -24,30 +24,53 @@
24/* Standard well-defined IP protocols. */ 24/* Standard well-defined IP protocols. */
25enum { 25enum {
26 IPPROTO_IP = 0, /* Dummy protocol for TCP */ 26 IPPROTO_IP = 0, /* Dummy protocol for TCP */
27#define IPPROTO_IP IPPROTO_IP
27 IPPROTO_ICMP = 1, /* Internet Control Message Protocol */ 28 IPPROTO_ICMP = 1, /* Internet Control Message Protocol */
29#define IPPROTO_ICMP IPPROTO_ICMP
28 IPPROTO_IGMP = 2, /* Internet Group Management Protocol */ 30 IPPROTO_IGMP = 2, /* Internet Group Management Protocol */
31#define IPPROTO_IGMP IPPROTO_IGMP
29 IPPROTO_IPIP = 4, /* IPIP tunnels (older KA9Q tunnels use 94) */ 32 IPPROTO_IPIP = 4, /* IPIP tunnels (older KA9Q tunnels use 94) */
33#define IPPROTO_IPIP IPPROTO_IPIP
30 IPPROTO_TCP = 6, /* Transmission Control Protocol */ 34 IPPROTO_TCP = 6, /* Transmission Control Protocol */
35#define IPPROTO_TCP IPPROTO_TCP
31 IPPROTO_EGP = 8, /* Exterior Gateway Protocol */ 36 IPPROTO_EGP = 8, /* Exterior Gateway Protocol */
37#define IPPROTO_EGP IPPROTO_EGP
32 IPPROTO_PUP = 12, /* PUP protocol */ 38 IPPROTO_PUP = 12, /* PUP protocol */
39#define IPPROTO_PUP IPPROTO_PUP
33 IPPROTO_UDP = 17, /* User Datagram Protocol */ 40 IPPROTO_UDP = 17, /* User Datagram Protocol */
41#define IPPROTO_UDP IPPROTO_UDP
34 IPPROTO_IDP = 22, /* XNS IDP protocol */ 42 IPPROTO_IDP = 22, /* XNS IDP protocol */
43#define IPPROTO_IDP IPPROTO_IDP
44 IPPROTO_TP = 29, /* SO Transport Protocol Class 4 */
45#define IPPROTO_TP IPPROTO_TP
35 IPPROTO_DCCP = 33, /* Datagram Congestion Control Protocol */ 46 IPPROTO_DCCP = 33, /* Datagram Congestion Control Protocol */
36 IPPROTO_RSVP = 46, /* RSVP protocol */ 47#define IPPROTO_DCCP IPPROTO_DCCP
48 IPPROTO_IPV6 = 41, /* IPv6-in-IPv4 tunnelling */
49#define IPPROTO_IPV6 IPPROTO_IPV6
50 IPPROTO_RSVP = 46, /* RSVP Protocol */
51#define IPPROTO_RSVP IPPROTO_RSVP
37 IPPROTO_GRE = 47, /* Cisco GRE tunnels (rfc 1701,1702) */ 52 IPPROTO_GRE = 47, /* Cisco GRE tunnels (rfc 1701,1702) */
38 53#define IPPROTO_GRE IPPROTO_GRE
39 IPPROTO_IPV6 = 41, /* IPv6-in-IPv4 tunnelling */ 54 IPPROTO_ESP = 50, /* Encapsulation Security Payload protocol */
40 55#define IPPROTO_ESP IPPROTO_ESP
41 IPPROTO_ESP = 50, /* Encapsulation Security Payload protocol */ 56 IPPROTO_AH = 51, /* Authentication Header protocol */
42 IPPROTO_AH = 51, /* Authentication Header protocol */ 57#define IPPROTO_AH IPPROTO_AH
43 IPPROTO_BEETPH = 94, /* IP option pseudo header for BEET */ 58 IPPROTO_MTP = 92, /* Multicast Transport Protocol */
44 IPPROTO_PIM = 103, /* Protocol Independent Multicast */ 59#define IPPROTO_MTP IPPROTO_MTP
45 60 IPPROTO_BEETPH = 94, /* IP option pseudo header for BEET */
46 IPPROTO_COMP = 108, /* Compression Header protocol */ 61#define IPPROTO_BEETPH IPPROTO_BEETPH
47 IPPROTO_SCTP = 132, /* Stream Control Transport Protocol */ 62 IPPROTO_ENCAP = 98, /* Encapsulation Header */
63#define IPPROTO_ENCAP IPPROTO_ENCAP
64 IPPROTO_PIM = 103, /* Protocol Independent Multicast */
65#define IPPROTO_PIM IPPROTO_PIM
66 IPPROTO_COMP = 108, /* Compression Header Protocol */
67#define IPPROTO_COMP IPPROTO_COMP
68 IPPROTO_SCTP = 132, /* Stream Control Transport Protocol */
69#define IPPROTO_SCTP IPPROTO_SCTP
48 IPPROTO_UDPLITE = 136, /* UDP-Lite (RFC 3828) */ 70 IPPROTO_UDPLITE = 136, /* UDP-Lite (RFC 3828) */
49 71#define IPPROTO_UDPLITE IPPROTO_UDPLITE
50 IPPROTO_RAW = 255, /* Raw IP packets */ 72 IPPROTO_RAW = 255, /* Raw IP packets */
73#define IPPROTO_RAW IPPROTO_RAW
51 IPPROTO_MAX 74 IPPROTO_MAX
52}; 75};
53 76
diff --git a/include/uapi/linux/in6.h b/include/uapi/linux/in6.h
index 53b1d56a6e7f..440d5c479145 100644
--- a/include/uapi/linux/in6.h
+++ b/include/uapi/linux/in6.h
@@ -22,22 +22,30 @@
22#define _UAPI_LINUX_IN6_H 22#define _UAPI_LINUX_IN6_H
23 23
24#include <linux/types.h> 24#include <linux/types.h>
25#include <linux/libc-compat.h>
25 26
26/* 27/*
27 * IPv6 address structure 28 * IPv6 address structure
28 */ 29 */
29 30
31#if __UAPI_DEF_IN6_ADDR
30struct in6_addr { 32struct in6_addr {
31 union { 33 union {
32 __u8 u6_addr8[16]; 34 __u8 u6_addr8[16];
35#if __UAPI_DEF_IN6_ADDR_ALT
33 __be16 u6_addr16[8]; 36 __be16 u6_addr16[8];
34 __be32 u6_addr32[4]; 37 __be32 u6_addr32[4];
38#endif
35 } in6_u; 39 } in6_u;
36#define s6_addr in6_u.u6_addr8 40#define s6_addr in6_u.u6_addr8
41#if __UAPI_DEF_IN6_ADDR_ALT
37#define s6_addr16 in6_u.u6_addr16 42#define s6_addr16 in6_u.u6_addr16
38#define s6_addr32 in6_u.u6_addr32 43#define s6_addr32 in6_u.u6_addr32
44#endif
39}; 45};
46#endif /* __UAPI_DEF_IN6_ADDR */
40 47
48#if __UAPI_DEF_SOCKADDR_IN6
41struct sockaddr_in6 { 49struct sockaddr_in6 {
42 unsigned short int sin6_family; /* AF_INET6 */ 50 unsigned short int sin6_family; /* AF_INET6 */
43 __be16 sin6_port; /* Transport layer port # */ 51 __be16 sin6_port; /* Transport layer port # */
@@ -45,7 +53,9 @@ struct sockaddr_in6 {
45 struct in6_addr sin6_addr; /* IPv6 address */ 53 struct in6_addr sin6_addr; /* IPv6 address */
46 __u32 sin6_scope_id; /* scope id (new in RFC2553) */ 54 __u32 sin6_scope_id; /* scope id (new in RFC2553) */
47}; 55};
56#endif /* __UAPI_DEF_SOCKADDR_IN6 */
48 57
58#if __UAPI_DEF_IPV6_MREQ
49struct ipv6_mreq { 59struct ipv6_mreq {
50 /* IPv6 multicast address of group */ 60 /* IPv6 multicast address of group */
51 struct in6_addr ipv6mr_multiaddr; 61 struct in6_addr ipv6mr_multiaddr;
@@ -53,6 +63,7 @@ struct ipv6_mreq {
53 /* local IPv6 address of interface */ 63 /* local IPv6 address of interface */
54 int ipv6mr_ifindex; 64 int ipv6mr_ifindex;
55}; 65};
66#endif /* __UAPI_DEF_IVP6_MREQ */
56 67
57#define ipv6mr_acaddr ipv6mr_multiaddr 68#define ipv6mr_acaddr ipv6mr_multiaddr
58 69
@@ -114,13 +125,24 @@ struct in6_flowlabel_req {
114/* 125/*
115 * IPV6 extension headers 126 * IPV6 extension headers
116 */ 127 */
117#define IPPROTO_HOPOPTS 0 /* IPv6 hop-by-hop options */ 128#if __UAPI_DEF_IPPROTO_V6
118#define IPPROTO_ROUTING 43 /* IPv6 routing header */ 129enum {
119#define IPPROTO_FRAGMENT 44 /* IPv6 fragmentation header */ 130 IPPROTO_HOPOPTS = 0, /* IPv6 hop-by-hop options */
120#define IPPROTO_ICMPV6 58 /* ICMPv6 */ 131#define IPPROTO_HOPOPTS IPPROTO_HOPOPTS
121#define IPPROTO_NONE 59 /* IPv6 no next header */ 132 IPPROTO_ROUTING = 43, /* IPv6 routing header */
122#define IPPROTO_DSTOPTS 60 /* IPv6 destination options */ 133#define IPPROTO_ROUTING IPPROTO_ROUTING
123#define IPPROTO_MH 135 /* IPv6 mobility header */ 134 IPPROTO_FRAGMENT = 44, /* IPv6 fragmentation header */
135#define IPPROTO_FRAGMENT IPPROTO_FRAGMENT
136 IPPROTO_ICMPV6 = 58, /* ICMPv6 */
137#define IPPROTO_ICMPV6 IPPROTO_ICMPV6
138 IPPROTO_NONE = 59, /* IPv6 no next header */
139#define IPPROTO_NONE IPPROTO_NONE
140 IPPROTO_DSTOPTS = 60, /* IPv6 destination options */
141#define IPPROTO_DSTOPTS IPPROTO_DSTOPTS
142 IPPROTO_MH = 135, /* IPv6 mobility header */
143#define IPPROTO_MH IPPROTO_MH
144};
145#endif /* __UAPI_DEF_IPPROTO_V6 */
124 146
125/* 147/*
126 * IPv6 TLV options. 148 * IPv6 TLV options.
diff --git a/include/uapi/linux/ip.h b/include/uapi/linux/ip.h
index 2fee45bdec0a..411959405ab6 100644
--- a/include/uapi/linux/ip.h
+++ b/include/uapi/linux/ip.h
@@ -162,6 +162,8 @@ enum
162 IPV4_DEVCONF_SRC_VMARK, 162 IPV4_DEVCONF_SRC_VMARK,
163 IPV4_DEVCONF_PROXY_ARP_PVLAN, 163 IPV4_DEVCONF_PROXY_ARP_PVLAN,
164 IPV4_DEVCONF_ROUTE_LOCALNET, 164 IPV4_DEVCONF_ROUTE_LOCALNET,
165 IPV4_DEVCONF_IGMPV2_UNSOLICITED_REPORT_INTERVAL,
166 IPV4_DEVCONF_IGMPV3_UNSOLICITED_REPORT_INTERVAL,
165 __IPV4_DEVCONF_MAX 167 __IPV4_DEVCONF_MAX
166}; 168};
167 169
diff --git a/include/uapi/linux/ipv6.h b/include/uapi/linux/ipv6.h
index 4bda4cf5b0f5..593b0e32d956 100644
--- a/include/uapi/linux/ipv6.h
+++ b/include/uapi/linux/ipv6.h
@@ -160,6 +160,9 @@ enum {
160 DEVCONF_ACCEPT_DAD, 160 DEVCONF_ACCEPT_DAD,
161 DEVCONF_FORCE_TLLAO, 161 DEVCONF_FORCE_TLLAO,
162 DEVCONF_NDISC_NOTIFY, 162 DEVCONF_NDISC_NOTIFY,
163 DEVCONF_MLDV1_UNSOLICITED_REPORT_INTERVAL,
164 DEVCONF_MLDV2_UNSOLICITED_REPORT_INTERVAL,
165 DEVCONF_SUPPRESS_FRAG_NDISC,
163 DEVCONF_MAX 166 DEVCONF_MAX
164}; 167};
165 168
diff --git a/include/uapi/linux/libc-compat.h b/include/uapi/linux/libc-compat.h
new file mode 100644
index 000000000000..335e8a7cad39
--- /dev/null
+++ b/include/uapi/linux/libc-compat.h
@@ -0,0 +1,103 @@
1/*
2 * Compatibility interface for userspace libc header coordination:
3 *
4 * Define compatibility macros that are used to control the inclusion or
5 * exclusion of UAPI structures and definitions in coordination with another
6 * userspace C library.
7 *
8 * This header is intended to solve the problem of UAPI definitions that
9 * conflict with userspace definitions. If a UAPI header has such conflicting
10 * definitions then the solution is as follows:
11 *
12 * * Synchronize the UAPI header and the libc headers so either one can be
13 * used and such that the ABI is preserved. If this is not possible then
14 * no simple compatibility interface exists (you need to write translating
15 * wrappers and rename things) and you can't use this interface.
16 *
17 * Then follow this process:
18 *
19 * (a) Include libc-compat.h in the UAPI header.
20 * e.g. #include <linux/libc-compat.h>
21 * This include must be as early as possible.
22 *
23 * (b) In libc-compat.h add enough code to detect that the comflicting
24 * userspace libc header has been included first.
25 *
26 * (c) If the userspace libc header has been included first define a set of
27 * guard macros of the form __UAPI_DEF_FOO and set their values to 1, else
28 * set their values to 0.
29 *
30 * (d) Back in the UAPI header with the conflicting definitions, guard the
31 * definitions with:
32 * #if __UAPI_DEF_FOO
33 * ...
34 * #endif
35 *
36 * This fixes the situation where the linux headers are included *after* the
37 * libc headers. To fix the problem with the inclusion in the other order the
38 * userspace libc headers must be fixed like this:
39 *
40 * * For all definitions that conflict with kernel definitions wrap those
41 * defines in the following:
42 * #if !__UAPI_DEF_FOO
43 * ...
44 * #endif
45 *
46 * This prevents the redefinition of a construct already defined by the kernel.
47 */
48#ifndef _UAPI_LIBC_COMPAT_H
49#define _UAPI_LIBC_COMPAT_H
50
51/* We have included glibc headers... */
52#if defined(__GLIBC__)
53
54/* Coordinate with glibc netinet/in.h header. */
55#if defined(_NETINET_IN_H)
56
57/* GLIBC headers included first so don't define anything
58 * that would already be defined. */
59#define __UAPI_DEF_IN6_ADDR 0
60/* The exception is the in6_addr macros which must be defined
61 * if the glibc code didn't define them. This guard matches
62 * the guard in glibc/inet/netinet/in.h which defines the
63 * additional in6_addr macros e.g. s6_addr16, and s6_addr32. */
64#if defined(__USE_MISC) || defined (__USE_GNU)
65#define __UAPI_DEF_IN6_ADDR_ALT 0
66#else
67#define __UAPI_DEF_IN6_ADDR_ALT 1
68#endif
69#define __UAPI_DEF_SOCKADDR_IN6 0
70#define __UAPI_DEF_IPV6_MREQ 0
71#define __UAPI_DEF_IPPROTO_V6 0
72
73#else
74
75/* Linux headers included first, and we must define everything
76 * we need. The expectation is that glibc will check the
77 * __UAPI_DEF_* defines and adjust appropriately. */
78#define __UAPI_DEF_IN6_ADDR 1
79/* We unconditionally define the in6_addr macros and glibc must
80 * coordinate. */
81#define __UAPI_DEF_IN6_ADDR_ALT 1
82#define __UAPI_DEF_SOCKADDR_IN6 1
83#define __UAPI_DEF_IPV6_MREQ 1
84#define __UAPI_DEF_IPPROTO_V6 1
85
86#endif /* _NETINET_IN_H */
87
88
89/* If we did not see any headers from any supported C libraries,
90 * or we are being included in the kernel, then define everything
91 * that we need. */
92#else /* !defined(__GLIBC__) */
93
94/* Definitions for in6.h */
95#define __UAPI_DEF_IN6_ADDR 1
96#define __UAPI_DEF_IN6_ADDR_ALT 1
97#define __UAPI_DEF_SOCKADDR_IN6 1
98#define __UAPI_DEF_IPV6_MREQ 1
99#define __UAPI_DEF_IPPROTO_V6 1
100
101#endif /* __GLIBC__ */
102
103#endif /* _UAPI_LIBC_COMPAT_H */
diff --git a/include/uapi/linux/netfilter/Kbuild b/include/uapi/linux/netfilter/Kbuild
index 41115776d76f..174915420d3f 100644
--- a/include/uapi/linux/netfilter/Kbuild
+++ b/include/uapi/linux/netfilter/Kbuild
@@ -22,6 +22,7 @@ header-y += xt_CONNMARK.h
22header-y += xt_CONNSECMARK.h 22header-y += xt_CONNSECMARK.h
23header-y += xt_CT.h 23header-y += xt_CT.h
24header-y += xt_DSCP.h 24header-y += xt_DSCP.h
25header-y += xt_HMARK.h
25header-y += xt_IDLETIMER.h 26header-y += xt_IDLETIMER.h
26header-y += xt_LED.h 27header-y += xt_LED.h
27header-y += xt_LOG.h 28header-y += xt_LOG.h
@@ -68,6 +69,7 @@ header-y += xt_quota.h
68header-y += xt_rateest.h 69header-y += xt_rateest.h
69header-y += xt_realm.h 70header-y += xt_realm.h
70header-y += xt_recent.h 71header-y += xt_recent.h
72header-y += xt_rpfilter.h
71header-y += xt_sctp.h 73header-y += xt_sctp.h
72header-y += xt_set.h 74header-y += xt_set.h
73header-y += xt_socket.h 75header-y += xt_socket.h
diff --git a/include/uapi/linux/netfilter/nf_conntrack_common.h b/include/uapi/linux/netfilter/nf_conntrack_common.h
index d69483fb3825..8dd803818ebe 100644
--- a/include/uapi/linux/netfilter/nf_conntrack_common.h
+++ b/include/uapi/linux/netfilter/nf_conntrack_common.h
@@ -99,7 +99,8 @@ enum ip_conntrack_events {
99 IPCT_PROTOINFO, /* protocol information has changed */ 99 IPCT_PROTOINFO, /* protocol information has changed */
100 IPCT_HELPER, /* new helper has been set */ 100 IPCT_HELPER, /* new helper has been set */
101 IPCT_MARK, /* new mark has been set */ 101 IPCT_MARK, /* new mark has been set */
102 IPCT_NATSEQADJ, /* NAT is doing sequence adjustment */ 102 IPCT_SEQADJ, /* sequence adjustment has changed */
103 IPCT_NATSEQADJ = IPCT_SEQADJ,
103 IPCT_SECMARK, /* new security mark has been set */ 104 IPCT_SECMARK, /* new security mark has been set */
104 IPCT_LABEL, /* new connlabel has been set */ 105 IPCT_LABEL, /* new connlabel has been set */
105}; 106};
diff --git a/include/uapi/linux/netfilter/nfnetlink_conntrack.h b/include/uapi/linux/netfilter/nfnetlink_conntrack.h
index 08fabc6c93f3..acad6c52a652 100644
--- a/include/uapi/linux/netfilter/nfnetlink_conntrack.h
+++ b/include/uapi/linux/netfilter/nfnetlink_conntrack.h
@@ -42,8 +42,10 @@ enum ctattr_type {
42 CTA_ID, 42 CTA_ID,
43 CTA_NAT_DST, 43 CTA_NAT_DST,
44 CTA_TUPLE_MASTER, 44 CTA_TUPLE_MASTER,
45 CTA_NAT_SEQ_ADJ_ORIG, 45 CTA_SEQ_ADJ_ORIG,
46 CTA_NAT_SEQ_ADJ_REPLY, 46 CTA_NAT_SEQ_ADJ_ORIG = CTA_SEQ_ADJ_ORIG,
47 CTA_SEQ_ADJ_REPLY,
48 CTA_NAT_SEQ_ADJ_REPLY = CTA_SEQ_ADJ_REPLY,
47 CTA_SECMARK, /* obsolete */ 49 CTA_SECMARK, /* obsolete */
48 CTA_ZONE, 50 CTA_ZONE,
49 CTA_SECCTX, 51 CTA_SECCTX,
@@ -165,6 +167,15 @@ enum ctattr_protonat {
165}; 167};
166#define CTA_PROTONAT_MAX (__CTA_PROTONAT_MAX - 1) 168#define CTA_PROTONAT_MAX (__CTA_PROTONAT_MAX - 1)
167 169
170enum ctattr_seqadj {
171 CTA_SEQADJ_UNSPEC,
172 CTA_SEQADJ_CORRECTION_POS,
173 CTA_SEQADJ_OFFSET_BEFORE,
174 CTA_SEQADJ_OFFSET_AFTER,
175 __CTA_SEQADJ_MAX
176};
177#define CTA_SEQADJ_MAX (__CTA_SEQADJ_MAX - 1)
178
168enum ctattr_natseq { 179enum ctattr_natseq {
169 CTA_NAT_SEQ_UNSPEC, 180 CTA_NAT_SEQ_UNSPEC,
170 CTA_NAT_SEQ_CORRECTION_POS, 181 CTA_NAT_SEQ_CORRECTION_POS,
diff --git a/include/uapi/linux/netfilter/nfnetlink_queue.h b/include/uapi/linux/netfilter/nfnetlink_queue.h
index 3a9b92147339..0132bad79de7 100644
--- a/include/uapi/linux/netfilter/nfnetlink_queue.h
+++ b/include/uapi/linux/netfilter/nfnetlink_queue.h
@@ -46,6 +46,7 @@ enum nfqnl_attr_type {
46 NFQA_CT_INFO, /* enum ip_conntrack_info */ 46 NFQA_CT_INFO, /* enum ip_conntrack_info */
47 NFQA_CAP_LEN, /* __u32 length of captured packet */ 47 NFQA_CAP_LEN, /* __u32 length of captured packet */
48 NFQA_SKB_INFO, /* __u32 skb meta information */ 48 NFQA_SKB_INFO, /* __u32 skb meta information */
49 NFQA_EXP, /* nf_conntrack_netlink.h */
49 50
50 __NFQA_MAX 51 __NFQA_MAX
51}; 52};
diff --git a/include/uapi/linux/netfilter/xt_HMARK.h b/include/uapi/linux/netfilter/xt_HMARK.h
new file mode 100644
index 000000000000..826fc5807577
--- /dev/null
+++ b/include/uapi/linux/netfilter/xt_HMARK.h
@@ -0,0 +1,50 @@
1#ifndef XT_HMARK_H_
2#define XT_HMARK_H_
3
4#include <linux/types.h>
5
6enum {
7 XT_HMARK_SADDR_MASK,
8 XT_HMARK_DADDR_MASK,
9 XT_HMARK_SPI,
10 XT_HMARK_SPI_MASK,
11 XT_HMARK_SPORT,
12 XT_HMARK_DPORT,
13 XT_HMARK_SPORT_MASK,
14 XT_HMARK_DPORT_MASK,
15 XT_HMARK_PROTO_MASK,
16 XT_HMARK_RND,
17 XT_HMARK_MODULUS,
18 XT_HMARK_OFFSET,
19 XT_HMARK_CT,
20 XT_HMARK_METHOD_L3,
21 XT_HMARK_METHOD_L3_4,
22};
23#define XT_HMARK_FLAG(flag) (1 << flag)
24
25union hmark_ports {
26 struct {
27 __u16 src;
28 __u16 dst;
29 } p16;
30 struct {
31 __be16 src;
32 __be16 dst;
33 } b16;
34 __u32 v32;
35 __be32 b32;
36};
37
38struct xt_hmark_info {
39 union nf_inet_addr src_mask;
40 union nf_inet_addr dst_mask;
41 union hmark_ports port_mask;
42 union hmark_ports port_set;
43 __u32 flags;
44 __u16 proto_mask;
45 __u32 hashrnd;
46 __u32 hmodulus;
47 __u32 hoffset; /* Mark offset to start from */
48};
49
50#endif /* XT_HMARK_H_ */
diff --git a/include/uapi/linux/netfilter/xt_SYNPROXY.h b/include/uapi/linux/netfilter/xt_SYNPROXY.h
new file mode 100644
index 000000000000..2d59fbaa93c6
--- /dev/null
+++ b/include/uapi/linux/netfilter/xt_SYNPROXY.h
@@ -0,0 +1,16 @@
1#ifndef _XT_SYNPROXY_H
2#define _XT_SYNPROXY_H
3
4#define XT_SYNPROXY_OPT_MSS 0x01
5#define XT_SYNPROXY_OPT_WSCALE 0x02
6#define XT_SYNPROXY_OPT_SACK_PERM 0x04
7#define XT_SYNPROXY_OPT_TIMESTAMP 0x08
8#define XT_SYNPROXY_OPT_ECN 0x10
9
10struct xt_synproxy_info {
11 __u8 options;
12 __u8 wscale;
13 __u16 mss;
14};
15
16#endif /* _XT_SYNPROXY_H */
diff --git a/include/uapi/linux/netfilter/xt_rpfilter.h b/include/uapi/linux/netfilter/xt_rpfilter.h
new file mode 100644
index 000000000000..8358d4f71952
--- /dev/null
+++ b/include/uapi/linux/netfilter/xt_rpfilter.h
@@ -0,0 +1,23 @@
1#ifndef _XT_RPATH_H
2#define _XT_RPATH_H
3
4#include <linux/types.h>
5
6enum {
7 XT_RPFILTER_LOOSE = 1 << 0,
8 XT_RPFILTER_VALID_MARK = 1 << 1,
9 XT_RPFILTER_ACCEPT_LOCAL = 1 << 2,
10 XT_RPFILTER_INVERT = 1 << 3,
11#ifdef __KERNEL__
12 XT_RPFILTER_OPTION_MASK = XT_RPFILTER_LOOSE |
13 XT_RPFILTER_VALID_MARK |
14 XT_RPFILTER_ACCEPT_LOCAL |
15 XT_RPFILTER_INVERT,
16#endif
17};
18
19struct xt_rpfilter_info {
20 __u8 flags;
21};
22
23#endif
diff --git a/include/uapi/linux/netfilter_bridge/ebt_802_3.h b/include/uapi/linux/netfilter_bridge/ebt_802_3.h
index 5bf84912a082..f37522aade24 100644
--- a/include/uapi/linux/netfilter_bridge/ebt_802_3.h
+++ b/include/uapi/linux/netfilter_bridge/ebt_802_3.h
@@ -2,6 +2,7 @@
2#define _UAPI__LINUX_BRIDGE_EBT_802_3_H 2#define _UAPI__LINUX_BRIDGE_EBT_802_3_H
3 3
4#include <linux/types.h> 4#include <linux/types.h>
5#include <linux/if_ether.h>
5 6
6#define EBT_802_3_SAP 0x01 7#define EBT_802_3_SAP 0x01
7#define EBT_802_3_TYPE 0x02 8#define EBT_802_3_TYPE 0x02
@@ -42,8 +43,8 @@ struct hdr_ni {
42}; 43};
43 44
44struct ebt_802_3_hdr { 45struct ebt_802_3_hdr {
45 __u8 daddr[6]; 46 __u8 daddr[ETH_ALEN];
46 __u8 saddr[6]; 47 __u8 saddr[ETH_ALEN];
47 __be16 len; 48 __be16 len;
48 union { 49 union {
49 struct hdr_ui ui; 50 struct hdr_ui ui;
diff --git a/include/uapi/linux/netfilter_ipv4/ipt_CLUSTERIP.h b/include/uapi/linux/netfilter_ipv4/ipt_CLUSTERIP.h
index c6a204c97047..eac0f6548f47 100644
--- a/include/uapi/linux/netfilter_ipv4/ipt_CLUSTERIP.h
+++ b/include/uapi/linux/netfilter_ipv4/ipt_CLUSTERIP.h
@@ -2,6 +2,7 @@
2#define _IPT_CLUSTERIP_H_target 2#define _IPT_CLUSTERIP_H_target
3 3
4#include <linux/types.h> 4#include <linux/types.h>
5#include <linux/if_ether.h>
5 6
6enum clusterip_hashmode { 7enum clusterip_hashmode {
7 CLUSTERIP_HASHMODE_SIP = 0, 8 CLUSTERIP_HASHMODE_SIP = 0,
@@ -22,7 +23,7 @@ struct ipt_clusterip_tgt_info {
22 __u32 flags; 23 __u32 flags;
23 24
24 /* only relevant for new ones */ 25 /* only relevant for new ones */
25 __u8 clustermac[6]; 26 __u8 clustermac[ETH_ALEN];
26 __u16 num_total_nodes; 27 __u16 num_total_nodes;
27 __u16 num_local_nodes; 28 __u16 num_local_nodes;
28 __u16 local_nodes[CLUSTERIP_MAX_NODES]; 29 __u16 local_nodes[CLUSTERIP_MAX_NODES];
diff --git a/include/uapi/linux/nfc.h b/include/uapi/linux/nfc.h
index 8137dd8d2adf..29bed72a4ac4 100644
--- a/include/uapi/linux/nfc.h
+++ b/include/uapi/linux/nfc.h
@@ -71,6 +71,20 @@
71 * @NFC_CMD_DISABLE_SE: Disable the physical link to a specific secure element. 71 * @NFC_CMD_DISABLE_SE: Disable the physical link to a specific secure element.
72 * @NFC_CMD_FW_DOWNLOAD: Request to Load/flash firmware, or event to inform 72 * @NFC_CMD_FW_DOWNLOAD: Request to Load/flash firmware, or event to inform
73 * that some firmware was loaded 73 * that some firmware was loaded
74 * @NFC_EVENT_SE_ADDED: Event emitted when a new secure element is discovered.
75 * This typically will be sent whenever a new NFC controller with either
76 * an embedded SE or an UICC one connected to it through SWP.
77 * @NFC_EVENT_SE_REMOVED: Event emitted when a secure element is removed from
78 * the system, as a consequence of e.g. an NFC controller being unplugged.
79 * @NFC_EVENT_SE_CONNECTIVITY: This event is emitted whenever a secure element
80 * is requesting connectivity access. For example a UICC SE may need to
81 * talk with a sleeping modem and will notify this need by sending this
82 * event. It is then up to userspace to decide if it will wake the modem
83 * up or not.
84 * @NFC_EVENT_SE_TRANSACTION: This event is sent when an application running on
85 * a specific SE notifies us about the end of a transaction. The parameter
86 * for this event is the application ID (AID).
87 * @NFC_CMD_GET_SE: Dump all discovered secure elements from an NFC controller.
74 */ 88 */
75enum nfc_commands { 89enum nfc_commands {
76 NFC_CMD_UNSPEC, 90 NFC_CMD_UNSPEC,
@@ -97,6 +111,9 @@ enum nfc_commands {
97 NFC_CMD_FW_DOWNLOAD, 111 NFC_CMD_FW_DOWNLOAD,
98 NFC_EVENT_SE_ADDED, 112 NFC_EVENT_SE_ADDED,
99 NFC_EVENT_SE_REMOVED, 113 NFC_EVENT_SE_REMOVED,
114 NFC_EVENT_SE_CONNECTIVITY,
115 NFC_EVENT_SE_TRANSACTION,
116 NFC_CMD_GET_SE,
100/* private: internal use only */ 117/* private: internal use only */
101 __NFC_CMD_AFTER_LAST 118 __NFC_CMD_AFTER_LAST
102}; 119};
@@ -129,6 +146,7 @@ enum nfc_commands {
129 * @NFC_ATTR_FIRMWARE_NAME: Free format firmware version 146 * @NFC_ATTR_FIRMWARE_NAME: Free format firmware version
130 * @NFC_ATTR_SE_INDEX: Secure element index 147 * @NFC_ATTR_SE_INDEX: Secure element index
131 * @NFC_ATTR_SE_TYPE: Secure element type (UICC or EMBEDDED) 148 * @NFC_ATTR_SE_TYPE: Secure element type (UICC or EMBEDDED)
149 * @NFC_ATTR_FIRMWARE_DOWNLOAD_STATUS: Firmware download operation status
132 */ 150 */
133enum nfc_attrs { 151enum nfc_attrs {
134 NFC_ATTR_UNSPEC, 152 NFC_ATTR_UNSPEC,
@@ -154,6 +172,8 @@ enum nfc_attrs {
154 NFC_ATTR_FIRMWARE_NAME, 172 NFC_ATTR_FIRMWARE_NAME,
155 NFC_ATTR_SE_INDEX, 173 NFC_ATTR_SE_INDEX,
156 NFC_ATTR_SE_TYPE, 174 NFC_ATTR_SE_TYPE,
175 NFC_ATTR_SE_AID,
176 NFC_ATTR_FIRMWARE_DOWNLOAD_STATUS,
157/* private: internal use only */ 177/* private: internal use only */
158 __NFC_ATTR_AFTER_LAST 178 __NFC_ATTR_AFTER_LAST
159}; 179};
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 861e5eba3953..fde2c021b26d 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -126,6 +126,31 @@
126 */ 126 */
127 127
128/** 128/**
129 * DOC: packet coalesce support
130 *
131 * In most cases, host that receives IPv4 and IPv6 multicast/broadcast
132 * packets does not do anything with these packets. Therefore the
133 * reception of these unwanted packets causes unnecessary processing
134 * and power consumption.
135 *
136 * Packet coalesce feature helps to reduce number of received interrupts
137 * to host by buffering these packets in firmware/hardware for some
138 * predefined time. Received interrupt will be generated when one of the
139 * following events occur.
140 * a) Expiration of hardware timer whose expiration time is set to maximum
141 * coalescing delay of matching coalesce rule.
142 * b) Coalescing buffer in hardware reaches it's limit.
143 * c) Packet doesn't match any of the configured coalesce rules.
144 *
145 * User needs to configure following parameters for creating a coalesce
146 * rule.
147 * a) Maximum coalescing delay
148 * b) List of packet patterns which needs to be matched
149 * c) Condition for coalescence. pattern 'match' or 'no match'
150 * Multiple such rules can be created.
151 */
152
153/**
129 * enum nl80211_commands - supported nl80211 commands 154 * enum nl80211_commands - supported nl80211 commands
130 * 155 *
131 * @NL80211_CMD_UNSPEC: unspecified command to catch errors 156 * @NL80211_CMD_UNSPEC: unspecified command to catch errors
@@ -648,6 +673,19 @@
648 * @NL80211_CMD_CRIT_PROTOCOL_STOP: Indicates the connection reliability can 673 * @NL80211_CMD_CRIT_PROTOCOL_STOP: Indicates the connection reliability can
649 * return back to normal. 674 * return back to normal.
650 * 675 *
676 * @NL80211_CMD_GET_COALESCE: Get currently supported coalesce rules.
677 * @NL80211_CMD_SET_COALESCE: Configure coalesce rules or clear existing rules.
678 *
679 * @NL80211_CMD_CHANNEL_SWITCH: Perform a channel switch by announcing the
680 * the new channel information (Channel Switch Announcement - CSA)
681 * in the beacon for some time (as defined in the
682 * %NL80211_ATTR_CH_SWITCH_COUNT parameter) and then change to the
683 * new channel. Userspace provides the new channel information (using
684 * %NL80211_ATTR_WIPHY_FREQ and the attributes determining channel
685 * width). %NL80211_ATTR_CH_SWITCH_BLOCK_TX may be supplied to inform
686 * other station that transmission must be blocked until the channel
687 * switch is complete.
688 *
651 * @NL80211_CMD_MAX: highest used command number 689 * @NL80211_CMD_MAX: highest used command number
652 * @__NL80211_CMD_AFTER_LAST: internal use 690 * @__NL80211_CMD_AFTER_LAST: internal use
653 */ 691 */
@@ -810,6 +848,11 @@ enum nl80211_commands {
810 NL80211_CMD_CRIT_PROTOCOL_START, 848 NL80211_CMD_CRIT_PROTOCOL_START,
811 NL80211_CMD_CRIT_PROTOCOL_STOP, 849 NL80211_CMD_CRIT_PROTOCOL_STOP,
812 850
851 NL80211_CMD_GET_COALESCE,
852 NL80211_CMD_SET_COALESCE,
853
854 NL80211_CMD_CHANNEL_SWITCH,
855
813 /* add new commands above here */ 856 /* add new commands above here */
814 857
815 /* used to define NL80211_CMD_MAX below */ 858 /* used to define NL80211_CMD_MAX below */
@@ -1436,6 +1479,23 @@ enum nl80211_commands {
1436 * allowed to be used with the first @NL80211_CMD_SET_STATION command to 1479 * allowed to be used with the first @NL80211_CMD_SET_STATION command to
1437 * update a TDLS peer STA entry. 1480 * update a TDLS peer STA entry.
1438 * 1481 *
1482 * @NL80211_ATTR_COALESCE_RULE: Coalesce rule information.
1483 *
1484 * @NL80211_ATTR_CH_SWITCH_COUNT: u32 attribute specifying the number of TBTT's
1485 * until the channel switch event.
1486 * @NL80211_ATTR_CH_SWITCH_BLOCK_TX: flag attribute specifying that transmission
1487 * must be blocked on the current channel (before the channel switch
1488 * operation).
1489 * @NL80211_ATTR_CSA_IES: Nested set of attributes containing the IE information
1490 * for the time while performing a channel switch.
1491 * @NL80211_ATTR_CSA_C_OFF_BEACON: Offset of the channel switch counter
1492 * field in the beacons tail (%NL80211_ATTR_BEACON_TAIL).
1493 * @NL80211_ATTR_CSA_C_OFF_PRESP: Offset of the channel switch counter
1494 * field in the probe response (%NL80211_ATTR_PROBE_RESP).
1495 *
1496 * @NL80211_ATTR_RXMGMT_FLAGS: flags for nl80211_send_mgmt(), u32.
1497 * As specified in the &enum nl80211_rxmgmt_flags.
1498 *
1439 * @NL80211_ATTR_MAX: highest attribute number currently defined 1499 * @NL80211_ATTR_MAX: highest attribute number currently defined
1440 * @__NL80211_ATTR_AFTER_LAST: internal use 1500 * @__NL80211_ATTR_AFTER_LAST: internal use
1441 */ 1501 */
@@ -1736,6 +1796,16 @@ enum nl80211_attrs {
1736 1796
1737 NL80211_ATTR_PEER_AID, 1797 NL80211_ATTR_PEER_AID,
1738 1798
1799 NL80211_ATTR_COALESCE_RULE,
1800
1801 NL80211_ATTR_CH_SWITCH_COUNT,
1802 NL80211_ATTR_CH_SWITCH_BLOCK_TX,
1803 NL80211_ATTR_CSA_IES,
1804 NL80211_ATTR_CSA_C_OFF_BEACON,
1805 NL80211_ATTR_CSA_C_OFF_PRESP,
1806
1807 NL80211_ATTR_RXMGMT_FLAGS,
1808
1739 /* add attributes here, update the policy in nl80211.c */ 1809 /* add attributes here, update the policy in nl80211.c */
1740 1810
1741 __NL80211_ATTR_AFTER_LAST, 1811 __NL80211_ATTR_AFTER_LAST,
@@ -2773,6 +2843,21 @@ enum nl80211_chan_width {
2773}; 2843};
2774 2844
2775/** 2845/**
2846 * enum nl80211_bss_scan_width - control channel width for a BSS
2847 *
2848 * These values are used with the %NL80211_BSS_CHAN_WIDTH attribute.
2849 *
2850 * @NL80211_BSS_CHAN_WIDTH_20: control channel is 20 MHz wide or compatible
2851 * @NL80211_BSS_CHAN_WIDTH_10: control channel is 10 MHz wide
2852 * @NL80211_BSS_CHAN_WIDTH_5: control channel is 5 MHz wide
2853 */
2854enum nl80211_bss_scan_width {
2855 NL80211_BSS_CHAN_WIDTH_20,
2856 NL80211_BSS_CHAN_WIDTH_10,
2857 NL80211_BSS_CHAN_WIDTH_5,
2858};
2859
2860/**
2776 * enum nl80211_bss - netlink attributes for a BSS 2861 * enum nl80211_bss - netlink attributes for a BSS
2777 * 2862 *
2778 * @__NL80211_BSS_INVALID: invalid 2863 * @__NL80211_BSS_INVALID: invalid
@@ -2796,6 +2881,8 @@ enum nl80211_chan_width {
2796 * @NL80211_BSS_BEACON_IES: binary attribute containing the raw information 2881 * @NL80211_BSS_BEACON_IES: binary attribute containing the raw information
2797 * elements from a Beacon frame (bin); not present if no Beacon frame has 2882 * elements from a Beacon frame (bin); not present if no Beacon frame has
2798 * yet been received 2883 * yet been received
2884 * @NL80211_BSS_CHAN_WIDTH: channel width of the control channel
2885 * (u32, enum nl80211_bss_scan_width)
2799 * @__NL80211_BSS_AFTER_LAST: internal 2886 * @__NL80211_BSS_AFTER_LAST: internal
2800 * @NL80211_BSS_MAX: highest BSS attribute 2887 * @NL80211_BSS_MAX: highest BSS attribute
2801 */ 2888 */
@@ -2812,6 +2899,7 @@ enum nl80211_bss {
2812 NL80211_BSS_STATUS, 2899 NL80211_BSS_STATUS,
2813 NL80211_BSS_SEEN_MS_AGO, 2900 NL80211_BSS_SEEN_MS_AGO,
2814 NL80211_BSS_BEACON_IES, 2901 NL80211_BSS_BEACON_IES,
2902 NL80211_BSS_CHAN_WIDTH,
2815 2903
2816 /* keep last */ 2904 /* keep last */
2817 __NL80211_BSS_AFTER_LAST, 2905 __NL80211_BSS_AFTER_LAST,
@@ -3060,11 +3148,11 @@ enum nl80211_tx_power_setting {
3060}; 3148};
3061 3149
3062/** 3150/**
3063 * enum nl80211_wowlan_packet_pattern_attr - WoWLAN packet pattern attribute 3151 * enum nl80211_packet_pattern_attr - packet pattern attribute
3064 * @__NL80211_WOWLAN_PKTPAT_INVALID: invalid number for nested attribute 3152 * @__NL80211_PKTPAT_INVALID: invalid number for nested attribute
3065 * @NL80211_WOWLAN_PKTPAT_PATTERN: the pattern, values where the mask has 3153 * @NL80211_PKTPAT_PATTERN: the pattern, values where the mask has
3066 * a zero bit are ignored 3154 * a zero bit are ignored
3067 * @NL80211_WOWLAN_PKTPAT_MASK: pattern mask, must be long enough to have 3155 * @NL80211_PKTPAT_MASK: pattern mask, must be long enough to have
3068 * a bit for each byte in the pattern. The lowest-order bit corresponds 3156 * a bit for each byte in the pattern. The lowest-order bit corresponds
3069 * to the first byte of the pattern, but the bytes of the pattern are 3157 * to the first byte of the pattern, but the bytes of the pattern are
3070 * in a little-endian-like format, i.e. the 9th byte of the pattern 3158 * in a little-endian-like format, i.e. the 9th byte of the pattern
@@ -3075,39 +3163,50 @@ enum nl80211_tx_power_setting {
3075 * Note that the pattern matching is done as though frames were not 3163 * Note that the pattern matching is done as though frames were not
3076 * 802.11 frames but 802.3 frames, i.e. the frame is fully unpacked 3164 * 802.11 frames but 802.3 frames, i.e. the frame is fully unpacked
3077 * first (including SNAP header unpacking) and then matched. 3165 * first (including SNAP header unpacking) and then matched.
3078 * @NL80211_WOWLAN_PKTPAT_OFFSET: packet offset, pattern is matched after 3166 * @NL80211_PKTPAT_OFFSET: packet offset, pattern is matched after
3079 * these fixed number of bytes of received packet 3167 * these fixed number of bytes of received packet
3080 * @NUM_NL80211_WOWLAN_PKTPAT: number of attributes 3168 * @NUM_NL80211_PKTPAT: number of attributes
3081 * @MAX_NL80211_WOWLAN_PKTPAT: max attribute number 3169 * @MAX_NL80211_PKTPAT: max attribute number
3082 */ 3170 */
3083enum nl80211_wowlan_packet_pattern_attr { 3171enum nl80211_packet_pattern_attr {
3084 __NL80211_WOWLAN_PKTPAT_INVALID, 3172 __NL80211_PKTPAT_INVALID,
3085 NL80211_WOWLAN_PKTPAT_MASK, 3173 NL80211_PKTPAT_MASK,
3086 NL80211_WOWLAN_PKTPAT_PATTERN, 3174 NL80211_PKTPAT_PATTERN,
3087 NL80211_WOWLAN_PKTPAT_OFFSET, 3175 NL80211_PKTPAT_OFFSET,
3088 3176
3089 NUM_NL80211_WOWLAN_PKTPAT, 3177 NUM_NL80211_PKTPAT,
3090 MAX_NL80211_WOWLAN_PKTPAT = NUM_NL80211_WOWLAN_PKTPAT - 1, 3178 MAX_NL80211_PKTPAT = NUM_NL80211_PKTPAT - 1,
3091}; 3179};
3092 3180
3093/** 3181/**
3094 * struct nl80211_wowlan_pattern_support - pattern support information 3182 * struct nl80211_pattern_support - packet pattern support information
3095 * @max_patterns: maximum number of patterns supported 3183 * @max_patterns: maximum number of patterns supported
3096 * @min_pattern_len: minimum length of each pattern 3184 * @min_pattern_len: minimum length of each pattern
3097 * @max_pattern_len: maximum length of each pattern 3185 * @max_pattern_len: maximum length of each pattern
3098 * @max_pkt_offset: maximum Rx packet offset 3186 * @max_pkt_offset: maximum Rx packet offset
3099 * 3187 *
3100 * This struct is carried in %NL80211_WOWLAN_TRIG_PKT_PATTERN when 3188 * This struct is carried in %NL80211_WOWLAN_TRIG_PKT_PATTERN when
3101 * that is part of %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED in the 3189 * that is part of %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED or in
3102 * capability information given by the kernel to userspace. 3190 * %NL80211_ATTR_COALESCE_RULE_PKT_PATTERN when that is part of
3191 * %NL80211_ATTR_COALESCE_RULE in the capability information given
3192 * by the kernel to userspace.
3103 */ 3193 */
3104struct nl80211_wowlan_pattern_support { 3194struct nl80211_pattern_support {
3105 __u32 max_patterns; 3195 __u32 max_patterns;
3106 __u32 min_pattern_len; 3196 __u32 min_pattern_len;
3107 __u32 max_pattern_len; 3197 __u32 max_pattern_len;
3108 __u32 max_pkt_offset; 3198 __u32 max_pkt_offset;
3109} __attribute__((packed)); 3199} __attribute__((packed));
3110 3200
3201/* only for backward compatibility */
3202#define __NL80211_WOWLAN_PKTPAT_INVALID __NL80211_PKTPAT_INVALID
3203#define NL80211_WOWLAN_PKTPAT_MASK NL80211_PKTPAT_MASK
3204#define NL80211_WOWLAN_PKTPAT_PATTERN NL80211_PKTPAT_PATTERN
3205#define NL80211_WOWLAN_PKTPAT_OFFSET NL80211_PKTPAT_OFFSET
3206#define NUM_NL80211_WOWLAN_PKTPAT NUM_NL80211_PKTPAT
3207#define MAX_NL80211_WOWLAN_PKTPAT MAX_NL80211_PKTPAT
3208#define nl80211_wowlan_pattern_support nl80211_pattern_support
3209
3111/** 3210/**
3112 * enum nl80211_wowlan_triggers - WoWLAN trigger definitions 3211 * enum nl80211_wowlan_triggers - WoWLAN trigger definitions
3113 * @__NL80211_WOWLAN_TRIG_INVALID: invalid number for nested attributes 3212 * @__NL80211_WOWLAN_TRIG_INVALID: invalid number for nested attributes
@@ -3127,7 +3226,7 @@ struct nl80211_wowlan_pattern_support {
3127 * pattern matching is done after the packet is converted to the MSDU. 3226 * pattern matching is done after the packet is converted to the MSDU.
3128 * 3227 *
3129 * In %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED, it is a binary attribute 3228 * In %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED, it is a binary attribute
3130 * carrying a &struct nl80211_wowlan_pattern_support. 3229 * carrying a &struct nl80211_pattern_support.
3131 * 3230 *
3132 * When reporting wakeup. it is a u32 attribute containing the 0-based 3231 * When reporting wakeup. it is a u32 attribute containing the 0-based
3133 * index of the pattern that caused the wakeup, in the patterns passed 3232 * index of the pattern that caused the wakeup, in the patterns passed
@@ -3284,7 +3383,7 @@ struct nl80211_wowlan_tcp_data_token_feature {
3284 * @NL80211_WOWLAN_TCP_WAKE_PAYLOAD: wake packet payload, for advertising a 3383 * @NL80211_WOWLAN_TCP_WAKE_PAYLOAD: wake packet payload, for advertising a
3285 * u32 attribute holding the maximum length 3384 * u32 attribute holding the maximum length
3286 * @NL80211_WOWLAN_TCP_WAKE_MASK: Wake packet payload mask, not used for 3385 * @NL80211_WOWLAN_TCP_WAKE_MASK: Wake packet payload mask, not used for
3287 * feature advertising. The mask works like @NL80211_WOWLAN_PKTPAT_MASK 3386 * feature advertising. The mask works like @NL80211_PKTPAT_MASK
3288 * but on the TCP payload only. 3387 * but on the TCP payload only.
3289 * @NUM_NL80211_WOWLAN_TCP: number of TCP attributes 3388 * @NUM_NL80211_WOWLAN_TCP: number of TCP attributes
3290 * @MAX_NL80211_WOWLAN_TCP: highest attribute number 3389 * @MAX_NL80211_WOWLAN_TCP: highest attribute number
@@ -3309,6 +3408,55 @@ enum nl80211_wowlan_tcp_attrs {
3309}; 3408};
3310 3409
3311/** 3410/**
3411 * struct nl80211_coalesce_rule_support - coalesce rule support information
3412 * @max_rules: maximum number of rules supported
3413 * @pat: packet pattern support information
3414 * @max_delay: maximum supported coalescing delay in msecs
3415 *
3416 * This struct is carried in %NL80211_ATTR_COALESCE_RULE in the
3417 * capability information given by the kernel to userspace.
3418 */
3419struct nl80211_coalesce_rule_support {
3420 __u32 max_rules;
3421 struct nl80211_pattern_support pat;
3422 __u32 max_delay;
3423} __attribute__((packed));
3424
3425/**
3426 * enum nl80211_attr_coalesce_rule - coalesce rule attribute
3427 * @__NL80211_COALESCE_RULE_INVALID: invalid number for nested attribute
3428 * @NL80211_ATTR_COALESCE_RULE_DELAY: delay in msecs used for packet coalescing
3429 * @NL80211_ATTR_COALESCE_RULE_CONDITION: condition for packet coalescence,
3430 * see &enum nl80211_coalesce_condition.
3431 * @NL80211_ATTR_COALESCE_RULE_PKT_PATTERN: packet offset, pattern is matched
3432 * after these fixed number of bytes of received packet
3433 * @NUM_NL80211_ATTR_COALESCE_RULE: number of attributes
3434 * @NL80211_ATTR_COALESCE_RULE_MAX: max attribute number
3435 */
3436enum nl80211_attr_coalesce_rule {
3437 __NL80211_COALESCE_RULE_INVALID,
3438 NL80211_ATTR_COALESCE_RULE_DELAY,
3439 NL80211_ATTR_COALESCE_RULE_CONDITION,
3440 NL80211_ATTR_COALESCE_RULE_PKT_PATTERN,
3441
3442 /* keep last */
3443 NUM_NL80211_ATTR_COALESCE_RULE,
3444 NL80211_ATTR_COALESCE_RULE_MAX = NUM_NL80211_ATTR_COALESCE_RULE - 1
3445};
3446
3447/**
3448 * enum nl80211_coalesce_condition - coalesce rule conditions
3449 * @NL80211_COALESCE_CONDITION_MATCH: coalaesce Rx packets when patterns
3450 * in a rule are matched.
3451 * @NL80211_COALESCE_CONDITION_NO_MATCH: coalesce Rx packets when patterns
3452 * in a rule are not matched.
3453 */
3454enum nl80211_coalesce_condition {
3455 NL80211_COALESCE_CONDITION_MATCH,
3456 NL80211_COALESCE_CONDITION_NO_MATCH
3457};
3458
3459/**
3312 * enum nl80211_iface_limit_attrs - limit attributes 3460 * enum nl80211_iface_limit_attrs - limit attributes
3313 * @NL80211_IFACE_LIMIT_UNSPEC: (reserved) 3461 * @NL80211_IFACE_LIMIT_UNSPEC: (reserved)
3314 * @NL80211_IFACE_LIMIT_MAX: maximum number of interfaces that 3462 * @NL80211_IFACE_LIMIT_MAX: maximum number of interfaces that
@@ -3758,4 +3906,15 @@ enum nl80211_crit_proto_id {
3758/* maximum duration for critical protocol measures */ 3906/* maximum duration for critical protocol measures */
3759#define NL80211_CRIT_PROTO_MAX_DURATION 5000 /* msec */ 3907#define NL80211_CRIT_PROTO_MAX_DURATION 5000 /* msec */
3760 3908
3909/**
3910 * enum nl80211_rxmgmt_flags - flags for received management frame.
3911 *
3912 * Used by cfg80211_rx_mgmt()
3913 *
3914 * @NL80211_RXMGMT_FLAG_ANSWERED: frame was answered by device/driver.
3915 */
3916enum nl80211_rxmgmt_flags {
3917 NL80211_RXMGMT_FLAG_ANSWERED = 1 << 0,
3918};
3919
3761#endif /* __LINUX_NL80211_H */ 3920#endif /* __LINUX_NL80211_H */
diff --git a/include/uapi/linux/openvswitch.h b/include/uapi/linux/openvswitch.h
index c55efaaa9bb4..a74d375b439b 100644
--- a/include/uapi/linux/openvswitch.h
+++ b/include/uapi/linux/openvswitch.h
@@ -1,6 +1,6 @@
1 1
2/* 2/*
3 * Copyright (c) 2007-2011 Nicira Networks. 3 * Copyright (c) 2007-2013 Nicira, Inc.
4 * 4 *
5 * This program is free software; you can redistribute it and/or 5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of version 2 of the GNU General Public 6 * modify it under the terms of version 2 of the GNU General Public
@@ -165,6 +165,7 @@ enum ovs_vport_type {
165 OVS_VPORT_TYPE_NETDEV, /* network device */ 165 OVS_VPORT_TYPE_NETDEV, /* network device */
166 OVS_VPORT_TYPE_INTERNAL, /* network device implemented by datapath */ 166 OVS_VPORT_TYPE_INTERNAL, /* network device implemented by datapath */
167 OVS_VPORT_TYPE_GRE, /* GRE tunnel. */ 167 OVS_VPORT_TYPE_GRE, /* GRE tunnel. */
168 OVS_VPORT_TYPE_VXLAN, /* VXLAN tunnel. */
168 __OVS_VPORT_TYPE_MAX 169 __OVS_VPORT_TYPE_MAX
169}; 170};
170 171
@@ -211,6 +212,16 @@ enum ovs_vport_attr {
211 212
212#define OVS_VPORT_ATTR_MAX (__OVS_VPORT_ATTR_MAX - 1) 213#define OVS_VPORT_ATTR_MAX (__OVS_VPORT_ATTR_MAX - 1)
213 214
215/* OVS_VPORT_ATTR_OPTIONS attributes for tunnels.
216 */
217enum {
218 OVS_TUNNEL_ATTR_UNSPEC,
219 OVS_TUNNEL_ATTR_DST_PORT, /* 16-bit UDP port, used by L4 tunnels. */
220 __OVS_TUNNEL_ATTR_MAX
221};
222
223#define OVS_TUNNEL_ATTR_MAX (__OVS_TUNNEL_ATTR_MAX - 1)
224
214/* Flows. */ 225/* Flows. */
215 226
216#define OVS_FLOW_FAMILY "ovs_flow" 227#define OVS_FLOW_FAMILY "ovs_flow"
@@ -248,6 +259,7 @@ enum ovs_key_attr {
248 OVS_KEY_ATTR_ND, /* struct ovs_key_nd */ 259 OVS_KEY_ATTR_ND, /* struct ovs_key_nd */
249 OVS_KEY_ATTR_SKB_MARK, /* u32 skb mark */ 260 OVS_KEY_ATTR_SKB_MARK, /* u32 skb mark */
250 OVS_KEY_ATTR_TUNNEL, /* Nested set of ovs_tunnel attributes */ 261 OVS_KEY_ATTR_TUNNEL, /* Nested set of ovs_tunnel attributes */
262 OVS_KEY_ATTR_SCTP, /* struct ovs_key_sctp */
251 263
252#ifdef __KERNEL__ 264#ifdef __KERNEL__
253 OVS_KEY_ATTR_IPV4_TUNNEL, /* struct ovs_key_ipv4_tunnel */ 265 OVS_KEY_ATTR_IPV4_TUNNEL, /* struct ovs_key_ipv4_tunnel */
@@ -322,6 +334,11 @@ struct ovs_key_udp {
322 __be16 udp_dst; 334 __be16 udp_dst;
323}; 335};
324 336
337struct ovs_key_sctp {
338 __be16 sctp_src;
339 __be16 sctp_dst;
340};
341
325struct ovs_key_icmp { 342struct ovs_key_icmp {
326 __u8 icmp_type; 343 __u8 icmp_type;
327 __u8 icmp_code; 344 __u8 icmp_code;
@@ -368,6 +385,12 @@ struct ovs_key_nd {
368 * @OVS_FLOW_ATTR_CLEAR: If present in a %OVS_FLOW_CMD_SET request, clears the 385 * @OVS_FLOW_ATTR_CLEAR: If present in a %OVS_FLOW_CMD_SET request, clears the
369 * last-used time, accumulated TCP flags, and statistics for this flow. 386 * last-used time, accumulated TCP flags, and statistics for this flow.
370 * Otherwise ignored in requests. Never present in notifications. 387 * Otherwise ignored in requests. Never present in notifications.
388 * @OVS_FLOW_ATTR_MASK: Nested %OVS_KEY_ATTR_* attributes specifying the
389 * mask bits for wildcarded flow match. Mask bit value '1' specifies exact
390 * match with corresponding flow key bit, while mask bit value '0' specifies
391 * a wildcarded match. Omitting attribute is treated as wildcarding all
392 * corresponding fields. Optional for all requests. If not present,
393 * all flow key bits are exact match bits.
371 * 394 *
372 * These attributes follow the &struct ovs_header within the Generic Netlink 395 * These attributes follow the &struct ovs_header within the Generic Netlink
373 * payload for %OVS_FLOW_* commands. 396 * payload for %OVS_FLOW_* commands.
@@ -380,6 +403,7 @@ enum ovs_flow_attr {
380 OVS_FLOW_ATTR_TCP_FLAGS, /* 8-bit OR'd TCP flags. */ 403 OVS_FLOW_ATTR_TCP_FLAGS, /* 8-bit OR'd TCP flags. */
381 OVS_FLOW_ATTR_USED, /* u64 msecs last used in monotonic time. */ 404 OVS_FLOW_ATTR_USED, /* u64 msecs last used in monotonic time. */
382 OVS_FLOW_ATTR_CLEAR, /* Flag to clear stats, tcp_flags, used. */ 405 OVS_FLOW_ATTR_CLEAR, /* Flag to clear stats, tcp_flags, used. */
406 OVS_FLOW_ATTR_MASK, /* Sequence of OVS_KEY_ATTR_* attributes. */
383 __OVS_FLOW_ATTR_MAX 407 __OVS_FLOW_ATTR_MAX
384}; 408};
385 409
diff --git a/include/uapi/linux/pkt_sched.h b/include/uapi/linux/pkt_sched.h
index 09d62b9228ff..9b829134d422 100644
--- a/include/uapi/linux/pkt_sched.h
+++ b/include/uapi/linux/pkt_sched.h
@@ -744,4 +744,45 @@ struct tc_fq_codel_xstats {
744 }; 744 };
745}; 745};
746 746
747/* FQ */
748
749enum {
750 TCA_FQ_UNSPEC,
751
752 TCA_FQ_PLIMIT, /* limit of total number of packets in queue */
753
754 TCA_FQ_FLOW_PLIMIT, /* limit of packets per flow */
755
756 TCA_FQ_QUANTUM, /* RR quantum */
757
758 TCA_FQ_INITIAL_QUANTUM, /* RR quantum for new flow */
759
760 TCA_FQ_RATE_ENABLE, /* enable/disable rate limiting */
761
762 TCA_FQ_FLOW_DEFAULT_RATE,/* for sockets with unspecified sk_rate,
763 * use the following rate
764 */
765
766 TCA_FQ_FLOW_MAX_RATE, /* per flow max rate */
767
768 TCA_FQ_BUCKETS_LOG, /* log2(number of buckets) */
769 __TCA_FQ_MAX
770};
771
772#define TCA_FQ_MAX (__TCA_FQ_MAX - 1)
773
774struct tc_fq_qd_stats {
775 __u64 gc_flows;
776 __u64 highprio_packets;
777 __u64 tcp_retrans;
778 __u64 throttled;
779 __u64 flows_plimit;
780 __u64 pkts_too_long;
781 __u64 allocation_errors;
782 __s64 time_next_delayed_flow;
783 __u32 flows;
784 __u32 inactive_flows;
785 __u32 throttled_flows;
786 __u32 pad;
787};
747#endif 788#endif
diff --git a/include/uapi/linux/sctp.h b/include/uapi/linux/sctp.h
index 66b466e4ca08..ca451e99b28b 100644
--- a/include/uapi/linux/sctp.h
+++ b/include/uapi/linux/sctp.h
@@ -28,7 +28,7 @@
28 * 28 *
29 * Please send any bug reports or fixes you make to the 29 * Please send any bug reports or fixes you make to the
30 * email address(es): 30 * email address(es):
31 * lksctp developers <lksctp-developers@lists.sourceforge.net> 31 * lksctp developers <linux-sctp@vger.kernel.org>
32 * 32 *
33 * Or submit a bug report through the following website: 33 * Or submit a bug report through the following website:
34 * http://www.sf.net/projects/lksctp 34 * http://www.sf.net/projects/lksctp
diff --git a/include/uapi/linux/snmp.h b/include/uapi/linux/snmp.h
index a1356d3b54df..1bdb4a39d1e1 100644
--- a/include/uapi/linux/snmp.h
+++ b/include/uapi/linux/snmp.h
@@ -51,6 +51,10 @@ enum
51 IPSTATS_MIB_INBCASTOCTETS, /* InBcastOctets */ 51 IPSTATS_MIB_INBCASTOCTETS, /* InBcastOctets */
52 IPSTATS_MIB_OUTBCASTOCTETS, /* OutBcastOctets */ 52 IPSTATS_MIB_OUTBCASTOCTETS, /* OutBcastOctets */
53 IPSTATS_MIB_CSUMERRORS, /* InCsumErrors */ 53 IPSTATS_MIB_CSUMERRORS, /* InCsumErrors */
54 IPSTATS_MIB_NOECTPKTS, /* InNoECTPkts */
55 IPSTATS_MIB_ECT1PKTS, /* InECT1Pkts */
56 IPSTATS_MIB_ECT0PKTS, /* InECT0Pkts */
57 IPSTATS_MIB_CEPKTS, /* InCEPkts */
54 __IPSTATS_MIB_MAX 58 __IPSTATS_MIB_MAX
55}; 59};
56 60
diff --git a/include/uapi/linux/tcp.h b/include/uapi/linux/tcp.h
index 8d776ebc4829..377f1e59411d 100644
--- a/include/uapi/linux/tcp.h
+++ b/include/uapi/linux/tcp.h
@@ -111,6 +111,7 @@ enum {
111#define TCP_REPAIR_OPTIONS 22 111#define TCP_REPAIR_OPTIONS 22
112#define TCP_FASTOPEN 23 /* Enable FastOpen on listeners */ 112#define TCP_FASTOPEN 23 /* Enable FastOpen on listeners */
113#define TCP_TIMESTAMP 24 113#define TCP_TIMESTAMP 24
114#define TCP_NOTSENT_LOWAT 25 /* limit number of unsent bytes in write queue */
114 115
115struct tcp_repair_opt { 116struct tcp_repair_opt {
116 __u32 opt_code; 117 __u32 opt_code;
diff --git a/include/uapi/linux/virtio_net.h b/include/uapi/linux/virtio_net.h
index c520203fac2f..172a7f00780c 100644
--- a/include/uapi/linux/virtio_net.h
+++ b/include/uapi/linux/virtio_net.h
@@ -60,7 +60,7 @@
60 60
61struct virtio_net_config { 61struct virtio_net_config {
62 /* The config defining mac address (if VIRTIO_NET_F_MAC) */ 62 /* The config defining mac address (if VIRTIO_NET_F_MAC) */
63 __u8 mac[6]; 63 __u8 mac[ETH_ALEN];
64 /* See VIRTIO_NET_F_STATUS and VIRTIO_NET_S_* above */ 64 /* See VIRTIO_NET_F_STATUS and VIRTIO_NET_S_* above */
65 __u16 status; 65 __u16 status;
66 /* Maximum number of each of transmit and receive queues; 66 /* Maximum number of each of transmit and receive queues;
@@ -70,7 +70,9 @@ struct virtio_net_config {
70 __u16 max_virtqueue_pairs; 70 __u16 max_virtqueue_pairs;
71} __attribute__((packed)); 71} __attribute__((packed));
72 72
73/* This is the first element of the scatter-gather list. If you don't 73/* This header comes first in the scatter-gather list.
74 * If VIRTIO_F_ANY_LAYOUT is not negotiated, it must
75 * be the first element of the scatter-gather list. If you don't
74 * specify GSO or CSUM features, you can simply ignore the header. */ 76 * specify GSO or CSUM features, you can simply ignore the header. */
75struct virtio_net_hdr { 77struct virtio_net_hdr {
76#define VIRTIO_NET_HDR_F_NEEDS_CSUM 1 // Use csum_start, csum_offset 78#define VIRTIO_NET_HDR_F_NEEDS_CSUM 1 // Use csum_start, csum_offset
diff --git a/include/uapi/linux/wimax/i2400m.h b/include/uapi/linux/wimax/i2400m.h
index 62d356153565..fd198bc24a3c 100644
--- a/include/uapi/linux/wimax/i2400m.h
+++ b/include/uapi/linux/wimax/i2400m.h
@@ -122,7 +122,7 @@
122#define __LINUX__WIMAX__I2400M_H__ 122#define __LINUX__WIMAX__I2400M_H__
123 123
124#include <linux/types.h> 124#include <linux/types.h>
125 125#include <linux/if_ether.h>
126 126
127/* 127/*
128 * Host Device Interface (HDI) common to all busses 128 * Host Device Interface (HDI) common to all busses
@@ -487,7 +487,7 @@ struct i2400m_tlv_l4_message_versions {
487struct i2400m_tlv_detailed_device_info { 487struct i2400m_tlv_detailed_device_info {
488 struct i2400m_tlv_hdr hdr; 488 struct i2400m_tlv_hdr hdr;
489 __u8 reserved1[400]; 489 __u8 reserved1[400];
490 __u8 mac_address[6]; 490 __u8 mac_address[ETH_ALEN];
491 __u8 reserved2[2]; 491 __u8 reserved2[2];
492} __attribute__((packed)); 492} __attribute__((packed));
493 493