From 7a53a9d93f72f95e21d7c54af1421f2b508ff397 Mon Sep 17 00:00:00 2001 From: Paul Chaignon Date: Thu, 28 Nov 2019 15:08:15 +0100 Subject: sys/linux: update BPF constants Signed-off-by: Paul Chaignon --- sys/linux/gen/386.go | 26 +++++++++++++++++--------- sys/linux/gen/amd64.go | 26 +++++++++++++++++--------- sys/linux/gen/arm.go | 26 +++++++++++++++++--------- sys/linux/gen/arm64.go | 8 +++++--- sys/linux/gen/ppc64le.go | 26 +++++++++++++++++--------- 5 files changed, 73 insertions(+), 39 deletions(-) (limited to 'sys/linux/gen') diff --git a/sys/linux/gen/386.go b/sys/linux/gen/386.go index d51b69732..4a2fc71b5 100644 --- a/sys/linux/gen/386.go +++ b/sys/linux/gen/386.go @@ -1055,7 +1055,7 @@ var structDescs_386 = []*KeyedStruct{ {Key: StructKey{Name: "bpf_attach_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_attach_arg", TypeSize: 16}, Fields: []Type{ &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_cgroup", FldName: "target_fd", TypeSize: 4}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "attach_bpf_fd", TypeSize: 4}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2}, BitMask: true}, }}}, {Key: StructKey{Name: "bpf_btf_info", Dir: 2}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_btf_info", TypeSize: 16, ArgDir: 2}, Fields: []Type{ @@ -1083,7 +1083,7 @@ var structDescs_386 = []*KeyedStruct{ {Key: StructKey{Name: "bpf_detach_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_detach_arg", TypeSize: 16}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "target", TypeSize: 4}}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "prog", TypeSize: 4}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "flags", TypeSize: 4}}}, }}}, {Key: StructKey{Name: "bpf_framed_program"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_framed_program", IsVarlen: true}, Fields: []Type{ @@ -1223,7 +1223,7 @@ var structDescs_386 = []*KeyedStruct{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "ksize", TypeSize: 4}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "vsize", TypeSize: 4}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "max", TypeSize: 4}}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "map_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8, 16, 32, 64, 128, 256, 512}, BitMask: true}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "map_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024}, BitMask: true}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_map", FldName: "inner", TypeSize: 4, IsOptional: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "node", TypeSize: 4}}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "map_name", TypeSize: 16}, Type: &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", TypeSize: 1}}}, Kind: 1, RangeBegin: 16, RangeEnd: 16}, @@ -1297,8 +1297,8 @@ var structDescs_386 = []*KeyedStruct{ {Key: StructKey{Name: "bpf_options"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_options", IsVarlen: true}, Fields: []Type{ &StructType{Key: StructKey{Name: "fs_opt[\"mode\", fmt[oct, int32]]"}, FldName: "mode"}, }}}, - {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 112}, Fields: []Type{ - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, + {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 120}, Fields: []Type{ + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize8", FldName: "ninsn", TypeSize: 4}}, BitSize: 64, Path: []string{"insns"}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "insns", TypeSize: 8}, Type: &UnionType{Key: StructKey{Name: "bpf_instructions"}}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "license", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "string", IsVarlen: true}, Kind: 2, SubKind: "bpf_licenses", Values: []string{"GPL\x00", "syzkaller\x00"}}}, @@ -1306,10 +1306,10 @@ var structDescs_386 = []*KeyedStruct{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "logsize", TypeSize: 4}}, Path: []string{"log"}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "log", TypeSize: 8, IsOptional: true}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "array", ArgDir: 1, IsVarlen: true}}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_kern_version", FldName: "kern_version", TypeSize: 4}}, Vals: []uint64{265984, 266240, 266496}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_load_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4}, BitMask: true}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_load_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8}, BitMask: true}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "prog_name", TypeSize: 16}, Type: &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", TypeSize: 1}}}, Kind: 1, RangeBegin: 16, RangeEnd: 16}, &ResourceType{TypeCommon: TypeCommon{TypeName: "ifindex", FldName: "prog_ifindex", TypeSize: 4, IsOptional: true}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "expected_attach_type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "expected_attach_type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_btf", FldName: "btf_fd", TypeSize: 4, IsOptional: true}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "func_info_rec_size", TypeSize: 4}}, Val: 8}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "func_info", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "bpf_func_info"}}}, @@ -1317,6 +1317,8 @@ var structDescs_386 = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "line_info_rec_size", TypeSize: 4}}, Val: 16}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "line_info", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "bpf_line_info"}}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "line_info_cnt", TypeSize: 4}}, Path: []string{"line_info"}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "bpf_btf_id", FldName: "attach_btf_id", TypeSize: 4, IsOptional: true}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "attach_prog_fd", TypeSize: 4, IsOptional: true}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "pad", TypeSize: 4}}, IsPad: true}, }}}, {Key: StructKey{Name: "bpf_prog_get_fd_by_id_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog_get_fd_by_id_arg", TypeSize: 12}, Fields: []Type{ @@ -16114,7 +16116,7 @@ var structDescs_386 = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 43}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "payload", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "ifla_xdp_policy"}}}, }, AlignAttr: 4}}, - {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 116}, Fields: []Type{ + {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 124}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "nla_len", TypeSize: 2}}, Path: []string{"parent"}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 1}, &StructType{Key: StructKey{Name: "bpf_prog"}, FldName: "payload"}, @@ -48235,6 +48237,7 @@ var consts_386 = []ConstValue{ {Name: "BPF_F_ANY_ALIGNMENT", Value: 2}, {Name: "BPF_F_CLONE", Value: 512}, {Name: "BPF_F_LOCK", Value: 4}, + {Name: "BPF_F_MMAPABLE", Value: 1024}, {Name: "BPF_F_NO_COMMON_LRU", Value: 2}, {Name: "BPF_F_NO_PREALLOC", Value: 1}, {Name: "BPF_F_NUMA_NODE", Value: 4}, @@ -48244,6 +48247,7 @@ var consts_386 = []ConstValue{ {Name: "BPF_F_STACK_BUILD_ID", Value: 32}, {Name: "BPF_F_STRICT_ALIGNMENT", Value: 1}, {Name: "BPF_F_TEST_RND_HI32", Value: 4}, + {Name: "BPF_F_TEST_STATE_FREQ", Value: 8}, {Name: "BPF_F_WRONLY", Value: 16}, {Name: "BPF_F_WRONLY_PROG", Value: 256}, {Name: "BPF_F_ZERO_SEED", Value: 64}, @@ -48344,6 +48348,7 @@ var consts_386 = []ConstValue{ {Name: "BPF_PROG_TYPE_SOCKET_FILTER", Value: 1}, {Name: "BPF_PROG_TYPE_SOCK_OPS", Value: 13}, {Name: "BPF_PROG_TYPE_TRACEPOINT", Value: 5}, + {Name: "BPF_PROG_TYPE_TRACING", Value: 26}, {Name: "BPF_PROG_TYPE_XDP", Value: 6}, {Name: "BPF_PSEUDO_CALL", Value: 1}, {Name: "BPF_PSEUDO_MAP_FD", Value: 1}, @@ -48368,6 +48373,9 @@ var consts_386 = []ConstValue{ {Name: "BPF_STX", Value: 3}, {Name: "BPF_SUB0", Value: 1}, {Name: "BPF_TASK_FD_QUERY", Value: 20}, + {Name: "BPF_TRACE_FENTRY", Value: 24}, + {Name: "BPF_TRACE_FEXIT", Value: 25}, + {Name: "BPF_TRACE_RAW_TP", Value: 23}, {Name: "BPF_W0"}, {Name: "BPF_XADD0", Value: 6}, {Name: "BPF_XOR0", Value: 10}, @@ -56166,4 +56174,4 @@ var consts_386 = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_386 = "1aa53e5e2c4acd3de43e0ebc83c8d14fd5cd561c" +const revision_386 = "c0474791632bc15b702cb2162944cb0b923b1414" diff --git a/sys/linux/gen/amd64.go b/sys/linux/gen/amd64.go index 53778f9f1..824126955 100644 --- a/sys/linux/gen/amd64.go +++ b/sys/linux/gen/amd64.go @@ -1058,7 +1058,7 @@ var structDescs_amd64 = []*KeyedStruct{ {Key: StructKey{Name: "bpf_attach_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_attach_arg", TypeSize: 16}, Fields: []Type{ &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_cgroup", FldName: "target_fd", TypeSize: 4}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "attach_bpf_fd", TypeSize: 4}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2}, BitMask: true}, }}}, {Key: StructKey{Name: "bpf_btf_info", Dir: 2}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_btf_info", TypeSize: 16, ArgDir: 2}, Fields: []Type{ @@ -1086,7 +1086,7 @@ var structDescs_amd64 = []*KeyedStruct{ {Key: StructKey{Name: "bpf_detach_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_detach_arg", TypeSize: 16}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "target", TypeSize: 4}}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "prog", TypeSize: 4}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "flags", TypeSize: 4}}}, }}}, {Key: StructKey{Name: "bpf_framed_program"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_framed_program", IsVarlen: true}, Fields: []Type{ @@ -1226,7 +1226,7 @@ var structDescs_amd64 = []*KeyedStruct{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "ksize", TypeSize: 4}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "vsize", TypeSize: 4}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "max", TypeSize: 4}}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "map_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8, 16, 32, 64, 128, 256, 512}, BitMask: true}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "map_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024}, BitMask: true}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_map", FldName: "inner", TypeSize: 4, IsOptional: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "node", TypeSize: 4}}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "map_name", TypeSize: 16}, Type: &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", TypeSize: 1}}}, Kind: 1, RangeBegin: 16, RangeEnd: 16}, @@ -1300,8 +1300,8 @@ var structDescs_amd64 = []*KeyedStruct{ {Key: StructKey{Name: "bpf_options"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_options", IsVarlen: true}, Fields: []Type{ &StructType{Key: StructKey{Name: "fs_opt[\"mode\", fmt[oct, int32]]"}, FldName: "mode"}, }}}, - {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 112}, Fields: []Type{ - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, + {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 120}, Fields: []Type{ + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize8", FldName: "ninsn", TypeSize: 4}}, BitSize: 64, Path: []string{"insns"}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "insns", TypeSize: 8}, Type: &UnionType{Key: StructKey{Name: "bpf_instructions"}}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "license", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "string", IsVarlen: true}, Kind: 2, SubKind: "bpf_licenses", Values: []string{"GPL\x00", "syzkaller\x00"}}}, @@ -1309,10 +1309,10 @@ var structDescs_amd64 = []*KeyedStruct{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "logsize", TypeSize: 4}}, Path: []string{"log"}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "log", TypeSize: 8, IsOptional: true}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "array", ArgDir: 1, IsVarlen: true}}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_kern_version", FldName: "kern_version", TypeSize: 4}}, Vals: []uint64{265984, 266240, 266496}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_load_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4}, BitMask: true}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_load_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8}, BitMask: true}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "prog_name", TypeSize: 16}, Type: &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", TypeSize: 1}}}, Kind: 1, RangeBegin: 16, RangeEnd: 16}, &ResourceType{TypeCommon: TypeCommon{TypeName: "ifindex", FldName: "prog_ifindex", TypeSize: 4, IsOptional: true}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "expected_attach_type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "expected_attach_type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_btf", FldName: "btf_fd", TypeSize: 4, IsOptional: true}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "func_info_rec_size", TypeSize: 4}}, Val: 8}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "func_info", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "bpf_func_info"}}}, @@ -1320,6 +1320,8 @@ var structDescs_amd64 = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "line_info_rec_size", TypeSize: 4}}, Val: 16}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "line_info", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "bpf_line_info"}}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "line_info_cnt", TypeSize: 4}}, Path: []string{"line_info"}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "bpf_btf_id", FldName: "attach_btf_id", TypeSize: 4, IsOptional: true}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "attach_prog_fd", TypeSize: 4, IsOptional: true}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "pad", TypeSize: 4}}, IsPad: true}, }}}, {Key: StructKey{Name: "bpf_prog_get_fd_by_id_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog_get_fd_by_id_arg", TypeSize: 12}, Fields: []Type{ @@ -16423,7 +16425,7 @@ var structDescs_amd64 = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 43}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "payload", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "ifla_xdp_policy"}}}, }, AlignAttr: 4}}, - {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 116}, Fields: []Type{ + {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 124}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "nla_len", TypeSize: 2}}, Path: []string{"parent"}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 1}, &StructType{Key: StructKey{Name: "bpf_prog"}, FldName: "payload"}, @@ -48775,6 +48777,7 @@ var consts_amd64 = []ConstValue{ {Name: "BPF_F_ANY_ALIGNMENT", Value: 2}, {Name: "BPF_F_CLONE", Value: 512}, {Name: "BPF_F_LOCK", Value: 4}, + {Name: "BPF_F_MMAPABLE", Value: 1024}, {Name: "BPF_F_NO_COMMON_LRU", Value: 2}, {Name: "BPF_F_NO_PREALLOC", Value: 1}, {Name: "BPF_F_NUMA_NODE", Value: 4}, @@ -48784,6 +48787,7 @@ var consts_amd64 = []ConstValue{ {Name: "BPF_F_STACK_BUILD_ID", Value: 32}, {Name: "BPF_F_STRICT_ALIGNMENT", Value: 1}, {Name: "BPF_F_TEST_RND_HI32", Value: 4}, + {Name: "BPF_F_TEST_STATE_FREQ", Value: 8}, {Name: "BPF_F_WRONLY", Value: 16}, {Name: "BPF_F_WRONLY_PROG", Value: 256}, {Name: "BPF_F_ZERO_SEED", Value: 64}, @@ -48884,6 +48888,7 @@ var consts_amd64 = []ConstValue{ {Name: "BPF_PROG_TYPE_SOCKET_FILTER", Value: 1}, {Name: "BPF_PROG_TYPE_SOCK_OPS", Value: 13}, {Name: "BPF_PROG_TYPE_TRACEPOINT", Value: 5}, + {Name: "BPF_PROG_TYPE_TRACING", Value: 26}, {Name: "BPF_PROG_TYPE_XDP", Value: 6}, {Name: "BPF_PSEUDO_CALL", Value: 1}, {Name: "BPF_PSEUDO_MAP_FD", Value: 1}, @@ -48908,6 +48913,9 @@ var consts_amd64 = []ConstValue{ {Name: "BPF_STX", Value: 3}, {Name: "BPF_SUB0", Value: 1}, {Name: "BPF_TASK_FD_QUERY", Value: 20}, + {Name: "BPF_TRACE_FENTRY", Value: 24}, + {Name: "BPF_TRACE_FEXIT", Value: 25}, + {Name: "BPF_TRACE_RAW_TP", Value: 23}, {Name: "BPF_W0"}, {Name: "BPF_XADD0", Value: 6}, {Name: "BPF_XOR0", Value: 10}, @@ -56721,4 +56729,4 @@ var consts_amd64 = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_amd64 = "c7deb0eb93a7f4ba313ca4353604a63048ceef31" +const revision_amd64 = "8fc9f1ffd255cf5aa4d8ea7de1cd0abf18f527ec" diff --git a/sys/linux/gen/arm.go b/sys/linux/gen/arm.go index de48c6c05..083c1d226 100644 --- a/sys/linux/gen/arm.go +++ b/sys/linux/gen/arm.go @@ -1055,7 +1055,7 @@ var structDescs_arm = []*KeyedStruct{ {Key: StructKey{Name: "bpf_attach_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_attach_arg", TypeSize: 16}, Fields: []Type{ &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_cgroup", FldName: "target_fd", TypeSize: 4}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "attach_bpf_fd", TypeSize: 4}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2}, BitMask: true}, }}}, {Key: StructKey{Name: "bpf_btf_info", Dir: 2}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_btf_info", TypeSize: 16, ArgDir: 2}, Fields: []Type{ @@ -1083,7 +1083,7 @@ var structDescs_arm = []*KeyedStruct{ {Key: StructKey{Name: "bpf_detach_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_detach_arg", TypeSize: 16}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "target", TypeSize: 4}}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "prog", TypeSize: 4}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "flags", TypeSize: 4}}}, }}}, {Key: StructKey{Name: "bpf_framed_program"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_framed_program", IsVarlen: true}, Fields: []Type{ @@ -1223,7 +1223,7 @@ var structDescs_arm = []*KeyedStruct{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "ksize", TypeSize: 4}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "vsize", TypeSize: 4}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "max", TypeSize: 4}}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "map_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8, 16, 32, 64, 128, 256, 512}, BitMask: true}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "map_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024}, BitMask: true}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_map", FldName: "inner", TypeSize: 4, IsOptional: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "node", TypeSize: 4}}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "map_name", TypeSize: 16}, Type: &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", TypeSize: 1}}}, Kind: 1, RangeBegin: 16, RangeEnd: 16}, @@ -1297,8 +1297,8 @@ var structDescs_arm = []*KeyedStruct{ {Key: StructKey{Name: "bpf_options"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_options", IsVarlen: true}, Fields: []Type{ &StructType{Key: StructKey{Name: "fs_opt[\"mode\", fmt[oct, int32]]"}, FldName: "mode"}, }}}, - {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 112}, Fields: []Type{ - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, + {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 120}, Fields: []Type{ + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize8", FldName: "ninsn", TypeSize: 4}}, BitSize: 64, Path: []string{"insns"}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "insns", TypeSize: 8}, Type: &UnionType{Key: StructKey{Name: "bpf_instructions"}}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "license", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "string", IsVarlen: true}, Kind: 2, SubKind: "bpf_licenses", Values: []string{"GPL\x00", "syzkaller\x00"}}}, @@ -1306,10 +1306,10 @@ var structDescs_arm = []*KeyedStruct{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "logsize", TypeSize: 4}}, Path: []string{"log"}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "log", TypeSize: 8, IsOptional: true}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "array", ArgDir: 1, IsVarlen: true}}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_kern_version", FldName: "kern_version", TypeSize: 4}}, Vals: []uint64{265984, 266240, 266496}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_load_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4}, BitMask: true}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_load_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8}, BitMask: true}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "prog_name", TypeSize: 16}, Type: &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", TypeSize: 1}}}, Kind: 1, RangeBegin: 16, RangeEnd: 16}, &ResourceType{TypeCommon: TypeCommon{TypeName: "ifindex", FldName: "prog_ifindex", TypeSize: 4, IsOptional: true}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "expected_attach_type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "expected_attach_type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_btf", FldName: "btf_fd", TypeSize: 4, IsOptional: true}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "func_info_rec_size", TypeSize: 4}}, Val: 8}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "func_info", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "bpf_func_info"}}}, @@ -1317,6 +1317,8 @@ var structDescs_arm = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "line_info_rec_size", TypeSize: 4}}, Val: 16}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "line_info", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "bpf_line_info"}}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "line_info_cnt", TypeSize: 4}}, Path: []string{"line_info"}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "bpf_btf_id", FldName: "attach_btf_id", TypeSize: 4, IsOptional: true}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "attach_prog_fd", TypeSize: 4, IsOptional: true}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "pad", TypeSize: 4}}, IsPad: true}, }}}, {Key: StructKey{Name: "bpf_prog_get_fd_by_id_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog_get_fd_by_id_arg", TypeSize: 12}, Fields: []Type{ @@ -15931,7 +15933,7 @@ var structDescs_arm = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 43}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "payload", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "ifla_xdp_policy"}}}, }, AlignAttr: 4}}, - {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 116}, Fields: []Type{ + {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 124}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "nla_len", TypeSize: 2}}, Path: []string{"parent"}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 1}, &StructType{Key: StructKey{Name: "bpf_prog"}, FldName: "payload"}, @@ -47875,6 +47877,7 @@ var consts_arm = []ConstValue{ {Name: "BPF_F_ANY_ALIGNMENT", Value: 2}, {Name: "BPF_F_CLONE", Value: 512}, {Name: "BPF_F_LOCK", Value: 4}, + {Name: "BPF_F_MMAPABLE", Value: 1024}, {Name: "BPF_F_NO_COMMON_LRU", Value: 2}, {Name: "BPF_F_NO_PREALLOC", Value: 1}, {Name: "BPF_F_NUMA_NODE", Value: 4}, @@ -47884,6 +47887,7 @@ var consts_arm = []ConstValue{ {Name: "BPF_F_STACK_BUILD_ID", Value: 32}, {Name: "BPF_F_STRICT_ALIGNMENT", Value: 1}, {Name: "BPF_F_TEST_RND_HI32", Value: 4}, + {Name: "BPF_F_TEST_STATE_FREQ", Value: 8}, {Name: "BPF_F_WRONLY", Value: 16}, {Name: "BPF_F_WRONLY_PROG", Value: 256}, {Name: "BPF_F_ZERO_SEED", Value: 64}, @@ -47984,6 +47988,7 @@ var consts_arm = []ConstValue{ {Name: "BPF_PROG_TYPE_SOCKET_FILTER", Value: 1}, {Name: "BPF_PROG_TYPE_SOCK_OPS", Value: 13}, {Name: "BPF_PROG_TYPE_TRACEPOINT", Value: 5}, + {Name: "BPF_PROG_TYPE_TRACING", Value: 26}, {Name: "BPF_PROG_TYPE_XDP", Value: 6}, {Name: "BPF_PSEUDO_CALL", Value: 1}, {Name: "BPF_PSEUDO_MAP_FD", Value: 1}, @@ -48008,6 +48013,9 @@ var consts_arm = []ConstValue{ {Name: "BPF_STX", Value: 3}, {Name: "BPF_SUB0", Value: 1}, {Name: "BPF_TASK_FD_QUERY", Value: 20}, + {Name: "BPF_TRACE_FENTRY", Value: 24}, + {Name: "BPF_TRACE_FEXIT", Value: 25}, + {Name: "BPF_TRACE_RAW_TP", Value: 23}, {Name: "BPF_W0"}, {Name: "BPF_XADD0", Value: 6}, {Name: "BPF_XOR0", Value: 10}, @@ -55743,4 +55751,4 @@ var consts_arm = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_arm = "bc534d8633d0dd3ff045bdae7dca58532abb9e77" +const revision_arm = "a6c83e9dee0a0fe2779d94cd319fe9eea0f13d49" diff --git a/sys/linux/gen/arm64.go b/sys/linux/gen/arm64.go index 86df183cd..f5e6ab0fa 100644 --- a/sys/linux/gen/arm64.go +++ b/sys/linux/gen/arm64.go @@ -1300,7 +1300,7 @@ var structDescs_arm64 = []*KeyedStruct{ {Key: StructKey{Name: "bpf_options"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_options", IsVarlen: true}, Fields: []Type{ &StructType{Key: StructKey{Name: "fs_opt[\"mode\", fmt[oct, int32]]"}, FldName: "mode"}, }}}, - {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 112}, Fields: []Type{ + {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 120}, Fields: []Type{ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize8", FldName: "ninsn", TypeSize: 4}}, BitSize: 64, Path: []string{"insns"}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "insns", TypeSize: 8}, Type: &UnionType{Key: StructKey{Name: "bpf_instructions"}}}, @@ -1320,6 +1320,8 @@ var structDescs_arm64 = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "line_info_rec_size", TypeSize: 4}}, Val: 16}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "line_info", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "bpf_line_info"}}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "line_info_cnt", TypeSize: 4}}, Path: []string{"line_info"}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "bpf_btf_id", FldName: "attach_btf_id", TypeSize: 4, IsOptional: true}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "attach_prog_fd", TypeSize: 4, IsOptional: true}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "pad", TypeSize: 4}}, IsPad: true}, }}}, {Key: StructKey{Name: "bpf_prog_get_fd_by_id_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog_get_fd_by_id_arg", TypeSize: 12}, Fields: []Type{ @@ -16240,7 +16242,7 @@ var structDescs_arm64 = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 43}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "payload", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "ifla_xdp_policy"}}}, }, AlignAttr: 4}}, - {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 116}, Fields: []Type{ + {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 124}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "nla_len", TypeSize: 2}}, Path: []string{"parent"}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 1}, &StructType{Key: StructKey{Name: "bpf_prog"}, FldName: "payload"}, @@ -56073,4 +56075,4 @@ var consts_arm64 = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_arm64 = "d456a991822924ac24bd293d2f19a8cc72049272" +const revision_arm64 = "296d5e25600a16e45296e2c7406f11493a9c5ecc" diff --git a/sys/linux/gen/ppc64le.go b/sys/linux/gen/ppc64le.go index 0906b49fe..73dff638e 100644 --- a/sys/linux/gen/ppc64le.go +++ b/sys/linux/gen/ppc64le.go @@ -1057,7 +1057,7 @@ var structDescs_ppc64le = []*KeyedStruct{ {Key: StructKey{Name: "bpf_attach_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_attach_arg", TypeSize: 16}, Fields: []Type{ &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_cgroup", FldName: "target_fd", TypeSize: 4}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "attach_bpf_fd", TypeSize: 4}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2}, BitMask: true}, }}}, {Key: StructKey{Name: "bpf_btf_info", Dir: 2}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_btf_info", TypeSize: 16, ArgDir: 2}, Fields: []Type{ @@ -1085,7 +1085,7 @@ var structDescs_ppc64le = []*KeyedStruct{ {Key: StructKey{Name: "bpf_detach_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_detach_arg", TypeSize: 16}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "target", TypeSize: 4}}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "prog", TypeSize: 4}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "flags", TypeSize: 4}}}, }}}, {Key: StructKey{Name: "bpf_framed_program"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_framed_program", IsVarlen: true}, Fields: []Type{ @@ -1225,7 +1225,7 @@ var structDescs_ppc64le = []*KeyedStruct{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "ksize", TypeSize: 4}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "vsize", TypeSize: 4}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "max", TypeSize: 4}}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "map_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8, 16, 32, 64, 128, 256, 512}, BitMask: true}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "map_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024}, BitMask: true}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_map", FldName: "inner", TypeSize: 4, IsOptional: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "node", TypeSize: 4}}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "map_name", TypeSize: 16}, Type: &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", TypeSize: 1}}}, Kind: 1, RangeBegin: 16, RangeEnd: 16}, @@ -1299,8 +1299,8 @@ var structDescs_ppc64le = []*KeyedStruct{ {Key: StructKey{Name: "bpf_options"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_options", IsVarlen: true}, Fields: []Type{ &StructType{Key: StructKey{Name: "fs_opt[\"mode\", fmt[oct, int32]]"}, FldName: "mode"}, }}}, - {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 112}, Fields: []Type{ - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, + {Key: StructKey{Name: "bpf_prog"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog", TypeSize: 120}, Fields: []Type{ + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_type", FldName: "type", TypeSize: 4}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize8", FldName: "ninsn", TypeSize: 4}}, BitSize: 64, Path: []string{"insns"}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "insns", TypeSize: 8}, Type: &UnionType{Key: StructKey{Name: "bpf_instructions"}}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "license", TypeSize: 8}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "string", IsVarlen: true}, Kind: 2, SubKind: "bpf_licenses", Values: []string{"GPL\x00", "syzkaller\x00"}}}, @@ -1308,10 +1308,10 @@ var structDescs_ppc64le = []*KeyedStruct{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "logsize", TypeSize: 4}}, Path: []string{"log"}}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "log", TypeSize: 8, IsOptional: true}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "array", ArgDir: 1, IsVarlen: true}}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_kern_version", FldName: "kern_version", TypeSize: 4}}, Vals: []uint64{265984, 266240, 266496}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_load_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4}, BitMask: true}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_prog_load_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{1, 2, 4, 8}, BitMask: true}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "prog_name", TypeSize: 16}, Type: &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", TypeSize: 1}}}, Kind: 1, RangeBegin: 16, RangeEnd: 16}, &ResourceType{TypeCommon: TypeCommon{TypeName: "ifindex", FldName: "prog_ifindex", TypeSize: 4, IsOptional: true}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "expected_attach_type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bpf_attach_type", FldName: "expected_attach_type", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_btf", FldName: "btf_fd", TypeSize: 4, IsOptional: true}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "func_info_rec_size", TypeSize: 4}}, Val: 8}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "func_info", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "bpf_func_info"}}}, @@ -1319,6 +1319,8 @@ var structDescs_ppc64le = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "line_info_rec_size", TypeSize: 4}}, Val: 16}, &PtrType{TypeCommon: TypeCommon{TypeName: "ptr64", FldName: "line_info", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "bpf_line_info"}}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "line_info_cnt", TypeSize: 4}}, Path: []string{"line_info"}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "bpf_btf_id", FldName: "attach_btf_id", TypeSize: 4, IsOptional: true}}, + &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_bpf_prog", FldName: "attach_prog_fd", TypeSize: 4, IsOptional: true}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "pad", TypeSize: 4}}, IsPad: true}, }}}, {Key: StructKey{Name: "bpf_prog_get_fd_by_id_arg"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "bpf_prog_get_fd_by_id_arg", TypeSize: 12}, Fields: []Type{ @@ -16192,7 +16194,7 @@ var structDescs_ppc64le = []*KeyedStruct{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 43}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "payload", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "ifla_xdp_policy"}}}, }, AlignAttr: 4}}, - {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 116}, Fields: []Type{ + {Key: StructKey{Name: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "nlattr_t[const[IFLA_XDP_FD, int16], bpf_prog]", TypeSize: 124}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "nla_len", TypeSize: 2}}, Path: []string{"parent"}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "nla_type", TypeSize: 2}}, Val: 1}, &StructType{Key: StructKey{Name: "bpf_prog"}, FldName: "payload"}, @@ -48215,6 +48217,7 @@ var consts_ppc64le = []ConstValue{ {Name: "BPF_F_ANY_ALIGNMENT", Value: 2}, {Name: "BPF_F_CLONE", Value: 512}, {Name: "BPF_F_LOCK", Value: 4}, + {Name: "BPF_F_MMAPABLE", Value: 1024}, {Name: "BPF_F_NO_COMMON_LRU", Value: 2}, {Name: "BPF_F_NO_PREALLOC", Value: 1}, {Name: "BPF_F_NUMA_NODE", Value: 4}, @@ -48224,6 +48227,7 @@ var consts_ppc64le = []ConstValue{ {Name: "BPF_F_STACK_BUILD_ID", Value: 32}, {Name: "BPF_F_STRICT_ALIGNMENT", Value: 1}, {Name: "BPF_F_TEST_RND_HI32", Value: 4}, + {Name: "BPF_F_TEST_STATE_FREQ", Value: 8}, {Name: "BPF_F_WRONLY", Value: 16}, {Name: "BPF_F_WRONLY_PROG", Value: 256}, {Name: "BPF_F_ZERO_SEED", Value: 64}, @@ -48324,6 +48328,7 @@ var consts_ppc64le = []ConstValue{ {Name: "BPF_PROG_TYPE_SOCKET_FILTER", Value: 1}, {Name: "BPF_PROG_TYPE_SOCK_OPS", Value: 13}, {Name: "BPF_PROG_TYPE_TRACEPOINT", Value: 5}, + {Name: "BPF_PROG_TYPE_TRACING", Value: 26}, {Name: "BPF_PROG_TYPE_XDP", Value: 6}, {Name: "BPF_PSEUDO_CALL", Value: 1}, {Name: "BPF_PSEUDO_MAP_FD", Value: 1}, @@ -48348,6 +48353,9 @@ var consts_ppc64le = []ConstValue{ {Name: "BPF_STX", Value: 3}, {Name: "BPF_SUB0", Value: 1}, {Name: "BPF_TASK_FD_QUERY", Value: 20}, + {Name: "BPF_TRACE_FENTRY", Value: 24}, + {Name: "BPF_TRACE_FEXIT", Value: 25}, + {Name: "BPF_TRACE_RAW_TP", Value: 23}, {Name: "BPF_W0"}, {Name: "BPF_XADD0", Value: 6}, {Name: "BPF_XOR0", Value: 10}, @@ -56038,4 +56046,4 @@ var consts_ppc64le = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_ppc64le = "9d05bddc02c71dd60eb8218ca126a19c2d95daf7" +const revision_ppc64le = "b52e602ac53e3e3a3865b78b1281b6435dbd9219" -- cgit mrf-deployment