Update to v6.6 kernel headers.
Kernel headers coming from:
Git: https://android.googlesource.com/kernel/common/
Branch: android-mainline
Tag: android-mainline-6.6
Test: Builds and bionic unit tests pass on raven.
Test: Able to log in to an Android GO 32 bit device.
Change-Id: Ib5ff5a23f382721d98d1e428a295c6794b190d8d
diff --git a/libc/kernel/uapi/linux/bpf.h b/libc/kernel/uapi/linux/bpf.h
index 48ec710..835be41 100644
--- a/libc/kernel/uapi/linux/bpf.h
+++ b/libc/kernel/uapi/linux/bpf.h
@@ -23,6 +23,7 @@
#define BPF_JMP32 0x06
#define BPF_ALU64 0x07
#define BPF_DW 0x18
+#define BPF_MEMSX 0x80
#define BPF_ATOMIC 0xc0
#define BPF_XADD 0xc0
#define BPF_MOV 0xb0
@@ -253,6 +254,9 @@
BPF_LSM_CGROUP,
BPF_STRUCT_OPS,
BPF_NETFILTER,
+ BPF_TCX_INGRESS,
+ BPF_TCX_EGRESS,
+ BPF_TRACE_UPROBE_MULTI,
__MAX_BPF_ATTACH_TYPE
};
#define MAX_BPF_ATTACH_TYPE __MAX_BPF_ATTACH_TYPE
@@ -268,11 +272,26 @@
BPF_LINK_TYPE_KPROBE_MULTI = 8,
BPF_LINK_TYPE_STRUCT_OPS = 9,
BPF_LINK_TYPE_NETFILTER = 10,
+ BPF_LINK_TYPE_TCX = 11,
+ BPF_LINK_TYPE_UPROBE_MULTI = 12,
MAX_BPF_LINK_TYPE,
};
+enum bpf_perf_event_type {
+ BPF_PERF_EVENT_UNSPEC = 0,
+ BPF_PERF_EVENT_UPROBE = 1,
+ BPF_PERF_EVENT_URETPROBE = 2,
+ BPF_PERF_EVENT_KPROBE = 3,
+ BPF_PERF_EVENT_KRETPROBE = 4,
+ BPF_PERF_EVENT_TRACEPOINT = 5,
+ BPF_PERF_EVENT_EVENT = 6,
+};
#define BPF_F_ALLOW_OVERRIDE (1U << 0)
#define BPF_F_ALLOW_MULTI (1U << 1)
#define BPF_F_REPLACE (1U << 2)
+#define BPF_F_BEFORE (1U << 3)
+#define BPF_F_AFTER (1U << 4)
+#define BPF_F_ID (1U << 5)
+#define BPF_F_LINK BPF_F_LINK
#define BPF_F_STRICT_ALIGNMENT (1U << 0)
#define BPF_F_ANY_ALIGNMENT (1U << 1)
#define BPF_F_TEST_RND_HI32 (1U << 2)
@@ -280,7 +299,13 @@
#define BPF_F_SLEEPABLE (1U << 4)
#define BPF_F_XDP_HAS_FRAGS (1U << 5)
#define BPF_F_XDP_DEV_BOUND_ONLY (1U << 6)
-#define BPF_F_KPROBE_MULTI_RETURN (1U << 0)
+enum {
+ BPF_F_KPROBE_MULTI_RETURN = (1U << 0)
+};
+enum {
+ BPF_F_UPROBE_MULTI_RETURN = (1U << 0)
+};
+#define BPF_F_NETFILTER_IP_DEFRAG (1U << 0)
#define BPF_PSEUDO_MAP_FD 1
#define BPF_PSEUDO_MAP_IDX 5
#define BPF_PSEUDO_MAP_VALUE 2
@@ -407,11 +432,19 @@
__s32 path_fd;
};
struct {
- __u32 target_fd;
+ union {
+ __u32 target_fd;
+ __u32 target_ifindex;
+ };
__u32 attach_bpf_fd;
__u32 attach_type;
__u32 attach_flags;
__u32 replace_bpf_fd;
+ union {
+ __u32 relative_fd;
+ __u32 relative_id;
+ };
+ __u64 expected_revision;
};
struct {
__u32 prog_fd;
@@ -447,13 +480,23 @@
__aligned_u64 info;
} info;
struct {
- __u32 target_fd;
+ union {
+ __u32 target_fd;
+ __u32 target_ifindex;
+ };
__u32 attach_type;
__u32 query_flags;
__u32 attach_flags;
__aligned_u64 prog_ids;
- __u32 prog_cnt;
+ union {
+ __u32 prog_cnt;
+ __u32 count;
+ };
+ __u32 : 32;
__aligned_u64 prog_attach_flags;
+ __aligned_u64 link_ids;
+ __aligned_u64 link_attach_flags;
+ __u64 revision;
} query;
struct {
__u64 name;
@@ -515,6 +558,22 @@
__s32 priority;
__u32 flags;
} netfilter;
+ struct {
+ union {
+ __u32 relative_fd;
+ __u32 relative_id;
+ };
+ __u64 expected_revision;
+ } tcx;
+ struct {
+ __aligned_u64 path;
+ __aligned_u64 offsets;
+ __aligned_u64 ref_ctr_offsets;
+ __aligned_u64 cookies;
+ __u32 cnt;
+ __u32 flags;
+ __u32 pid;
+ } uprobe_multi;
};
} link_create;
struct {
@@ -805,6 +864,12 @@
} ipv6;
};
};
+enum tcx_action_base {
+ TCX_NEXT = - 1,
+ TCX_PASS = 0,
+ TCX_DROP = 2,
+ TCX_REDIRECT = 7,
+};
struct bpf_xdp_sock {
__u32 queue_id;
};
@@ -987,6 +1052,40 @@
__s32 priority;
__u32 flags;
} netfilter;
+ struct {
+ __aligned_u64 addrs;
+ __u32 count;
+ __u32 flags;
+ } kprobe_multi;
+ struct {
+ __u32 type;
+ __u32 : 32;
+ union {
+ struct {
+ __aligned_u64 file_name;
+ __u32 name_len;
+ __u32 offset;
+ } uprobe;
+ struct {
+ __aligned_u64 func_name;
+ __u32 name_len;
+ __u32 offset;
+ __u64 addr;
+ } kprobe;
+ struct {
+ __aligned_u64 tp_name;
+ __u32 name_len;
+ } tracepoint;
+ struct {
+ __u64 config;
+ __u32 type;
+ } event;
+ };
+ } perf_event;
+ struct {
+ __u32 ifindex;
+ __u32 attach_type;
+ } tcx;
};
} __attribute__((aligned(8)));
struct bpf_sock_addr {
@@ -1261,6 +1360,7 @@
struct bpf_list_node {
__u64 : 64;
__u64 : 64;
+ __u64 : 64;
} __attribute__((aligned(8)));
struct bpf_rb_root {
__u64 : 64;
@@ -1270,6 +1370,7 @@
__u64 : 64;
__u64 : 64;
__u64 : 64;
+ __u64 : 64;
} __attribute__((aligned(8)));
struct bpf_refcount {
__u32 : 32;