]> git.proxmox.com Git - mirror_iproute2.git/commitdiff
Update kernel headers
authorDavid Ahern <dsahern@gmail.com>
Tue, 31 Mar 2020 23:23:28 +0000 (23:23 +0000)
committerDavid Ahern <dsahern@gmail.com>
Tue, 31 Mar 2020 23:23:28 +0000 (23:23 +0000)
Update kernel headers to commit:
    7f80ccfe9968 ("net: ipv6: rpl_iptunnel: Fix potential memory leak in rpl_do_srh_inline")

Signed-off-by: David Ahern <dsahern@gmail.com>
include/uapi/linux/bpf.h
include/uapi/linux/devlink.h
include/uapi/linux/if_link.h
include/uapi/linux/inet_diag.h
include/uapi/linux/lwtunnel.h
include/uapi/linux/pkt_cls.h
include/uapi/linux/pkt_sched.h

index 28667ac44c6b87b176e5a34faa4a702309b88bf8..c7b2ffb2cf1833885536386a03920e0bef8fda18 100644 (file)
@@ -111,6 +111,8 @@ enum bpf_cmd {
        BPF_MAP_LOOKUP_AND_DELETE_BATCH,
        BPF_MAP_UPDATE_BATCH,
        BPF_MAP_DELETE_BATCH,
+       BPF_LINK_CREATE,
+       BPF_LINK_UPDATE,
 };
 
 enum bpf_map_type {
@@ -181,6 +183,7 @@ enum bpf_prog_type {
        BPF_PROG_TYPE_TRACING,
        BPF_PROG_TYPE_STRUCT_OPS,
        BPF_PROG_TYPE_EXT,
+       BPF_PROG_TYPE_LSM,
 };
 
 enum bpf_attach_type {
@@ -211,6 +214,7 @@ enum bpf_attach_type {
        BPF_TRACE_FENTRY,
        BPF_TRACE_FEXIT,
        BPF_MODIFY_RETURN,
+       BPF_LSM_MAC,
        __MAX_BPF_ATTACH_TYPE
 };
 
@@ -539,7 +543,7 @@ union bpf_attr {
                __u32           prog_cnt;
        } query;
 
-       struct {
+       struct { /* anonymous struct used by BPF_RAW_TRACEPOINT_OPEN command */
                __u64 name;
                __u32 prog_fd;
        } raw_tracepoint;
@@ -567,6 +571,24 @@ union bpf_attr {
                __u64           probe_offset;   /* output: probe_offset */
                __u64           probe_addr;     /* output: probe_addr */
        } task_fd_query;
+
+       struct { /* struct used by BPF_LINK_CREATE command */
+               __u32           prog_fd;        /* eBPF program to attach */
+               __u32           target_fd;      /* object to attach to */
+               __u32           attach_type;    /* attach type */
+               __u32           flags;          /* extra flags */
+       } link_create;
+
+       struct { /* struct used by BPF_LINK_UPDATE command */
+               __u32           link_fd;        /* link fd */
+               /* new program fd to update link with */
+               __u32           new_prog_fd;
+               __u32           flags;          /* extra flags */
+               /* expected link's program fd; is specified only if
+                * BPF_F_REPLACE flag is set in flags */
+               __u32           old_prog_fd;
+       } link_update;
+
 } __attribute__((aligned(8)));
 
 /* The description below is an attempt at providing documentation to eBPF
@@ -2950,6 +2972,59 @@ union bpf_attr {
  *             restricted to raw_tracepoint bpf programs.
  *     Return
  *             0 on success, or a negative error in case of failure.
+ *
+ * u64 bpf_get_netns_cookie(void *ctx)
+ *     Description
+ *             Retrieve the cookie (generated by the kernel) of the network
+ *             namespace the input *ctx* is associated with. The network
+ *             namespace cookie remains stable for its lifetime and provides
+ *             a global identifier that can be assumed unique. If *ctx* is
+ *             NULL, then the helper returns the cookie for the initial
+ *             network namespace. The cookie itself is very similar to that
+ *             of bpf_get_socket_cookie() helper, but for network namespaces
+ *             instead of sockets.
+ *     Return
+ *             A 8-byte long opaque number.
+ *
+ * u64 bpf_get_current_ancestor_cgroup_id(int ancestor_level)
+ *     Description
+ *             Return id of cgroup v2 that is ancestor of the cgroup associated
+ *             with the current task at the *ancestor_level*. The root cgroup
+ *             is at *ancestor_level* zero and each step down the hierarchy
+ *             increments the level. If *ancestor_level* == level of cgroup
+ *             associated with the current task, then return value will be the
+ *             same as that of **bpf_get_current_cgroup_id**\ ().
+ *
+ *             The helper is useful to implement policies based on cgroups
+ *             that are upper in hierarchy than immediate cgroup associated
+ *             with the current task.
+ *
+ *             The format of returned id and helper limitations are same as in
+ *             **bpf_get_current_cgroup_id**\ ().
+ *     Return
+ *             The id is returned or 0 in case the id could not be retrieved.
+ *
+ * int bpf_sk_assign(struct sk_buff *skb, struct bpf_sock *sk, u64 flags)
+ *     Description
+ *             Assign the *sk* to the *skb*. When combined with appropriate
+ *             routing configuration to receive the packet towards the socket,
+ *             will cause *skb* to be delivered to the specified socket.
+ *             Subsequent redirection of *skb* via  **bpf_redirect**\ (),
+ *             **bpf_clone_redirect**\ () or other methods outside of BPF may
+ *             interfere with successful delivery to the socket.
+ *
+ *             This operation is only valid from TC ingress path.
+ *
+ *             The *flags* argument must be zero.
+ *     Return
+ *             0 on success, or a negative errno in case of failure.
+ *
+ *             * **-EINVAL**           Unsupported flags specified.
+ *             * **-ENOENT**           Socket is unavailable for assignment.
+ *             * **-ENETUNREACH**      Socket is unreachable (wrong netns).
+ *             * **-EOPNOTSUPP**       Unsupported operation, for example a
+ *                                     call from outside of TC ingress.
+ *             * **-ESOCKTNOSUPPORT**  Socket type not supported (reuseport).
  */
 #define __BPF_FUNC_MAPPER(FN)          \
        FN(unspec),                     \
@@ -3073,7 +3148,10 @@ union bpf_attr {
        FN(jiffies64),                  \
        FN(read_branch_records),        \
        FN(get_ns_current_pid_tgid),    \
-       FN(xdp_output),
+       FN(xdp_output),                 \
+       FN(get_netns_cookie),           \
+       FN(get_current_ancestor_cgroup_id),     \
+       FN(sk_assign),
 
 /* integer value in 'imm' field of BPF_CALL instruction selects which helper
  * function eBPF program intends to call
index 1b412281db23e1dc9d85dcab58acafb48d61bb31..80e33d2503fc30b1dcbb38a4c9cc46be40afb794 100644 (file)
@@ -117,6 +117,11 @@ enum devlink_command {
        DEVLINK_CMD_TRAP_GROUP_NEW,
        DEVLINK_CMD_TRAP_GROUP_DEL,
 
+       DEVLINK_CMD_TRAP_POLICER_GET,   /* can dump */
+       DEVLINK_CMD_TRAP_POLICER_SET,
+       DEVLINK_CMD_TRAP_POLICER_NEW,
+       DEVLINK_CMD_TRAP_POLICER_DEL,
+
        /* add new commands above here */
        __DEVLINK_CMD_MAX,
        DEVLINK_CMD_MAX = __DEVLINK_CMD_MAX - 1
@@ -217,6 +222,7 @@ enum devlink_param_reset_dev_on_drv_probe_value {
 enum {
        DEVLINK_ATTR_STATS_RX_PACKETS,          /* u64 */
        DEVLINK_ATTR_STATS_RX_BYTES,            /* u64 */
+       DEVLINK_ATTR_STATS_RX_DROPPED,          /* u64 */
 
        __DEVLINK_ATTR_STATS_MAX,
        DEVLINK_ATTR_STATS_MAX = __DEVLINK_ATTR_STATS_MAX - 1
@@ -429,6 +435,13 @@ enum devlink_attr {
        DEVLINK_ATTR_NETNS_FD,                  /* u32 */
        DEVLINK_ATTR_NETNS_PID,                 /* u32 */
        DEVLINK_ATTR_NETNS_ID,                  /* u32 */
+
+       DEVLINK_ATTR_HEALTH_REPORTER_AUTO_DUMP, /* u8 */
+
+       DEVLINK_ATTR_TRAP_POLICER_ID,                   /* u32 */
+       DEVLINK_ATTR_TRAP_POLICER_RATE,                 /* u64 */
+       DEVLINK_ATTR_TRAP_POLICER_BURST,                /* u64 */
+
        /* add new attributes above here, update the policy in devlink.c */
 
        __DEVLINK_ATTR_MAX,
index cb88bcb4728735a85e3b608b02d0f6a1845f4610..978f98c76be17c262ff5347a5af60f0b2fbed8b6 100644 (file)
@@ -461,6 +461,7 @@ enum {
        IFLA_MACSEC_REPLAY_PROTECT,
        IFLA_MACSEC_VALIDATION,
        IFLA_MACSEC_PAD,
+       IFLA_MACSEC_OFFLOAD,
        __IFLA_MACSEC_MAX,
 };
 
@@ -487,6 +488,7 @@ enum macsec_validation_type {
 enum macsec_offload {
        MACSEC_OFFLOAD_OFF = 0,
        MACSEC_OFFLOAD_PHY = 1,
+       MACSEC_OFFLOAD_MAC = 2,
        __MACSEC_OFFLOAD_END,
        MACSEC_OFFLOAD_MAX = __MACSEC_OFFLOAD_END - 1,
 };
@@ -970,11 +972,12 @@ enum {
 #define XDP_FLAGS_SKB_MODE             (1U << 1)
 #define XDP_FLAGS_DRV_MODE             (1U << 2)
 #define XDP_FLAGS_HW_MODE              (1U << 3)
+#define XDP_FLAGS_REPLACE              (1U << 4)
 #define XDP_FLAGS_MODES                        (XDP_FLAGS_SKB_MODE | \
                                         XDP_FLAGS_DRV_MODE | \
                                         XDP_FLAGS_HW_MODE)
 #define XDP_FLAGS_MASK                 (XDP_FLAGS_UPDATE_IF_NOEXIST | \
-                                        XDP_FLAGS_MODES)
+                                        XDP_FLAGS_MODES | XDP_FLAGS_REPLACE)
 
 /* These are stored into IFLA_XDP_ATTACHED on dump. */
 enum {
@@ -994,6 +997,7 @@ enum {
        IFLA_XDP_DRV_PROG_ID,
        IFLA_XDP_SKB_PROG_ID,
        IFLA_XDP_HW_PROG_ID,
+       IFLA_XDP_EXPECTED_FD,
        __IFLA_XDP_MAX,
 };
 
index e045d170334b1709eba2eda6bbde724110175225..0c1c781c0a60f6d201d252c082487812cd426e42 100644 (file)
@@ -166,6 +166,7 @@ enum {
        INET_ULP_INFO_UNSPEC,
        INET_ULP_INFO_NAME,
        INET_ULP_INFO_TLS,
+       INET_ULP_INFO_MPTCP,
        __INET_ULP_INFO_MAX,
 };
 #define INET_ULP_INFO_MAX (__INET_ULP_INFO_MAX - 1)
index 532c9370cd55615c427c91733d79ffbd172e4703..b7c0191fd1b5f240291dc24dcc525a2520d19b81 100644 (file)
@@ -13,6 +13,7 @@ enum lwtunnel_encap_types {
        LWTUNNEL_ENCAP_SEG6,
        LWTUNNEL_ENCAP_BPF,
        LWTUNNEL_ENCAP_SEG6_LOCAL,
+       LWTUNNEL_ENCAP_RPL,
        __LWTUNNEL_ENCAP_MAX,
 };
 
index 6fcf7307e5342a3f8021ef2a3b7e37b9578ec2c2..9f06d29cab705871c3b2b78a15284b429314849c 100644 (file)
@@ -18,6 +18,7 @@ enum {
        TCA_ACT_COOKIE,
        TCA_ACT_FLAGS,
        TCA_ACT_HW_STATS,
+       TCA_ACT_USED_HW_STATS,
        __TCA_ACT_MAX
 };
 
index 7307a29a103e5191acd829c745860b637721be30..0c02737c8f47921b807e52d6482ca9ff84e89268 100644 (file)
@@ -1216,8 +1216,8 @@ enum {
  *       [TCA_TAPRIO_ATTR_SCHED_ENTRY_INTERVAL]
  */
 
-#define TCA_TAPRIO_ATTR_FLAG_TXTIME_ASSIST     BIT(0)
-#define TCA_TAPRIO_ATTR_FLAG_FULL_OFFLOAD      BIT(1)
+#define TCA_TAPRIO_ATTR_FLAG_TXTIME_ASSIST     _BITUL(0)
+#define TCA_TAPRIO_ATTR_FLAG_FULL_OFFLOAD      _BITUL(1)
 
 enum {
        TCA_TAPRIO_ATTR_UNSPEC,