History

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

Pull networking updates from David Miller: "Reasonably busy this cycle, but perhaps not as busy as in the 4.12 merge window: 1) Several optimizations for UDP processing under high load from Paolo Abeni. 2) Support pacing internally in TCP when using the sch_fq packet scheduler for this is not practical. From Eric Dumazet. 3) Support mutliple filter chains per qdisc, from Jiri Pirko. 4) Move to 1ms TCP timestamp clock, from Eric Dumazet. 5) Add batch dequeueing to vhost_net, from Jason Wang. 6) Flesh out more completely SCTP checksum offload support, from Davide Caratti. 7) More plumbing of extended netlink ACKs, from David Ahern, Pablo Neira Ayuso, and Matthias Schiffer. 8) Add devlink support to nfp driver, from Simon Horman. 9) Add RTM_F_FIB_MATCH flag to RTM_GETROUTE queries, from Roopa Prabhu. 10) Add stack depth tracking to BPF verifier and use this information in the various eBPF JITs. From Alexei Starovoitov. 11) Support XDP on qed device VFs, from Yuval Mintz. 12) Introduce BPF PROG ID for better introspection of installed BPF programs. From Martin KaFai Lau. 13) Add bpf_set_hash helper for TC bpf programs, from Daniel Borkmann. 14) For loads, allow narrower accesses in bpf verifier checking, from Yonghong Song. 15) Support MIPS in the BPF selftests and samples infrastructure, the MIPS eBPF JIT will be merged in via the MIPS GIT tree. From David Daney. 16) Support kernel based TLS, from Dave Watson and others. 17) Remove completely DST garbage collection, from Wei Wang. 18) Allow installing TCP MD5 rules using prefixes, from Ivan Delalande. 19) Add XDP support to Intel i40e driver, from Björn Töpel 20) Add support for TC flower offload in nfp driver, from Simon Horman, Pieter Jansen van Vuuren, Benjamin LaHaise, Jakub Kicinski, and Bert van Leeuwen. 21) IPSEC offloading support in mlx5, from Ilan Tayari. 22) Add HW PTP support to macb driver, from Rafal Ozieblo. 23) Networking refcount_t conversions, From Elena Reshetova. 24) Add sock_ops support to BPF, from Lawrence Brako. This is useful for tuning the TCP sockopt settings of a group of applications, currently via CGROUPs" * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1899 commits) net: phy: dp83867: add workaround for incorrect RX_CTRL pin strap dt-bindings: phy: dp83867: provide a workaround for incorrect RX_CTRL pin strap cxgb4: Support for get_ts_info ethtool method cxgb4: Add PTP Hardware Clock (PHC) support cxgb4: time stamping interface for PTP nfp: default to chained metadata prepend format nfp: remove legacy MAC address lookup nfp: improve order of interfaces in breakout mode net: macb: remove extraneous return when MACB_EXT_DESC is defined bpf: add missing break in for the TCP_BPF_SNDCWND_CLAMP case bpf: fix return in load_bpf_file mpls: fix rtm policy in mpls_getroute net, ax25: convert ax25_cb.refcount from atomic_t to refcount_t net, ax25: convert ax25_route.refcount from atomic_t to refcount_t net, ax25: convert ax25_uid_assoc.refcount from atomic_t to refcount_t net, sctp: convert sctp_ep_common.refcnt from atomic_t to refcount_t net, sctp: convert sctp_transport.refcnt from atomic_t to refcount_t net, sctp: convert sctp_chunk.refcnt from atomic_t to refcount_t net, sctp: convert sctp_datamsg.refcnt from atomic_t to refcount_t net, sctp: convert sctp_auth_bytes.refcnt from atomic_t to refcount_t ...

Linus Torvalds committed 9 years ago

Commit 5518b692 parents 8ad06e5 0e725821901 files · +98596 −35934Browse files

Showing the changes to include/uapi/linux (16 of 1901 files). Show all

Unified · Split

16 files
  1. include/uapi/linux/bpf.h +135 −5
  2. include/uapi/linux/if_link.h +18 −2
  3. include/uapi/linux/mroute.h +54 −0
  4. include/uapi/linux/mroute6.h +12 −0
  5. include/uapi/linux/neighbour.h +1 −0
  6. include/uapi/linux/net_tstamp.h +14 −1
  7. include/uapi/linux/nl80211.h +73 −9
  8. include/uapi/linux/pkt_cls.h +17 −0
  9. include/uapi/linux/rtnetlink.h +9 −0
  10. include/uapi/linux/sctp.h +6 −0
  11. include/uapi/linux/snmp.h +1 −0
  12. include/uapi/linux/tc_act/tc_bpf.h +1 −0
  13. include/uapi/linux/tc_act/tc_tunnel_key.h +1 −0
  14. include/uapi/linux/tcp.h +8 −2
  15. include/uapi/linux/tls.h +79 −0
  16. include/uapi/linux/wil6210_uapi.h +0 −87
include/uapi/linux/bpf.h+135−5
@@ -82,6 +82,11 @@ enum bpf_cmd { · 81 unmodified lines
8282 BPF_PROG_ATTACH,
8383 BPF_PROG_DETACH,
8484 BPF_PROG_TEST_RUN,
85+ BPF_PROG_GET_NEXT_ID,
86+ BPF_MAP_GET_NEXT_ID,
87+ BPF_PROG_GET_FD_BY_ID,
88+ BPF_MAP_GET_FD_BY_ID,
89+ BPF_OBJ_GET_INFO_BY_FD,
8590 };
8691
8792 enum bpf_map_type {
@@ -115,12 +120,14 @@ enum bpf_prog_type { · 27 unmodified lines
115120 BPF_PROG_TYPE_LWT_IN,
116121 BPF_PROG_TYPE_LWT_OUT,
117122 BPF_PROG_TYPE_LWT_XMIT,
123+ BPF_PROG_TYPE_SOCK_OPS,
118124 };
119125
120126 enum bpf_attach_type {
121127 BPF_CGROUP_INET_INGRESS,
122128 BPF_CGROUP_INET_EGRESS,
123129 BPF_CGROUP_INET_SOCK_CREATE,
130+ BPF_CGROUP_SOCK_OPS,
124131 __MAX_BPF_ATTACH_TYPE
125132 };
126133
@@ -209,6 +216,21 @@ union bpf_attr { · 82 unmodified lines
209216 __u32 repeat;
210217 __u32 duration;
211218 } test;
219+
220+ struct { /* anonymous struct used by BPF_*_GET_*_ID */
221+ union {
222+ __u32 start_id;
223+ __u32 prog_id;
224+ __u32 map_id;
225+ };
226+ __u32 next_id;
227+ };
228+
229+ struct { /* anonymous struct used by BPF_OBJ_GET_INFO_BY_FD */
230+ __u32 bpf_fd;
231+ __u32 info_len;
232+ __aligned_u64 info;
233+ } info;
212234 } __attribute__((aligned(8)));
213235
214236 /* BPF helper function descriptions:
@@ -313,8 +335,11 @@ union bpf_attr { · 98 unmodified lines
313335 * @flags: room for future extensions
314336 * Return: 0 on success or negative error
315337 *
316− * u64 bpf_perf_event_read(&map, index)
317− * Return: Number events read or error code
338+ * u64 bpf_perf_event_read(map, flags)
339+ * read perf event counter value
340+ * @map: pointer to perf_event_array map
341+ * @flags: index of event in the map or bitmask flags
342+ * Return: value of perf event counter read or error code
318343 *
319344 * int bpf_redirect(ifindex, flags)
320345 * redirect to another netdev
@@ -328,11 +353,11 @@ union bpf_attr { · 7 unmodified lines
328353 * @skb: pointer to skb
329354 * Return: realm if != 0
330355 *
331− * int bpf_perf_event_output(ctx, map, index, data, size)
356+ * int bpf_perf_event_output(ctx, map, flags, data, size)
332357 * output perf raw sample
333358 * @ctx: struct pt_regs*
334359 * @map: pointer to perf_event_array map
335− * @index: index of event in the map
360+ * @flags: index of event in the map or bitmask flags
336361 * @data: data on stack to be output as raw data
337362 * @size: size of data
338363 * Return: 0 on success or negative error
@@ -490,6 +515,30 @@ union bpf_attr { · 151 unmodified lines
490515 * Get the owner uid of the socket stored inside sk_buff.
491516 * @skb: pointer to skb
492517 * Return: uid of the socket owner on success or overflowuid if failed.
518+ *
519+ * u32 bpf_set_hash(skb, hash)
520+ * Set full skb->hash.
521+ * @skb: pointer to skb
522+ * @hash: hash to set
523+ *
524+ * int bpf_setsockopt(bpf_socket, level, optname, optval, optlen)
525+ * Calls setsockopt. Not all opts are available, only those with
526+ * integer optvals plus TCP_CONGESTION.
527+ * Supported levels: SOL_SOCKET and IPROTO_TCP
528+ * @bpf_socket: pointer to bpf_socket
529+ * @level: SOL_SOCKET or IPROTO_TCP
530+ * @optname: option name
531+ * @optval: pointer to option value
532+ * @optlen: length of optval in byes
533+ * Return: 0 or negative error
534+ *
535+ * int bpf_skb_adjust_room(skb, len_diff, mode, flags)
536+ * Grow or shrink room in sk_buff.
537+ * @skb: pointer to skb
538+ * @len_diff: (signed) amount of room to grow/shrink
539+ * @mode: operation mode (enum bpf_adj_room_mode)
540+ * @flags: reserved for future use
541+ * Return: 0 on success or negative error code
493542 */
494543 #define __BPF_FUNC_MAPPER(FN) \
495544 FN(unspec), \
@@ -539,7 +588,10 @@ union bpf_attr { · 43 unmodified lines
539588 FN(xdp_adjust_head), \
540589 FN(probe_read_str), \
541590 FN(get_socket_cookie), \
542− FN(get_socket_uid),
591+ FN(get_socket_uid), \
592+ FN(set_hash), \
593+ FN(setsockopt), \
594+ FN(skb_adjust_room),
543595
544596 /* integer value in 'imm' field of BPF_CALL instruction selects which helper
545597 * function eBPF program intends to call
@@ -589,6 +641,11 @@ enum bpf_func_id { · 43 unmodified lines
589641 /* BPF_FUNC_perf_event_output for sk_buff input context. */
590642 #define BPF_F_CTXLEN_MASK (0xfffffULL << 32)
591643
644+/* Mode for BPF_FUNC_skb_adjust_room helper. */
645+enum bpf_adj_room_mode {
646+ BPF_ADJ_ROOM_NET,
647+};
648+
592649 /* user accessible mirror of in-kernel sk_buff.
593650 * new fields can only be added to the end of this structure
594651 */
@@ -670,4 +727,77 @@ struct xdp_md { · 75 unmodified lines
670727 __u32 data_end;
671728 };
672729
730+#define BPF_TAG_SIZE 8
731+
732+struct bpf_prog_info {
733+ __u32 type;
734+ __u32 id;
735+ __u8 tag[BPF_TAG_SIZE];
736+ __u32 jited_prog_len;
737+ __u32 xlated_prog_len;
738+ __aligned_u64 jited_prog_insns;
739+ __aligned_u64 xlated_prog_insns;
740+} __attribute__((aligned(8)));
741+
742+struct bpf_map_info {
743+ __u32 type;
744+ __u32 id;
745+ __u32 key_size;
746+ __u32 value_size;
747+ __u32 max_entries;
748+ __u32 map_flags;
749+} __attribute__((aligned(8)));
750+
751+/* User bpf_sock_ops struct to access socket values and specify request ops
752+ * and their replies.
753+ * Some of this fields are in network (bigendian) byte order and may need
754+ * to be converted before use (bpf_ntohl() defined in samples/bpf/bpf_endian.h).
755+ * New fields can only be added at the end of this structure
756+ */
757+struct bpf_sock_ops {
758+ __u32 op;
759+ union {
760+ __u32 reply;
761+ __u32 replylong[4];
762+ };
763+ __u32 family;
764+ __u32 remote_ip4; /* Stored in network byte order */
765+ __u32 local_ip4; /* Stored in network byte order */
766+ __u32 remote_ip6[4]; /* Stored in network byte order */
767+ __u32 local_ip6[4]; /* Stored in network byte order */
768+ __u32 remote_port; /* Stored in network byte order */
769+ __u32 local_port; /* stored in host byte order */
770+};
771+
772+/* List of known BPF sock_ops operators.
773+ * New entries can only be added at the end
774+ */
775+enum {
776+ BPF_SOCK_OPS_VOID,
777+ BPF_SOCK_OPS_TIMEOUT_INIT, /* Should return SYN-RTO value to use or
778+ * -1 if default value should be used
779+ */
780+ BPF_SOCK_OPS_RWND_INIT, /* Should return initial advertized
781+ * window (in packets) or -1 if default
782+ * value should be used
783+ */
784+ BPF_SOCK_OPS_TCP_CONNECT_CB, /* Calls BPF program right before an
785+ * active connection is initialized
786+ */
787+ BPF_SOCK_OPS_ACTIVE_ESTABLISHED_CB, /* Calls BPF program when an
788+ * active connection is
789+ * established
790+ */
791+ BPF_SOCK_OPS_PASSIVE_ESTABLISHED_CB, /* Calls BPF program when a
792+ * passive connection is
793+ * established
794+ */
795+ BPF_SOCK_OPS_NEEDS_ECN, /* If connection's congestion control
796+ * needs ECN
797+ */
798+};
799+
800+#define TCP_BPF_IW 1001 /* Set TCP initial congestion window */
801+#define TCP_BPF_SNDCWND_CLAMP 1002 /* Set sndcwnd_clamp */
802+
673803 #endif /* _UAPI__LINUX_BPF_H__ */
include/uapi/linux/if_link.h+18−2
@@ -157,6 +157,7 @@ enum { · 156 unmodified lines
157157 IFLA_GSO_MAX_SIZE,
158158 IFLA_PAD,
159159 IFLA_XDP,
160+ IFLA_EVENT,
160161 __IFLA_MAX
161162 };
162163
@@ -890,15 +891,19 @@ enum { · 727 unmodified lines
890891 #define XDP_FLAGS_UPDATE_IF_NOEXIST (1U << 0)
891892 #define XDP_FLAGS_SKB_MODE (1U << 1)
892893 #define XDP_FLAGS_DRV_MODE (1U << 2)
894+#define XDP_FLAGS_HW_MODE (1U << 3)
895+#define XDP_FLAGS_MODES (XDP_FLAGS_SKB_MODE | \
896+ XDP_FLAGS_DRV_MODE | \
897+ XDP_FLAGS_HW_MODE)
893898 #define XDP_FLAGS_MASK (XDP_FLAGS_UPDATE_IF_NOEXIST | \
894− XDP_FLAGS_SKB_MODE | \
895− XDP_FLAGS_DRV_MODE)
899+ XDP_FLAGS_MODES)
896900
897901 /* These are stored into IFLA_XDP_ATTACHED on dump. */
898902 enum {
899903 XDP_ATTACHED_NONE = 0,
900904 XDP_ATTACHED_DRV,
901905 XDP_ATTACHED_SKB,
906+ XDP_ATTACHED_HW,
902907 };
903908
904909 enum {
@@ -906,9 +911,20 @@ enum { · 1 unmodified line
906911 IFLA_XDP_FD,
907912 IFLA_XDP_ATTACHED,
908913 IFLA_XDP_FLAGS,
914+ IFLA_XDP_PROG_ID,
909915 __IFLA_XDP_MAX,
910916 };
911917
912918 #define IFLA_XDP_MAX (__IFLA_XDP_MAX - 1)
913919
920+enum {
921+ IFLA_EVENT_NONE,
922+ IFLA_EVENT_REBOOT, /* internal reset / reboot */
923+ IFLA_EVENT_FEATURES, /* change in offload features */
924+ IFLA_EVENT_BONDING_FAILOVER, /* change in active slave */
925+ IFLA_EVENT_NOTIFY_PEERS, /* re-sent grat. arp/ndisc */
926+ IFLA_EVENT_IGMP_RESEND, /* re-sent IGMP JOIN */
927+ IFLA_EVENT_BONDING_OPTIONS, /* change in bonding options */
928+};
929+
914930 #endif /* _UAPI_LINUX_IF_LINK_H */
include/uapi/linux/mroute.h+54−0
@@ -110,6 +110,60 @@ struct igmpmsg { · 109 unmodified lines
110110 struct in_addr im_src,im_dst;
111111 };
112112
113+/* ipmr netlink table attributes */
114+enum {
115+ IPMRA_TABLE_UNSPEC,
116+ IPMRA_TABLE_ID,
117+ IPMRA_TABLE_CACHE_RES_QUEUE_LEN,
118+ IPMRA_TABLE_MROUTE_REG_VIF_NUM,
119+ IPMRA_TABLE_MROUTE_DO_ASSERT,
120+ IPMRA_TABLE_MROUTE_DO_PIM,
121+ IPMRA_TABLE_VIFS,
122+ __IPMRA_TABLE_MAX
123+};
124+#define IPMRA_TABLE_MAX (__IPMRA_TABLE_MAX - 1)
125+
126+/* ipmr netlink vif attribute format
127+ * [ IPMRA_TABLE_VIFS ] - nested attribute
128+ * [ IPMRA_VIF ] - nested attribute
129+ * [ IPMRA_VIFA_xxx ]
130+ */
131+enum {
132+ IPMRA_VIF_UNSPEC,
133+ IPMRA_VIF,
134+ __IPMRA_VIF_MAX
135+};
136+#define IPMRA_VIF_MAX (__IPMRA_VIF_MAX - 1)
137+
138+/* vif-specific attributes */
139+enum {
140+ IPMRA_VIFA_UNSPEC,
141+ IPMRA_VIFA_IFINDEX,
142+ IPMRA_VIFA_VIF_ID,
143+ IPMRA_VIFA_FLAGS,
144+ IPMRA_VIFA_BYTES_IN,
145+ IPMRA_VIFA_BYTES_OUT,
146+ IPMRA_VIFA_PACKETS_IN,
147+ IPMRA_VIFA_PACKETS_OUT,
148+ IPMRA_VIFA_LOCAL_ADDR,
149+ IPMRA_VIFA_REMOTE_ADDR,
150+ IPMRA_VIFA_PAD,
151+ __IPMRA_VIFA_MAX
152+};
153+#define IPMRA_VIFA_MAX (__IPMRA_VIFA_MAX - 1)
154+
155+/* ipmr netlink cache report attributes */
156+enum {
157+ IPMRA_CREPORT_UNSPEC,
158+ IPMRA_CREPORT_MSGTYPE,
159+ IPMRA_CREPORT_VIF_ID,
160+ IPMRA_CREPORT_SRC_ADDR,
161+ IPMRA_CREPORT_DST_ADDR,
162+ IPMRA_CREPORT_PKT,
163+ __IPMRA_CREPORT_MAX
164+};
165+#define IPMRA_CREPORT_MAX (__IPMRA_CREPORT_MAX - 1)
166+
113167 /* That's all usermode folks */
114168
115169 #define MFC_ASSERT_THRESH (3*HZ) /* Maximal freq. of asserts */
include/uapi/linux/mroute6.h+12−0
@@ -133,4 +133,16 @@ struct mrt6msg { · 132 unmodified lines
133133 struct in6_addr im6_src, im6_dst;
134134 };
135135
136+/* ip6mr netlink cache report attributes */
137+enum {
138+ IP6MRA_CREPORT_UNSPEC,
139+ IP6MRA_CREPORT_MSGTYPE,
140+ IP6MRA_CREPORT_MIF_ID,
141+ IP6MRA_CREPORT_SRC_ADDR,
142+ IP6MRA_CREPORT_DST_ADDR,
143+ IP6MRA_CREPORT_PKT,
144+ __IP6MRA_CREPORT_MAX
145+};
146+#define IP6MRA_CREPORT_MAX (__IP6MRA_CREPORT_MAX - 1)
147+
136148 #endif /* _UAPI__LINUX_MROUTE6_H */
include/uapi/linux/neighbour.h+1−0
@@ -41,6 +41,7 @@ enum { · 40 unmodified lines
4141 #define NTF_MASTER 0x04
4242 #define NTF_PROXY 0x08 /* == ATF_PUBL */
4343 #define NTF_EXT_LEARNED 0x10
44+#define NTF_OFFLOADED 0x20
4445 #define NTF_ROUTER 0x80
4546
4647 /*
include/uapi/linux/net_tstamp.h+14−1
@@ -9,6 +9,7 @@ · 8 unmodified lines
99 #ifndef _NET_TIMESTAMPING_H
1010 #define _NET_TIMESTAMPING_H
1111
12+#include <linux/types.h>
1213 #include <linux/socket.h> /* for SO_TIMESTAMPING */
1314
1415 /* SO_TIMESTAMPING gets an integer bit field comprised of these values */
@@ -26,8 +27,10 @@ enum { · 11 unmodified lines
2627 SOF_TIMESTAMPING_OPT_CMSG = (1<<10),
2728 SOF_TIMESTAMPING_OPT_TSONLY = (1<<11),
2829 SOF_TIMESTAMPING_OPT_STATS = (1<<12),
30+ SOF_TIMESTAMPING_OPT_PKTINFO = (1<<13),
31+ SOF_TIMESTAMPING_OPT_TX_SWHW = (1<<14),
2932
30− SOF_TIMESTAMPING_LAST = SOF_TIMESTAMPING_OPT_STATS,
33+ SOF_TIMESTAMPING_LAST = SOF_TIMESTAMPING_OPT_TX_SWHW,
3134 SOF_TIMESTAMPING_MASK = (SOF_TIMESTAMPING_LAST - 1) |
3235 SOF_TIMESTAMPING_LAST
3336 };
@@ -125,6 +128,16 @@ enum hwtstamp_rx_filters { · 91 unmodified lines
125128 HWTSTAMP_FILTER_PTP_V2_SYNC,
126129 /* PTP v2/802.AS1, any layer, Delay_req packet */
127130 HWTSTAMP_FILTER_PTP_V2_DELAY_REQ,
131+
132+ /* NTP, UDP, all versions and packet modes */
133+ HWTSTAMP_FILTER_NTP_ALL,
134+};
135+
136+/* SCM_TIMESTAMPING_PKTINFO control message */
137+struct scm_ts_pktinfo {
138+ __u32 if_index;
139+ __u32 pkt_length;
140+ __u32 reserved[2];
128141 };
129142
130143 #endif /* _NET_TIMESTAMPING_H */
include/uapi/linux/nl80211.h+73−9
@@ -172,6 +172,29 @@ · 171 unmodified lines
172172 * Multiple such rules can be created.
173173 */
174174
175+/**
176+ * DOC: WPA/WPA2 EAPOL handshake offload
177+ *
178+ * By setting @NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_PSK flag drivers
179+ * can indicate they support offloading EAPOL handshakes for WPA/WPA2
180+ * preshared key authentication. In %NL80211_CMD_CONNECT the preshared
181+ * key should be specified using %NL80211_ATTR_PMK. Drivers supporting
182+ * this offload may reject the %NL80211_CMD_CONNECT when no preshared
183+ * key material is provided, for example when that driver does not
184+ * support setting the temporal keys through %CMD_NEW_KEY.
185+ *
186+ * Similarly @NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X flag can be
187+ * set by drivers indicating offload support of the PTK/GTK EAPOL
188+ * handshakes during 802.1X authentication. In order to use the offload
189+ * the %NL80211_CMD_CONNECT should have %NL80211_ATTR_WANT_1X_4WAY_HS
190+ * attribute flag. Drivers supporting this offload may reject the
191+ * %NL80211_CMD_CONNECT when the attribute flag is not present.
192+ *
193+ * For 802.1X the PMK or PMK-R0 are set by providing %NL80211_ATTR_PMK
194+ * using %NL80211_CMD_SET_PMK. For offloaded FT support also
195+ * %NL80211_ATTR_PMKR0_NAME must be provided.
196+ */
197+
175198 /**
176199 * DOC: FILS shared key authentication offload
177200 *
@@ -546,8 +569,13 @@ · 368 unmodified lines
546569 * authentication/association or not receiving a response from the AP.
547570 * Non-zero %NL80211_ATTR_STATUS_CODE value is indicated in that case as
548571 * well to remain backwards compatible.
549− * @NL80211_CMD_ROAM: request that the card roam (currently not implemented),
550− * sent as an event when the card/driver roamed by itself.
572+ * @NL80211_CMD_ROAM: notifcation indicating the card/driver roamed by itself.
573+ * When the driver roamed in a network that requires 802.1X authentication,
574+ * %NL80211_ATTR_PORT_AUTHORIZED should be set if the 802.1X authentication
575+ * was done by the driver or if roaming was done using Fast Transition
576+ * protocol (in which case 802.1X authentication is not needed). If
577+ * %NL80211_ATTR_PORT_AUTHORIZED is not set, user space is responsible for
578+ * the 802.1X authentication.
551579 * @NL80211_CMD_DISCONNECT: drop a given connection; also used to notify
552580 * userspace that a connection was dropped by the AP or due to other
553581 * reasons, for this the %NL80211_ATTR_DISCONNECTED_BY_AP and
@@ -947,6 +975,14 @@ · 393 unmodified lines
947975 * does not result in a change for the current association. Currently,
948976 * only the %NL80211_ATTR_IE data is used and updated with this command.
949977 *
978+ * @NL80211_CMD_SET_PMK: For offloaded 4-Way handshake, set the PMK or PMK-R0
979+ * for the given authenticator address (specified with &NL80211_ATTR_MAC).
980+ * When &NL80211_ATTR_PMKR0_NAME is set, &NL80211_ATTR_PMK specifies the
981+ * PMK-R0, otherwise it specifies the PMK.
982+ * @NL80211_CMD_DEL_PMK: For offloaded 4-Way handshake, delete the previously
983+ * configured PMK for the authenticator address identified by
984+ * &NL80211_ATTR_MAC.
985+ *
950986 * @NL80211_CMD_MAX: highest used command number
951987 * @__NL80211_CMD_AFTER_LAST: internal use
952988 */
@@ -1146,6 +1182,9 @@ enum nl80211_commands { · 193 unmodified lines
11461182
11471183 NL80211_CMD_UPDATE_CONNECT_PARAMS,
11481184
1185+ NL80211_CMD_SET_PMK,
1186+ NL80211_CMD_DEL_PMK,
1187+
11491188 /* add new commands above here */
11501189
11511190 /* used to define NL80211_CMD_MAX below */
@@ -1870,11 +1909,10 @@ enum nl80211_commands { · 718 unmodified lines
18701909 * that configured the indoor setting, and the indoor operation would be
18711910 * cleared when the socket is closed.
18721911 * If set during NAN interface creation, the interface will be destroyed
1873− * if the socket is closed just like any other interface. Moreover, only
1874− * the netlink socket that created the interface will be allowed to add
1875− * and remove functions. NAN notifications will be sent in unicast to that
1876− * socket. Without this attribute, any socket can add functions and the
1877− * notifications will be sent to the %NL80211_MCGRP_NAN multicast group.
1912+ * if the socket is closed just like any other interface. Moreover, NAN
1913+ * notifications will be sent in unicast to that socket. Without this
1914+ * attribute, the notifications will be sent to the %NL80211_MCGRP_NAN
1915+ * multicast group.
18781916 * If set during %NL80211_CMD_ASSOCIATE or %NL80211_CMD_CONNECT the
18791917 * station will deauthenticate when the socket is closed.
18801918 *
@@ -2080,14 +2118,27 @@ enum nl80211_commands { · 199 unmodified lines
20802118 * identifying the scope of PMKSAs. This is used with
20812119 * @NL80211_CMD_SET_PMKSA and @NL80211_CMD_DEL_PMKSA.
20822120 *
2083− * @NL80211_ATTR_PMK: PMK for the PMKSA identified by %NL80211_ATTR_PMKID.
2084− * This is used with @NL80211_CMD_SET_PMKSA.
2121+ * @NL80211_ATTR_PMK: attribute for passing PMK key material. Used with
2122+ * %NL80211_CMD_SET_PMKSA for the PMKSA identified by %NL80211_ATTR_PMKID.
2123+ * For %NL80211_CMD_CONNECT it is used to provide PSK for offloading 4-way
2124+ * handshake for WPA/WPA2-PSK networks. For 802.1X authentication it is
2125+ * used with %NL80211_CMD_SET_PMK. For offloaded FT support this attribute
2126+ * specifies the PMK-R0 if NL80211_ATTR_PMKR0_NAME is included as well.
20852127 *
20862128 * @NL80211_ATTR_SCHED_SCAN_MULTI: flag attribute which user-space shall use to
20872129 * indicate that it supports multiple active scheduled scan requests.
20882130 * @NL80211_ATTR_SCHED_SCAN_MAX_REQS: indicates maximum number of scheduled
20892131 * scan request that may be active for the device (u32).
20902132 *
2133+ * @NL80211_ATTR_WANT_1X_4WAY_HS: flag attribute which user-space can include
2134+ * in %NL80211_CMD_CONNECT to indicate that for 802.1X authentication it
2135+ * wants to use the supported offload of the 4-way handshake.
2136+ * @NL80211_ATTR_PMKR0_NAME: PMK-R0 Name for offloaded FT.
2137+ * @NL80211_ATTR_PORT_AUTHORIZED: flag attribute used in %NL80211_CMD_ROAMED
2138+ * notification indicating that that 802.1X authentication was done by
2139+ * the driver or is not needed (because roaming used the Fast Transition
2140+ * protocol).
2141+ *
20912142 * @NUM_NL80211_ATTR: total number of nl80211_attrs available
20922143 * @NL80211_ATTR_MAX: highest attribute number currently defined
20932144 * @__NL80211_ATTR_AFTER_LAST: internal use
@@ -2510,6 +2561,10 @@ enum nl80211_attrs { · 416 unmodified lines
25102561 NL80211_ATTR_SCHED_SCAN_MULTI,
25112562 NL80211_ATTR_SCHED_SCAN_MAX_REQS,
25122563
2564+ NL80211_ATTR_WANT_1X_4WAY_HS,
2565+ NL80211_ATTR_PMKR0_NAME,
2566+ NL80211_ATTR_PORT_AUTHORIZED,
2567+
25132568 /* add attributes here, update the policy in nl80211.c */
25142569
25152570 __NL80211_ATTR_AFTER_LAST,
@@ -4852,6 +4907,13 @@ enum nl80211_feature_flags { · 2336 unmodified lines
48524907 * RSSI threshold values to monitor rather than exactly one threshold.
48534908 * @NL80211_EXT_FEATURE_FILS_SK_OFFLOAD: Driver SME supports FILS shared key
48544909 * authentication with %NL80211_CMD_CONNECT.
4910+ * @NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_PSK: Device wants to do 4-way
4911+ * handshake with PSK in station mode (PSK is passed as part of the connect
4912+ * and associate commands), doing it in the host might not be supported.
4913+ * @NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X: Device wants to do doing 4-way
4914+ * handshake with 802.1X in station mode (will pass EAP frames to the host
4915+ * and accept the set_pmk/del_pmk commands), doing it in the host might not
4916+ * be supported.
48554917 *
48564918 * @NUM_NL80211_EXT_FEATURES: number of extended features.
48574919 * @MAX_NL80211_EXT_FEATURES: highest extended feature index.
@@ -4872,6 +4934,8 @@ enum nl80211_ext_feature_index { · 14 unmodified lines
48724934 NL80211_EXT_FEATURE_SCHED_SCAN_RELATIVE_RSSI,
48734935 NL80211_EXT_FEATURE_CQM_RSSI_LIST,
48744936 NL80211_EXT_FEATURE_FILS_SK_OFFLOAD,
4937+ NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_PSK,
4938+ NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X,
48754939
48764940 /* add new features before the definition below */
48774941 NUM_NL80211_EXT_FEATURES,
include/uapi/linux/pkt_cls.h+17−0
@@ -37,6 +37,13 @@ enum { · 36 unmodified lines
3737 #define TC_ACT_QUEUED 5
3838 #define TC_ACT_REPEAT 6
3939 #define TC_ACT_REDIRECT 7
40+#define TC_ACT_TRAP 8 /* For hw path, this means "trap to cpu"
41+ * and don't further process the frame
42+ * in hardware. For sw path, this is
43+ * equivalent of TC_ACT_STOLEN - drop
44+ * the skb and act like everything
45+ * is alright.
46+ */
4047
4148 /* There is a special kind of actions called "extended actions",
4249 * which need a value parameter. These have a local opcode located in
@@ -51,6 +58,7 @@ enum { · 8 unmodified lines
5158 (((combined) & (~TC_ACT_EXT_VAL_MASK)) == opcode)
5259
5360 #define TC_ACT_JUMP __TC_ACT_EXT(1)
61+#define TC_ACT_GOTO_CHAIN __TC_ACT_EXT(2)
5462
5563 /* Action type identifiers*/
5664 enum {
@@ -361,6 +369,7 @@ enum { · 304 unmodified lines
361369 TCA_BPF_FLAGS,
362370 TCA_BPF_FLAGS_GEN,
363371 TCA_BPF_TAG,
372+ TCA_BPF_ID,
364373 __TCA_BPF_MAX,
365374 };
366375
@@ -450,6 +459,14 @@ enum { · 83 unmodified lines
450459 TCA_FLOWER_KEY_MPLS_TC, /* u8 - 3 bits */
451460 TCA_FLOWER_KEY_MPLS_LABEL, /* be32 - 20 bits */
452461
462+ TCA_FLOWER_KEY_TCP_FLAGS, /* be16 */
463+ TCA_FLOWER_KEY_TCP_FLAGS_MASK, /* be16 */
464+
465+ TCA_FLOWER_KEY_IP_TOS, /* u8 */
466+ TCA_FLOWER_KEY_IP_TOS_MASK, /* u8 */
467+ TCA_FLOWER_KEY_IP_TTL, /* u8 */
468+ TCA_FLOWER_KEY_IP_TTL_MASK, /* u8 */
469+
453470 __TCA_FLOWER_MAX,
454471 };
455472
include/uapi/linux/rtnetlink.h+9−0
@@ -146,6 +146,9 @@ enum { · 145 unmodified lines
146146 RTM_GETSTATS = 94,
147147 #define RTM_GETSTATS RTM_GETSTATS
148148
149+ RTM_NEWCACHEREPORT = 96,
150+#define RTM_NEWCACHEREPORT RTM_NEWCACHEREPORT
151+
149152 __RTM_MAX,
150153 #define RTM_MAX (((__RTM_MAX + 3) & ~3) - 1)
151154 };
@@ -278,6 +281,7 @@ enum rt_scope_t { · 126 unmodified lines
278281 #define RTM_F_EQUALIZE 0x400 /* Multipath equalizer: NI */
279282 #define RTM_F_PREFIX 0x800 /* Prefix addresses */
280283 #define RTM_F_LOOKUP_TABLE 0x1000 /* set rtm_table to FIB lookup result */
284+#define RTM_F_FIB_MATCH 0x2000 /* return full fib lookup match */
281285
282286 /* Reserved table identifiers */
283287
@@ -549,6 +553,7 @@ enum { · 265 unmodified lines
549553 TCA_STAB,
550554 TCA_PAD,
551555 TCA_DUMP_INVISIBLE,
556+ TCA_CHAIN,
552557 __TCA_MAX
553558 };
554559
@@ -664,6 +669,10 @@ enum rtnetlink_groups { · 109 unmodified lines
664669 #define RTNLGRP_NSID RTNLGRP_NSID
665670 RTNLGRP_MPLS_NETCONF,
666671 #define RTNLGRP_MPLS_NETCONF RTNLGRP_MPLS_NETCONF
672+ RTNLGRP_IPV4_MROUTE_R,
673+#define RTNLGRP_IPV4_MROUTE_R RTNLGRP_IPV4_MROUTE_R
674+ RTNLGRP_IPV6_MROUTE_R,
675+#define RTNLGRP_IPV6_MROUTE_R RTNLGRP_IPV6_MROUTE_R
667676 __RTNLGRP_MAX
668677 };
669678 #define RTNLGRP_MAX (__RTNLGRP_MAX - 1)
include/uapi/linux/sctp.h+6−0
@@ -121,6 +121,7 @@ typedef __s32 sctp_assoc_t; · 120 unmodified lines
121121 #define SCTP_RESET_STREAMS 119
122122 #define SCTP_RESET_ASSOC 120
123123 #define SCTP_ADD_STREAMS 121
124+#define SCTP_SOCKOPT_PEELOFF_FLAGS 122
124125
125126 /* PR-SCTP policies */
126127 #define SCTP_PR_SCTP_NONE 0x0000
@@ -978,6 +979,11 @@ typedef struct { · 851 unmodified lines
978979 int sd;
979980 } sctp_peeloff_arg_t;
980981
982+typedef struct {
983+ sctp_peeloff_arg_t p_arg;
984+ unsigned flags;
985+} sctp_peeloff_flags_arg_t;
986+
981987 /*
982988 * Peer Address Thresholds socket option
983989 */
include/uapi/linux/snmp.h+1−0
@@ -228,6 +228,7 @@ enum · 227 unmodified lines
228228 LINUX_MIB_TCPABORTONLINGER, /* TCPAbortOnLinger */
229229 LINUX_MIB_TCPABORTFAILED, /* TCPAbortFailed */
230230 LINUX_MIB_TCPMEMORYPRESSURES, /* TCPMemoryPressures */
231+ LINUX_MIB_TCPMEMORYPRESSURESCHRONO, /* TCPMemoryPressuresChrono */
231232 LINUX_MIB_TCPSACKDISCARD, /* TCPSACKDiscard */
232233 LINUX_MIB_TCPDSACKIGNOREDOLD, /* TCPSACKIgnoredOld */
233234 LINUX_MIB_TCPDSACKIGNOREDNOUNDO, /* TCPSACKIgnoredNoUndo */
include/uapi/linux/tc_act/tc_bpf.h+1−0
@@ -28,6 +28,7 @@ enum { · 27 unmodified lines
2828 TCA_ACT_BPF_NAME,
2929 TCA_ACT_BPF_PAD,
3030 TCA_ACT_BPF_TAG,
31+ TCA_ACT_BPF_ID,
3132 __TCA_ACT_BPF_MAX,
3233 };
3334 #define TCA_ACT_BPF_MAX (__TCA_ACT_BPF_MAX - 1)
include/uapi/linux/tc_act/tc_tunnel_key.h+1−0
@@ -34,6 +34,7 @@ enum { · 33 unmodified lines
3434 TCA_TUNNEL_KEY_ENC_KEY_ID, /* be64 */
3535 TCA_TUNNEL_KEY_PAD,
3636 TCA_TUNNEL_KEY_ENC_DST_PORT, /* be16 */
37+ TCA_TUNNEL_KEY_NO_CSUM, /* u8 */
3738 __TCA_TUNNEL_KEY_MAX,
3839 };
3940
include/uapi/linux/tcp.h+8−2
@@ -117,6 +117,8 @@ enum { · 116 unmodified lines
117117 #define TCP_SAVED_SYN 28 /* Get SYN headers recorded for connection */
118118 #define TCP_REPAIR_WINDOW 29 /* Get/set window parameters */
119119 #define TCP_FASTOPEN_CONNECT 30 /* Attempt FastOpen with connect */
120+#define TCP_ULP 31 /* Attach a ULP to a TCP connection */
121+#define TCP_MD5SIG_EXT 32 /* TCP MD5 Signature with extensions */
120122
121123 struct tcp_repair_opt {
122124 __u32 opt_code;
@@ -234,11 +236,15 @@ enum { · 111 unmodified lines
234236 /* for TCP_MD5SIG socket option */
235237 #define TCP_MD5SIG_MAXKEYLEN 80
236238
239+/* tcp_md5sig extension flags for TCP_MD5SIG_EXT */
240+#define TCP_MD5SIG_FLAG_PREFIX 1 /* address prefix length */
241+
237242 struct tcp_md5sig {
238243 struct __kernel_sockaddr_storage tcpm_addr; /* address associated */
239− __u16 __tcpm_pad1; /* zero */
244+ __u8 tcpm_flags; /* extension flags */
245+ __u8 tcpm_prefixlen; /* address prefix */
240246 __u16 tcpm_keylen; /* key length */
241− __u32 __tcpm_pad2; /* zero */
247+ __u32 __tcpm_pad; /* zero */
242248 __u8 tcpm_key[TCP_MD5SIG_MAXKEYLEN]; /* key (binary) */
243249 };
244250
include/uapi/linux/tls.h+79−0
@@ -0,0 +1,79 @@
1+/*
2+ * Copyright (c) 2016-2017, Mellanox Technologies. All rights reserved.
3+ *
4+ * This software is available to you under a choice of one of two
5+ * licenses. You may choose to be licensed under the terms of the GNU
6+ * General Public License (GPL) Version 2, available from the file
7+ * COPYING in the main directory of this source tree, or the
8+ * OpenIB.org BSD license below:
9+ *
10+ * Redistribution and use in source and binary forms, with or
11+ * without modification, are permitted provided that the following
12+ * conditions are met:
13+ *
14+ * - Redistributions of source code must retain the above
15+ * copyright notice, this list of conditions and the following
16+ * disclaimer.
17+ *
18+ * - Redistributions in binary form must reproduce the above
19+ * copyright notice, this list of conditions and the following
20+ * disclaimer in the documentation and/or other materials
21+ * provided with the distribution.
22+ *
23+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30+ * SOFTWARE.
31+ */
32+
33+#ifndef _UAPI_LINUX_TLS_H
34+#define _UAPI_LINUX_TLS_H
35+
36+#include <linux/types.h>
37+#include <asm/byteorder.h>
38+#include <linux/socket.h>
39+#include <linux/tcp.h>
40+#include <net/tcp.h>
41+
42+/* TLS socket options */
43+#define TLS_TX 1 /* Set transmit parameters */
44+
45+/* Supported versions */
46+#define TLS_VERSION_MINOR(ver) ((ver) & 0xFF)
47+#define TLS_VERSION_MAJOR(ver) (((ver) >> 8) & 0xFF)
48+
49+#define TLS_VERSION_NUMBER(id) ((((id##_VERSION_MAJOR) & 0xFF) << 8) | \
50+ ((id##_VERSION_MINOR) & 0xFF))
51+
52+#define TLS_1_2_VERSION_MAJOR 0x3
53+#define TLS_1_2_VERSION_MINOR 0x3
54+#define TLS_1_2_VERSION TLS_VERSION_NUMBER(TLS_1_2)
55+
56+/* Supported ciphers */
57+#define TLS_CIPHER_AES_GCM_128 51
58+#define TLS_CIPHER_AES_GCM_128_IV_SIZE 8
59+#define TLS_CIPHER_AES_GCM_128_KEY_SIZE 16
60+#define TLS_CIPHER_AES_GCM_128_SALT_SIZE 4
61+#define TLS_CIPHER_AES_GCM_128_TAG_SIZE 16
62+#define TLS_CIPHER_AES_GCM_128_REC_SEQ_SIZE 8
63+
64+#define TLS_SET_RECORD_TYPE 1
65+
66+struct tls_crypto_info {
67+ __u16 version;
68+ __u16 cipher_type;
69+};
70+
71+struct tls12_crypto_info_aes_gcm_128 {
72+ struct tls_crypto_info info;
73+ unsigned char iv[TLS_CIPHER_AES_GCM_128_IV_SIZE];
74+ unsigned char key[TLS_CIPHER_AES_GCM_128_KEY_SIZE];
75+ unsigned char salt[TLS_CIPHER_AES_GCM_128_SALT_SIZE];
76+ unsigned char rec_seq[TLS_CIPHER_AES_GCM_128_REC_SEQ_SIZE];
77+};
78+
79+#endif /* _UAPI_LINUX_TLS_H */
include/uapi/linux/wil6210_uapi.h+0−87
@@ -1,87 +0,0 @@
1−/*
2− * Copyright (c) 2014 Qualcomm Atheros, Inc.
3− *
4− * Permission to use, copy, modify, and/or distribute this software for any
5− * purpose with or without fee is hereby granted, provided that the above
6− * copyright notice and this permission notice appear in all copies.
7− *
8− * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9− * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10− * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11− * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12− * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13− * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14− * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15− */
16−
17−#ifndef __WIL6210_UAPI_H__
18−#define __WIL6210_UAPI_H__
19−
20−#if !defined(__KERNEL__)
21−#define __user
22−#endif
23−
24−#include <linux/sockios.h>
25−
26−/* Numbers SIOCDEVPRIVATE and SIOCDEVPRIVATE + 1
27− * are used by Android devices to implement PNO (preferred network offload).
28− * Albeit it is temporary solution, use different numbers to avoid conflicts
29− */
30−
31−/**
32− * Perform 32-bit I/O operation to the card memory
33− *
34− * User code should arrange data in memory like this:
35− *
36− * struct wil_memio io;
37− * struct ifreq ifr = {
38− * .ifr_data = &io,
39− * };
40− */
41−#define WIL_IOCTL_MEMIO (SIOCDEVPRIVATE + 2)
42−
43−/**
44− * Perform block I/O operation to the card memory
45− *
46− * User code should arrange data in memory like this:
47− *
48− * void *buf;
49− * struct wil_memio_block io = {
50− * .block = buf,
51− * };
52− * struct ifreq ifr = {
53− * .ifr_data = &io,
54− * };
55− */
56−#define WIL_IOCTL_MEMIO_BLOCK (SIOCDEVPRIVATE + 3)
57−
58−/**
59− * operation to perform
60− *
61− * @wil_mmio_op_mask - bits defining operation,
62− * @wil_mmio_addr_mask - bits defining addressing mode
63− */
64−enum wil_memio_op {
65− wil_mmio_read = 0,
66− wil_mmio_write = 1,
67− wil_mmio_op_mask = 0xff,
68− wil_mmio_addr_linker = 0 << 8,
69− wil_mmio_addr_ahb = 1 << 8,
70− wil_mmio_addr_bar = 2 << 8,
71− wil_mmio_addr_mask = 0xff00,
72−};
73−
74−struct wil_memio {
75− uint32_t op; /* enum wil_memio_op */
76− uint32_t addr; /* should be 32-bit aligned */
77− uint32_t val;
78−};
79−
80−struct wil_memio_block {
81− uint32_t op; /* enum wil_memio_op */
82− uint32_t addr; /* should be 32-bit aligned */
83− uint32_t size; /* should be multiple of 4 */
84− void __user *block; /* block address */
85−};
86−
87−#endif /* __WIL6210_UAPI_H__ */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t