diff --git a/aya/src/generated/linux_bindings_aarch64.rs b/aya/src/generated/linux_bindings_aarch64.rs index 171d3113..ace0f73e 100644 --- a/aya/src/generated/linux_bindings_aarch64.rs +++ b/aya/src/generated/linux_bindings_aarch64.rs @@ -101,24 +101,6 @@ pub const BPF_PSEUDO_BTF_ID: u32 = 3; pub const BPF_PSEUDO_FUNC: u32 = 4; pub const BPF_PSEUDO_CALL: u32 = 1; pub const BPF_PSEUDO_KFUNC_CALL: u32 = 2; -pub const BTF_KIND_UNKN: u32 = 0; -pub const BTF_KIND_INT: u32 = 1; -pub const BTF_KIND_PTR: u32 = 2; -pub const BTF_KIND_ARRAY: u32 = 3; -pub const BTF_KIND_STRUCT: u32 = 4; -pub const BTF_KIND_UNION: u32 = 5; -pub const BTF_KIND_ENUM: u32 = 6; -pub const BTF_KIND_FWD: u32 = 7; -pub const BTF_KIND_TYPEDEF: u32 = 8; -pub const BTF_KIND_VOLATILE: u32 = 9; -pub const BTF_KIND_CONST: u32 = 10; -pub const BTF_KIND_RESTRICT: u32 = 11; -pub const BTF_KIND_FUNC: u32 = 12; -pub const BTF_KIND_FUNC_PROTO: u32 = 13; -pub const BTF_KIND_VAR: u32 = 14; -pub const BTF_KIND_DATASEC: u32 = 15; -pub const BTF_KIND_FLOAT: u32 = 16; -pub const BTF_KIND_MAX: u32 = 16; pub const BTF_INT_SIGNED: u32 = 1; pub const BTF_INT_CHAR: u32 = 2; pub const BTF_INT_BOOL: u32 = 4; @@ -714,6 +696,27 @@ pub union btf_type__bindgen_ty_1 { pub size: __u32, pub type_: __u32, } +pub const BTF_KIND_UNKN: ::std::os::raw::c_uint = 0; +pub const BTF_KIND_INT: ::std::os::raw::c_uint = 1; +pub const BTF_KIND_PTR: ::std::os::raw::c_uint = 2; +pub const BTF_KIND_ARRAY: ::std::os::raw::c_uint = 3; +pub const BTF_KIND_STRUCT: ::std::os::raw::c_uint = 4; +pub const BTF_KIND_UNION: ::std::os::raw::c_uint = 5; +pub const BTF_KIND_ENUM: ::std::os::raw::c_uint = 6; +pub const BTF_KIND_FWD: ::std::os::raw::c_uint = 7; +pub const BTF_KIND_TYPEDEF: ::std::os::raw::c_uint = 8; +pub const BTF_KIND_VOLATILE: ::std::os::raw::c_uint = 9; +pub const BTF_KIND_CONST: ::std::os::raw::c_uint = 10; +pub const BTF_KIND_RESTRICT: ::std::os::raw::c_uint = 11; +pub const BTF_KIND_FUNC: ::std::os::raw::c_uint = 12; +pub const BTF_KIND_FUNC_PROTO: ::std::os::raw::c_uint = 13; +pub const BTF_KIND_VAR: ::std::os::raw::c_uint = 14; +pub const BTF_KIND_DATASEC: ::std::os::raw::c_uint = 15; +pub const BTF_KIND_FLOAT: ::std::os::raw::c_uint = 16; +pub const BTF_KIND_TAG: ::std::os::raw::c_uint = 17; +pub const NR_BTF_KINDS: ::std::os::raw::c_uint = 18; +pub const BTF_KIND_MAX: ::std::os::raw::c_uint = 17; +pub type _bindgen_ty_37 = ::std::os::raw::c_uint; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct btf_enum { @@ -1722,19 +1725,19 @@ pub enum perf_event_type { PERF_RECORD_TEXT_POKE = 20, PERF_RECORD_MAX = 21, } -pub const IFLA_XDP_UNSPEC: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_UNSPEC; -pub const IFLA_XDP_FD: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_FD; -pub const IFLA_XDP_ATTACHED: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_ATTACHED; -pub const IFLA_XDP_FLAGS: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_FLAGS; -pub const IFLA_XDP_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_PROG_ID; -pub const IFLA_XDP_DRV_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_DRV_PROG_ID; -pub const IFLA_XDP_SKB_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_SKB_PROG_ID; -pub const IFLA_XDP_HW_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_HW_PROG_ID; -pub const IFLA_XDP_EXPECTED_FD: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_EXPECTED_FD; -pub const __IFLA_XDP_MAX: _bindgen_ty_80 = _bindgen_ty_80::__IFLA_XDP_MAX; +pub const IFLA_XDP_UNSPEC: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_UNSPEC; +pub const IFLA_XDP_FD: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_FD; +pub const IFLA_XDP_ATTACHED: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_ATTACHED; +pub const IFLA_XDP_FLAGS: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_FLAGS; +pub const IFLA_XDP_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_PROG_ID; +pub const IFLA_XDP_DRV_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_DRV_PROG_ID; +pub const IFLA_XDP_SKB_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_SKB_PROG_ID; +pub const IFLA_XDP_HW_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_HW_PROG_ID; +pub const IFLA_XDP_EXPECTED_FD: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_EXPECTED_FD; +pub const __IFLA_XDP_MAX: _bindgen_ty_81 = _bindgen_ty_81::__IFLA_XDP_MAX; #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum _bindgen_ty_80 { +pub enum _bindgen_ty_81 { IFLA_XDP_UNSPEC = 0, IFLA_XDP_FD = 1, IFLA_XDP_ATTACHED = 2, @@ -1767,25 +1770,26 @@ pub struct tcmsg { pub tcm_parent: __u32, pub tcm_info: __u32, } -pub const TCA_UNSPEC: _bindgen_ty_92 = _bindgen_ty_92::TCA_UNSPEC; -pub const TCA_KIND: _bindgen_ty_92 = _bindgen_ty_92::TCA_KIND; -pub const TCA_OPTIONS: _bindgen_ty_92 = _bindgen_ty_92::TCA_OPTIONS; -pub const TCA_STATS: _bindgen_ty_92 = _bindgen_ty_92::TCA_STATS; -pub const TCA_XSTATS: _bindgen_ty_92 = _bindgen_ty_92::TCA_XSTATS; -pub const TCA_RATE: _bindgen_ty_92 = _bindgen_ty_92::TCA_RATE; -pub const TCA_FCNT: _bindgen_ty_92 = _bindgen_ty_92::TCA_FCNT; -pub const TCA_STATS2: _bindgen_ty_92 = _bindgen_ty_92::TCA_STATS2; -pub const TCA_STAB: _bindgen_ty_92 = _bindgen_ty_92::TCA_STAB; -pub const TCA_PAD: _bindgen_ty_92 = _bindgen_ty_92::TCA_PAD; -pub const TCA_DUMP_INVISIBLE: _bindgen_ty_92 = _bindgen_ty_92::TCA_DUMP_INVISIBLE; -pub const TCA_CHAIN: _bindgen_ty_92 = _bindgen_ty_92::TCA_CHAIN; -pub const TCA_HW_OFFLOAD: _bindgen_ty_92 = _bindgen_ty_92::TCA_HW_OFFLOAD; -pub const TCA_INGRESS_BLOCK: _bindgen_ty_92 = _bindgen_ty_92::TCA_INGRESS_BLOCK; -pub const TCA_EGRESS_BLOCK: _bindgen_ty_92 = _bindgen_ty_92::TCA_EGRESS_BLOCK; -pub const __TCA_MAX: _bindgen_ty_92 = _bindgen_ty_92::__TCA_MAX; +pub const TCA_UNSPEC: _bindgen_ty_95 = _bindgen_ty_95::TCA_UNSPEC; +pub const TCA_KIND: _bindgen_ty_95 = _bindgen_ty_95::TCA_KIND; +pub const TCA_OPTIONS: _bindgen_ty_95 = _bindgen_ty_95::TCA_OPTIONS; +pub const TCA_STATS: _bindgen_ty_95 = _bindgen_ty_95::TCA_STATS; +pub const TCA_XSTATS: _bindgen_ty_95 = _bindgen_ty_95::TCA_XSTATS; +pub const TCA_RATE: _bindgen_ty_95 = _bindgen_ty_95::TCA_RATE; +pub const TCA_FCNT: _bindgen_ty_95 = _bindgen_ty_95::TCA_FCNT; +pub const TCA_STATS2: _bindgen_ty_95 = _bindgen_ty_95::TCA_STATS2; +pub const TCA_STAB: _bindgen_ty_95 = _bindgen_ty_95::TCA_STAB; +pub const TCA_PAD: _bindgen_ty_95 = _bindgen_ty_95::TCA_PAD; +pub const TCA_DUMP_INVISIBLE: _bindgen_ty_95 = _bindgen_ty_95::TCA_DUMP_INVISIBLE; +pub const TCA_CHAIN: _bindgen_ty_95 = _bindgen_ty_95::TCA_CHAIN; +pub const TCA_HW_OFFLOAD: _bindgen_ty_95 = _bindgen_ty_95::TCA_HW_OFFLOAD; +pub const TCA_INGRESS_BLOCK: _bindgen_ty_95 = _bindgen_ty_95::TCA_INGRESS_BLOCK; +pub const TCA_EGRESS_BLOCK: _bindgen_ty_95 = _bindgen_ty_95::TCA_EGRESS_BLOCK; +pub const TCA_DUMP_FLAGS: _bindgen_ty_95 = _bindgen_ty_95::TCA_DUMP_FLAGS; +pub const __TCA_MAX: _bindgen_ty_95 = _bindgen_ty_95::__TCA_MAX; #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum _bindgen_ty_92 { +pub enum _bindgen_ty_95 { TCA_UNSPEC = 0, TCA_KIND = 1, TCA_OPTIONS = 2, @@ -1801,24 +1805,25 @@ pub enum _bindgen_ty_92 { TCA_HW_OFFLOAD = 12, TCA_INGRESS_BLOCK = 13, TCA_EGRESS_BLOCK = 14, - __TCA_MAX = 15, -} -pub const TCA_BPF_UNSPEC: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_UNSPEC; -pub const TCA_BPF_ACT: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_ACT; -pub const TCA_BPF_POLICE: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_POLICE; -pub const TCA_BPF_CLASSID: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_CLASSID; -pub const TCA_BPF_OPS_LEN: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_OPS_LEN; -pub const TCA_BPF_OPS: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_OPS; -pub const TCA_BPF_FD: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_FD; -pub const TCA_BPF_NAME: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_NAME; -pub const TCA_BPF_FLAGS: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_FLAGS; -pub const TCA_BPF_FLAGS_GEN: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_FLAGS_GEN; -pub const TCA_BPF_TAG: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_TAG; -pub const TCA_BPF_ID: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_ID; -pub const __TCA_BPF_MAX: _bindgen_ty_148 = _bindgen_ty_148::__TCA_BPF_MAX; + TCA_DUMP_FLAGS = 15, + __TCA_MAX = 16, +} +pub const TCA_BPF_UNSPEC: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_UNSPEC; +pub const TCA_BPF_ACT: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_ACT; +pub const TCA_BPF_POLICE: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_POLICE; +pub const TCA_BPF_CLASSID: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_CLASSID; +pub const TCA_BPF_OPS_LEN: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_OPS_LEN; +pub const TCA_BPF_OPS: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_OPS; +pub const TCA_BPF_FD: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_FD; +pub const TCA_BPF_NAME: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_NAME; +pub const TCA_BPF_FLAGS: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_FLAGS; +pub const TCA_BPF_FLAGS_GEN: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_FLAGS_GEN; +pub const TCA_BPF_TAG: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_TAG; +pub const TCA_BPF_ID: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_ID; +pub const __TCA_BPF_MAX: _bindgen_ty_151 = _bindgen_ty_151::__TCA_BPF_MAX; #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum _bindgen_ty_148 { +pub enum _bindgen_ty_151 { TCA_BPF_UNSPEC = 0, TCA_BPF_ACT = 1, TCA_BPF_POLICE = 2, diff --git a/aya/src/generated/linux_bindings_armv7.rs b/aya/src/generated/linux_bindings_armv7.rs index 171d3113..ace0f73e 100644 --- a/aya/src/generated/linux_bindings_armv7.rs +++ b/aya/src/generated/linux_bindings_armv7.rs @@ -101,24 +101,6 @@ pub const BPF_PSEUDO_BTF_ID: u32 = 3; pub const BPF_PSEUDO_FUNC: u32 = 4; pub const BPF_PSEUDO_CALL: u32 = 1; pub const BPF_PSEUDO_KFUNC_CALL: u32 = 2; -pub const BTF_KIND_UNKN: u32 = 0; -pub const BTF_KIND_INT: u32 = 1; -pub const BTF_KIND_PTR: u32 = 2; -pub const BTF_KIND_ARRAY: u32 = 3; -pub const BTF_KIND_STRUCT: u32 = 4; -pub const BTF_KIND_UNION: u32 = 5; -pub const BTF_KIND_ENUM: u32 = 6; -pub const BTF_KIND_FWD: u32 = 7; -pub const BTF_KIND_TYPEDEF: u32 = 8; -pub const BTF_KIND_VOLATILE: u32 = 9; -pub const BTF_KIND_CONST: u32 = 10; -pub const BTF_KIND_RESTRICT: u32 = 11; -pub const BTF_KIND_FUNC: u32 = 12; -pub const BTF_KIND_FUNC_PROTO: u32 = 13; -pub const BTF_KIND_VAR: u32 = 14; -pub const BTF_KIND_DATASEC: u32 = 15; -pub const BTF_KIND_FLOAT: u32 = 16; -pub const BTF_KIND_MAX: u32 = 16; pub const BTF_INT_SIGNED: u32 = 1; pub const BTF_INT_CHAR: u32 = 2; pub const BTF_INT_BOOL: u32 = 4; @@ -714,6 +696,27 @@ pub union btf_type__bindgen_ty_1 { pub size: __u32, pub type_: __u32, } +pub const BTF_KIND_UNKN: ::std::os::raw::c_uint = 0; +pub const BTF_KIND_INT: ::std::os::raw::c_uint = 1; +pub const BTF_KIND_PTR: ::std::os::raw::c_uint = 2; +pub const BTF_KIND_ARRAY: ::std::os::raw::c_uint = 3; +pub const BTF_KIND_STRUCT: ::std::os::raw::c_uint = 4; +pub const BTF_KIND_UNION: ::std::os::raw::c_uint = 5; +pub const BTF_KIND_ENUM: ::std::os::raw::c_uint = 6; +pub const BTF_KIND_FWD: ::std::os::raw::c_uint = 7; +pub const BTF_KIND_TYPEDEF: ::std::os::raw::c_uint = 8; +pub const BTF_KIND_VOLATILE: ::std::os::raw::c_uint = 9; +pub const BTF_KIND_CONST: ::std::os::raw::c_uint = 10; +pub const BTF_KIND_RESTRICT: ::std::os::raw::c_uint = 11; +pub const BTF_KIND_FUNC: ::std::os::raw::c_uint = 12; +pub const BTF_KIND_FUNC_PROTO: ::std::os::raw::c_uint = 13; +pub const BTF_KIND_VAR: ::std::os::raw::c_uint = 14; +pub const BTF_KIND_DATASEC: ::std::os::raw::c_uint = 15; +pub const BTF_KIND_FLOAT: ::std::os::raw::c_uint = 16; +pub const BTF_KIND_TAG: ::std::os::raw::c_uint = 17; +pub const NR_BTF_KINDS: ::std::os::raw::c_uint = 18; +pub const BTF_KIND_MAX: ::std::os::raw::c_uint = 17; +pub type _bindgen_ty_37 = ::std::os::raw::c_uint; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct btf_enum { @@ -1722,19 +1725,19 @@ pub enum perf_event_type { PERF_RECORD_TEXT_POKE = 20, PERF_RECORD_MAX = 21, } -pub const IFLA_XDP_UNSPEC: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_UNSPEC; -pub const IFLA_XDP_FD: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_FD; -pub const IFLA_XDP_ATTACHED: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_ATTACHED; -pub const IFLA_XDP_FLAGS: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_FLAGS; -pub const IFLA_XDP_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_PROG_ID; -pub const IFLA_XDP_DRV_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_DRV_PROG_ID; -pub const IFLA_XDP_SKB_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_SKB_PROG_ID; -pub const IFLA_XDP_HW_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_HW_PROG_ID; -pub const IFLA_XDP_EXPECTED_FD: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_EXPECTED_FD; -pub const __IFLA_XDP_MAX: _bindgen_ty_80 = _bindgen_ty_80::__IFLA_XDP_MAX; +pub const IFLA_XDP_UNSPEC: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_UNSPEC; +pub const IFLA_XDP_FD: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_FD; +pub const IFLA_XDP_ATTACHED: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_ATTACHED; +pub const IFLA_XDP_FLAGS: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_FLAGS; +pub const IFLA_XDP_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_PROG_ID; +pub const IFLA_XDP_DRV_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_DRV_PROG_ID; +pub const IFLA_XDP_SKB_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_SKB_PROG_ID; +pub const IFLA_XDP_HW_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_HW_PROG_ID; +pub const IFLA_XDP_EXPECTED_FD: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_EXPECTED_FD; +pub const __IFLA_XDP_MAX: _bindgen_ty_81 = _bindgen_ty_81::__IFLA_XDP_MAX; #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum _bindgen_ty_80 { +pub enum _bindgen_ty_81 { IFLA_XDP_UNSPEC = 0, IFLA_XDP_FD = 1, IFLA_XDP_ATTACHED = 2, @@ -1767,25 +1770,26 @@ pub struct tcmsg { pub tcm_parent: __u32, pub tcm_info: __u32, } -pub const TCA_UNSPEC: _bindgen_ty_92 = _bindgen_ty_92::TCA_UNSPEC; -pub const TCA_KIND: _bindgen_ty_92 = _bindgen_ty_92::TCA_KIND; -pub const TCA_OPTIONS: _bindgen_ty_92 = _bindgen_ty_92::TCA_OPTIONS; -pub const TCA_STATS: _bindgen_ty_92 = _bindgen_ty_92::TCA_STATS; -pub const TCA_XSTATS: _bindgen_ty_92 = _bindgen_ty_92::TCA_XSTATS; -pub const TCA_RATE: _bindgen_ty_92 = _bindgen_ty_92::TCA_RATE; -pub const TCA_FCNT: _bindgen_ty_92 = _bindgen_ty_92::TCA_FCNT; -pub const TCA_STATS2: _bindgen_ty_92 = _bindgen_ty_92::TCA_STATS2; -pub const TCA_STAB: _bindgen_ty_92 = _bindgen_ty_92::TCA_STAB; -pub const TCA_PAD: _bindgen_ty_92 = _bindgen_ty_92::TCA_PAD; -pub const TCA_DUMP_INVISIBLE: _bindgen_ty_92 = _bindgen_ty_92::TCA_DUMP_INVISIBLE; -pub const TCA_CHAIN: _bindgen_ty_92 = _bindgen_ty_92::TCA_CHAIN; -pub const TCA_HW_OFFLOAD: _bindgen_ty_92 = _bindgen_ty_92::TCA_HW_OFFLOAD; -pub const TCA_INGRESS_BLOCK: _bindgen_ty_92 = _bindgen_ty_92::TCA_INGRESS_BLOCK; -pub const TCA_EGRESS_BLOCK: _bindgen_ty_92 = _bindgen_ty_92::TCA_EGRESS_BLOCK; -pub const __TCA_MAX: _bindgen_ty_92 = _bindgen_ty_92::__TCA_MAX; +pub const TCA_UNSPEC: _bindgen_ty_95 = _bindgen_ty_95::TCA_UNSPEC; +pub const TCA_KIND: _bindgen_ty_95 = _bindgen_ty_95::TCA_KIND; +pub const TCA_OPTIONS: _bindgen_ty_95 = _bindgen_ty_95::TCA_OPTIONS; +pub const TCA_STATS: _bindgen_ty_95 = _bindgen_ty_95::TCA_STATS; +pub const TCA_XSTATS: _bindgen_ty_95 = _bindgen_ty_95::TCA_XSTATS; +pub const TCA_RATE: _bindgen_ty_95 = _bindgen_ty_95::TCA_RATE; +pub const TCA_FCNT: _bindgen_ty_95 = _bindgen_ty_95::TCA_FCNT; +pub const TCA_STATS2: _bindgen_ty_95 = _bindgen_ty_95::TCA_STATS2; +pub const TCA_STAB: _bindgen_ty_95 = _bindgen_ty_95::TCA_STAB; +pub const TCA_PAD: _bindgen_ty_95 = _bindgen_ty_95::TCA_PAD; +pub const TCA_DUMP_INVISIBLE: _bindgen_ty_95 = _bindgen_ty_95::TCA_DUMP_INVISIBLE; +pub const TCA_CHAIN: _bindgen_ty_95 = _bindgen_ty_95::TCA_CHAIN; +pub const TCA_HW_OFFLOAD: _bindgen_ty_95 = _bindgen_ty_95::TCA_HW_OFFLOAD; +pub const TCA_INGRESS_BLOCK: _bindgen_ty_95 = _bindgen_ty_95::TCA_INGRESS_BLOCK; +pub const TCA_EGRESS_BLOCK: _bindgen_ty_95 = _bindgen_ty_95::TCA_EGRESS_BLOCK; +pub const TCA_DUMP_FLAGS: _bindgen_ty_95 = _bindgen_ty_95::TCA_DUMP_FLAGS; +pub const __TCA_MAX: _bindgen_ty_95 = _bindgen_ty_95::__TCA_MAX; #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum _bindgen_ty_92 { +pub enum _bindgen_ty_95 { TCA_UNSPEC = 0, TCA_KIND = 1, TCA_OPTIONS = 2, @@ -1801,24 +1805,25 @@ pub enum _bindgen_ty_92 { TCA_HW_OFFLOAD = 12, TCA_INGRESS_BLOCK = 13, TCA_EGRESS_BLOCK = 14, - __TCA_MAX = 15, -} -pub const TCA_BPF_UNSPEC: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_UNSPEC; -pub const TCA_BPF_ACT: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_ACT; -pub const TCA_BPF_POLICE: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_POLICE; -pub const TCA_BPF_CLASSID: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_CLASSID; -pub const TCA_BPF_OPS_LEN: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_OPS_LEN; -pub const TCA_BPF_OPS: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_OPS; -pub const TCA_BPF_FD: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_FD; -pub const TCA_BPF_NAME: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_NAME; -pub const TCA_BPF_FLAGS: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_FLAGS; -pub const TCA_BPF_FLAGS_GEN: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_FLAGS_GEN; -pub const TCA_BPF_TAG: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_TAG; -pub const TCA_BPF_ID: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_ID; -pub const __TCA_BPF_MAX: _bindgen_ty_148 = _bindgen_ty_148::__TCA_BPF_MAX; + TCA_DUMP_FLAGS = 15, + __TCA_MAX = 16, +} +pub const TCA_BPF_UNSPEC: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_UNSPEC; +pub const TCA_BPF_ACT: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_ACT; +pub const TCA_BPF_POLICE: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_POLICE; +pub const TCA_BPF_CLASSID: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_CLASSID; +pub const TCA_BPF_OPS_LEN: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_OPS_LEN; +pub const TCA_BPF_OPS: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_OPS; +pub const TCA_BPF_FD: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_FD; +pub const TCA_BPF_NAME: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_NAME; +pub const TCA_BPF_FLAGS: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_FLAGS; +pub const TCA_BPF_FLAGS_GEN: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_FLAGS_GEN; +pub const TCA_BPF_TAG: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_TAG; +pub const TCA_BPF_ID: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_ID; +pub const __TCA_BPF_MAX: _bindgen_ty_151 = _bindgen_ty_151::__TCA_BPF_MAX; #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum _bindgen_ty_148 { +pub enum _bindgen_ty_151 { TCA_BPF_UNSPEC = 0, TCA_BPF_ACT = 1, TCA_BPF_POLICE = 2, diff --git a/aya/src/generated/linux_bindings_x86_64.rs b/aya/src/generated/linux_bindings_x86_64.rs index 171d3113..ace0f73e 100644 --- a/aya/src/generated/linux_bindings_x86_64.rs +++ b/aya/src/generated/linux_bindings_x86_64.rs @@ -101,24 +101,6 @@ pub const BPF_PSEUDO_BTF_ID: u32 = 3; pub const BPF_PSEUDO_FUNC: u32 = 4; pub const BPF_PSEUDO_CALL: u32 = 1; pub const BPF_PSEUDO_KFUNC_CALL: u32 = 2; -pub const BTF_KIND_UNKN: u32 = 0; -pub const BTF_KIND_INT: u32 = 1; -pub const BTF_KIND_PTR: u32 = 2; -pub const BTF_KIND_ARRAY: u32 = 3; -pub const BTF_KIND_STRUCT: u32 = 4; -pub const BTF_KIND_UNION: u32 = 5; -pub const BTF_KIND_ENUM: u32 = 6; -pub const BTF_KIND_FWD: u32 = 7; -pub const BTF_KIND_TYPEDEF: u32 = 8; -pub const BTF_KIND_VOLATILE: u32 = 9; -pub const BTF_KIND_CONST: u32 = 10; -pub const BTF_KIND_RESTRICT: u32 = 11; -pub const BTF_KIND_FUNC: u32 = 12; -pub const BTF_KIND_FUNC_PROTO: u32 = 13; -pub const BTF_KIND_VAR: u32 = 14; -pub const BTF_KIND_DATASEC: u32 = 15; -pub const BTF_KIND_FLOAT: u32 = 16; -pub const BTF_KIND_MAX: u32 = 16; pub const BTF_INT_SIGNED: u32 = 1; pub const BTF_INT_CHAR: u32 = 2; pub const BTF_INT_BOOL: u32 = 4; @@ -714,6 +696,27 @@ pub union btf_type__bindgen_ty_1 { pub size: __u32, pub type_: __u32, } +pub const BTF_KIND_UNKN: ::std::os::raw::c_uint = 0; +pub const BTF_KIND_INT: ::std::os::raw::c_uint = 1; +pub const BTF_KIND_PTR: ::std::os::raw::c_uint = 2; +pub const BTF_KIND_ARRAY: ::std::os::raw::c_uint = 3; +pub const BTF_KIND_STRUCT: ::std::os::raw::c_uint = 4; +pub const BTF_KIND_UNION: ::std::os::raw::c_uint = 5; +pub const BTF_KIND_ENUM: ::std::os::raw::c_uint = 6; +pub const BTF_KIND_FWD: ::std::os::raw::c_uint = 7; +pub const BTF_KIND_TYPEDEF: ::std::os::raw::c_uint = 8; +pub const BTF_KIND_VOLATILE: ::std::os::raw::c_uint = 9; +pub const BTF_KIND_CONST: ::std::os::raw::c_uint = 10; +pub const BTF_KIND_RESTRICT: ::std::os::raw::c_uint = 11; +pub const BTF_KIND_FUNC: ::std::os::raw::c_uint = 12; +pub const BTF_KIND_FUNC_PROTO: ::std::os::raw::c_uint = 13; +pub const BTF_KIND_VAR: ::std::os::raw::c_uint = 14; +pub const BTF_KIND_DATASEC: ::std::os::raw::c_uint = 15; +pub const BTF_KIND_FLOAT: ::std::os::raw::c_uint = 16; +pub const BTF_KIND_TAG: ::std::os::raw::c_uint = 17; +pub const NR_BTF_KINDS: ::std::os::raw::c_uint = 18; +pub const BTF_KIND_MAX: ::std::os::raw::c_uint = 17; +pub type _bindgen_ty_37 = ::std::os::raw::c_uint; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct btf_enum { @@ -1722,19 +1725,19 @@ pub enum perf_event_type { PERF_RECORD_TEXT_POKE = 20, PERF_RECORD_MAX = 21, } -pub const IFLA_XDP_UNSPEC: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_UNSPEC; -pub const IFLA_XDP_FD: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_FD; -pub const IFLA_XDP_ATTACHED: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_ATTACHED; -pub const IFLA_XDP_FLAGS: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_FLAGS; -pub const IFLA_XDP_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_PROG_ID; -pub const IFLA_XDP_DRV_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_DRV_PROG_ID; -pub const IFLA_XDP_SKB_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_SKB_PROG_ID; -pub const IFLA_XDP_HW_PROG_ID: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_HW_PROG_ID; -pub const IFLA_XDP_EXPECTED_FD: _bindgen_ty_80 = _bindgen_ty_80::IFLA_XDP_EXPECTED_FD; -pub const __IFLA_XDP_MAX: _bindgen_ty_80 = _bindgen_ty_80::__IFLA_XDP_MAX; +pub const IFLA_XDP_UNSPEC: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_UNSPEC; +pub const IFLA_XDP_FD: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_FD; +pub const IFLA_XDP_ATTACHED: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_ATTACHED; +pub const IFLA_XDP_FLAGS: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_FLAGS; +pub const IFLA_XDP_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_PROG_ID; +pub const IFLA_XDP_DRV_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_DRV_PROG_ID; +pub const IFLA_XDP_SKB_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_SKB_PROG_ID; +pub const IFLA_XDP_HW_PROG_ID: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_HW_PROG_ID; +pub const IFLA_XDP_EXPECTED_FD: _bindgen_ty_81 = _bindgen_ty_81::IFLA_XDP_EXPECTED_FD; +pub const __IFLA_XDP_MAX: _bindgen_ty_81 = _bindgen_ty_81::__IFLA_XDP_MAX; #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum _bindgen_ty_80 { +pub enum _bindgen_ty_81 { IFLA_XDP_UNSPEC = 0, IFLA_XDP_FD = 1, IFLA_XDP_ATTACHED = 2, @@ -1767,25 +1770,26 @@ pub struct tcmsg { pub tcm_parent: __u32, pub tcm_info: __u32, } -pub const TCA_UNSPEC: _bindgen_ty_92 = _bindgen_ty_92::TCA_UNSPEC; -pub const TCA_KIND: _bindgen_ty_92 = _bindgen_ty_92::TCA_KIND; -pub const TCA_OPTIONS: _bindgen_ty_92 = _bindgen_ty_92::TCA_OPTIONS; -pub const TCA_STATS: _bindgen_ty_92 = _bindgen_ty_92::TCA_STATS; -pub const TCA_XSTATS: _bindgen_ty_92 = _bindgen_ty_92::TCA_XSTATS; -pub const TCA_RATE: _bindgen_ty_92 = _bindgen_ty_92::TCA_RATE; -pub const TCA_FCNT: _bindgen_ty_92 = _bindgen_ty_92::TCA_FCNT; -pub const TCA_STATS2: _bindgen_ty_92 = _bindgen_ty_92::TCA_STATS2; -pub const TCA_STAB: _bindgen_ty_92 = _bindgen_ty_92::TCA_STAB; -pub const TCA_PAD: _bindgen_ty_92 = _bindgen_ty_92::TCA_PAD; -pub const TCA_DUMP_INVISIBLE: _bindgen_ty_92 = _bindgen_ty_92::TCA_DUMP_INVISIBLE; -pub const TCA_CHAIN: _bindgen_ty_92 = _bindgen_ty_92::TCA_CHAIN; -pub const TCA_HW_OFFLOAD: _bindgen_ty_92 = _bindgen_ty_92::TCA_HW_OFFLOAD; -pub const TCA_INGRESS_BLOCK: _bindgen_ty_92 = _bindgen_ty_92::TCA_INGRESS_BLOCK; -pub const TCA_EGRESS_BLOCK: _bindgen_ty_92 = _bindgen_ty_92::TCA_EGRESS_BLOCK; -pub const __TCA_MAX: _bindgen_ty_92 = _bindgen_ty_92::__TCA_MAX; +pub const TCA_UNSPEC: _bindgen_ty_95 = _bindgen_ty_95::TCA_UNSPEC; +pub const TCA_KIND: _bindgen_ty_95 = _bindgen_ty_95::TCA_KIND; +pub const TCA_OPTIONS: _bindgen_ty_95 = _bindgen_ty_95::TCA_OPTIONS; +pub const TCA_STATS: _bindgen_ty_95 = _bindgen_ty_95::TCA_STATS; +pub const TCA_XSTATS: _bindgen_ty_95 = _bindgen_ty_95::TCA_XSTATS; +pub const TCA_RATE: _bindgen_ty_95 = _bindgen_ty_95::TCA_RATE; +pub const TCA_FCNT: _bindgen_ty_95 = _bindgen_ty_95::TCA_FCNT; +pub const TCA_STATS2: _bindgen_ty_95 = _bindgen_ty_95::TCA_STATS2; +pub const TCA_STAB: _bindgen_ty_95 = _bindgen_ty_95::TCA_STAB; +pub const TCA_PAD: _bindgen_ty_95 = _bindgen_ty_95::TCA_PAD; +pub const TCA_DUMP_INVISIBLE: _bindgen_ty_95 = _bindgen_ty_95::TCA_DUMP_INVISIBLE; +pub const TCA_CHAIN: _bindgen_ty_95 = _bindgen_ty_95::TCA_CHAIN; +pub const TCA_HW_OFFLOAD: _bindgen_ty_95 = _bindgen_ty_95::TCA_HW_OFFLOAD; +pub const TCA_INGRESS_BLOCK: _bindgen_ty_95 = _bindgen_ty_95::TCA_INGRESS_BLOCK; +pub const TCA_EGRESS_BLOCK: _bindgen_ty_95 = _bindgen_ty_95::TCA_EGRESS_BLOCK; +pub const TCA_DUMP_FLAGS: _bindgen_ty_95 = _bindgen_ty_95::TCA_DUMP_FLAGS; +pub const __TCA_MAX: _bindgen_ty_95 = _bindgen_ty_95::__TCA_MAX; #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum _bindgen_ty_92 { +pub enum _bindgen_ty_95 { TCA_UNSPEC = 0, TCA_KIND = 1, TCA_OPTIONS = 2, @@ -1801,24 +1805,25 @@ pub enum _bindgen_ty_92 { TCA_HW_OFFLOAD = 12, TCA_INGRESS_BLOCK = 13, TCA_EGRESS_BLOCK = 14, - __TCA_MAX = 15, -} -pub const TCA_BPF_UNSPEC: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_UNSPEC; -pub const TCA_BPF_ACT: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_ACT; -pub const TCA_BPF_POLICE: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_POLICE; -pub const TCA_BPF_CLASSID: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_CLASSID; -pub const TCA_BPF_OPS_LEN: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_OPS_LEN; -pub const TCA_BPF_OPS: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_OPS; -pub const TCA_BPF_FD: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_FD; -pub const TCA_BPF_NAME: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_NAME; -pub const TCA_BPF_FLAGS: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_FLAGS; -pub const TCA_BPF_FLAGS_GEN: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_FLAGS_GEN; -pub const TCA_BPF_TAG: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_TAG; -pub const TCA_BPF_ID: _bindgen_ty_148 = _bindgen_ty_148::TCA_BPF_ID; -pub const __TCA_BPF_MAX: _bindgen_ty_148 = _bindgen_ty_148::__TCA_BPF_MAX; + TCA_DUMP_FLAGS = 15, + __TCA_MAX = 16, +} +pub const TCA_BPF_UNSPEC: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_UNSPEC; +pub const TCA_BPF_ACT: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_ACT; +pub const TCA_BPF_POLICE: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_POLICE; +pub const TCA_BPF_CLASSID: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_CLASSID; +pub const TCA_BPF_OPS_LEN: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_OPS_LEN; +pub const TCA_BPF_OPS: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_OPS; +pub const TCA_BPF_FD: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_FD; +pub const TCA_BPF_NAME: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_NAME; +pub const TCA_BPF_FLAGS: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_FLAGS; +pub const TCA_BPF_FLAGS_GEN: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_FLAGS_GEN; +pub const TCA_BPF_TAG: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_TAG; +pub const TCA_BPF_ID: _bindgen_ty_151 = _bindgen_ty_151::TCA_BPF_ID; +pub const __TCA_BPF_MAX: _bindgen_ty_151 = _bindgen_ty_151::__TCA_BPF_MAX; #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum _bindgen_ty_148 { +pub enum _bindgen_ty_151 { TCA_BPF_UNSPEC = 0, TCA_BPF_ACT = 1, TCA_BPF_POLICE = 2, diff --git a/bpf/aya-bpf-bindings/src/aarch64/bindings.rs b/bpf/aya-bpf-bindings/src/aarch64/bindings.rs index e3946da5..c57d6a1e 100644 --- a/bpf/aya-bpf-bindings/src/aarch64/bindings.rs +++ b/bpf/aya-bpf-bindings/src/aarch64/bindings.rs @@ -228,6 +228,9 @@ pub const SO_TIMESTAMPING_NEW: u32 = 65; pub const SO_RCVTIMEO_NEW: u32 = 66; pub const SO_SNDTIMEO_NEW: u32 = 67; pub const SO_DETACH_REUSEPORT_BPF: u32 = 68; +pub const SO_PREFER_BUSY_POLL: u32 = 69; +pub const SO_BUSY_POLL_BUDGET: u32 = 70; +pub const SO_NETNS_COOKIE: u32 = 71; pub const SO_TIMESTAMP: u32 = 29; pub const SO_TIMESTAMPNS: u32 = 35; pub const SO_TIMESTAMPING: u32 = 37; @@ -431,6 +434,9 @@ pub struct __sk_buff { pub gso_segs: __u32, pub __bindgen_anon_2: __sk_buff__bindgen_ty_2, pub gso_size: __u32, + pub _bitfield_align_1: [u8; 0], + pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, + pub hwtstamp: __u64, } #[repr(C)] #[derive(Copy, Clone)] @@ -438,7 +444,6 @@ pub union __sk_buff__bindgen_ty_1 { pub flow_keys: *mut bpf_flow_keys, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl __sk_buff__bindgen_ty_1 { #[inline] @@ -453,7 +458,6 @@ pub union __sk_buff__bindgen_ty_2 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl __sk_buff__bindgen_ty_2 { #[inline] @@ -462,6 +466,13 @@ impl __sk_buff__bindgen_ty_2 { __bindgen_bitfield_unit } } +impl __sk_buff { + #[inline] + pub fn new_bitfield_1() -> __BindgenBitfieldUnit<[u8; 4usize]> { + let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); + __bindgen_bitfield_unit + } +} #[repr(C)] #[derive(Copy, Clone)] pub struct bpf_tunnel_key { @@ -477,7 +488,6 @@ pub struct bpf_tunnel_key { pub union bpf_tunnel_key__bindgen_ty_1 { pub remote_ipv4: __u32, pub remote_ipv6: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] @@ -493,7 +503,6 @@ pub struct bpf_xfrm_state { pub union bpf_xfrm_state__bindgen_ty_1 { pub remote_ipv4: __u32, pub remote_ipv6: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -553,7 +562,6 @@ pub struct bpf_sock_tuple { pub union bpf_sock_tuple__bindgen_ty_1 { pub ipv4: bpf_sock_tuple__bindgen_ty_1__bindgen_ty_1, pub ipv6: bpf_sock_tuple__bindgen_ty_1__bindgen_ty_2, - _bindgen_union_align: [u32; 9usize], } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -615,7 +623,6 @@ pub union sk_msg_md__bindgen_ty_1 { pub data: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_msg_md__bindgen_ty_1 { #[inline] @@ -630,7 +637,6 @@ pub union sk_msg_md__bindgen_ty_2 { pub data_end: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_msg_md__bindgen_ty_2 { #[inline] @@ -645,7 +651,6 @@ pub union sk_msg_md__bindgen_ty_3 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_msg_md__bindgen_ty_3 { #[inline] @@ -673,7 +678,6 @@ pub union sk_reuseport_md__bindgen_ty_1 { pub data: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_1 { #[inline] @@ -688,7 +692,6 @@ pub union sk_reuseport_md__bindgen_ty_2 { pub data_end: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_2 { #[inline] @@ -703,7 +706,6 @@ pub union sk_reuseport_md__bindgen_ty_3 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_3 { #[inline] @@ -718,7 +720,6 @@ pub union sk_reuseport_md__bindgen_ty_4 { pub migrating_sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_4 { #[inline] @@ -765,7 +766,6 @@ pub union bpf_sock_addr__bindgen_ty_1 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_addr__bindgen_ty_1 { #[inline] @@ -824,7 +824,6 @@ pub union bpf_sock_ops__bindgen_ty_1 { pub args: [__u32; 4usize], pub reply: __u32, pub replylong: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] @@ -832,7 +831,6 @@ pub union bpf_sock_ops__bindgen_ty_2 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_ops__bindgen_ty_2 { #[inline] @@ -847,7 +845,6 @@ pub union bpf_sock_ops__bindgen_ty_3 { pub skb_data: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_ops__bindgen_ty_3 { #[inline] @@ -862,7 +859,6 @@ pub union bpf_sock_ops__bindgen_ty_4 { pub skb_data_end: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_ops__bindgen_ty_4 { #[inline] @@ -969,7 +965,6 @@ pub struct bpf_fib_lookup { pub union bpf_fib_lookup__bindgen_ty_1 { pub tot_len: __u16, pub mtu_result: __u16, - _bindgen_union_align: u16, } #[repr(C)] #[derive(Copy, Clone)] @@ -977,21 +972,18 @@ pub union bpf_fib_lookup__bindgen_ty_2 { pub tos: __u8, pub flowinfo: __be32, pub rt_metric: __u32, - _bindgen_union_align: u32, } #[repr(C)] #[derive(Copy, Clone)] pub union bpf_fib_lookup__bindgen_ty_3 { pub ipv4_src: __be32, pub ipv6_src: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] pub union bpf_fib_lookup__bindgen_ty_4 { pub ipv4_dst: __be32, pub ipv6_dst: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] @@ -1004,7 +996,6 @@ pub struct bpf_redir_neigh { pub union bpf_redir_neigh__bindgen_ty_1 { pub ipv4_nh: __be32, pub ipv6_nh: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } pub const BPF_FLOW_DISSECTOR_F_PARSE_1ST_FRAG: ::aya_bpf_cty::c_uint = 1; pub const BPF_FLOW_DISSECTOR_F_STOP_AT_FLOW_LABEL: ::aya_bpf_cty::c_uint = 2; @@ -1032,7 +1023,6 @@ pub struct bpf_flow_keys { pub union bpf_flow_keys__bindgen_ty_1 { pub __bindgen_anon_1: bpf_flow_keys__bindgen_ty_1__bindgen_ty_1, pub __bindgen_anon_2: bpf_flow_keys__bindgen_ty_1__bindgen_ty_2, - _bindgen_union_align: [u32; 8usize], } #[repr(C)] #[derive(Debug, Copy, Clone)] diff --git a/bpf/aya-bpf-bindings/src/aarch64/getters.rs b/bpf/aya-bpf-bindings/src/aarch64/getters.rs index 39534eb9..fa62dbce 100644 --- a/bpf/aya-bpf-bindings/src/aarch64/getters.rs +++ b/bpf/aya-bpf-bindings/src/aarch64/getters.rs @@ -107,6 +107,9 @@ impl __sk_buff { pub fn gso_size(&self) -> Option<__u32> { unsafe { crate::bpf_probe_read(&self.gso_size) }.ok() } + pub fn hwtstamp(&self) -> Option<__u64> { + unsafe { crate::bpf_probe_read(&self.hwtstamp) }.ok() + } } impl __sk_buff__bindgen_ty_1 { pub fn flow_keys(&self) -> Option<*mut bpf_flow_keys> { diff --git a/bpf/aya-bpf-bindings/src/aarch64/helpers.rs b/bpf/aya-bpf-bindings/src/aarch64/helpers.rs index 8ce046b6..f8cb0f24 100644 --- a/bpf/aya-bpf-bindings/src/aarch64/helpers.rs +++ b/bpf/aya-bpf-bindings/src/aarch64/helpers.rs @@ -1759,3 +1759,34 @@ pub unsafe fn bpf_get_attach_cookie(ctx: *mut ::aya_bpf_cty::c_void) -> __u64 { ::core::mem::transmute(174usize); fun(ctx) } +pub unsafe fn bpf_task_pt_regs(task: *mut task_struct) -> ::aya_bpf_cty::c_long { + let fun: unsafe extern "C" fn(task: *mut task_struct) -> ::aya_bpf_cty::c_long = + ::core::mem::transmute(175usize); + fun(task) +} +pub unsafe fn bpf_get_branch_snapshot( + entries: *mut ::aya_bpf_cty::c_void, + size: __u32, + flags: __u64, +) -> ::aya_bpf_cty::c_long { + let fun: unsafe extern "C" fn( + entries: *mut ::aya_bpf_cty::c_void, + size: __u32, + flags: __u64, + ) -> ::aya_bpf_cty::c_long = ::core::mem::transmute(176usize); + fun(entries, size, flags) +} +pub unsafe fn bpf_trace_vprintk( + fmt: *const ::aya_bpf_cty::c_char, + fmt_size: __u32, + data: *const ::aya_bpf_cty::c_void, + data_len: __u32, +) -> ::aya_bpf_cty::c_long { + let fun: unsafe extern "C" fn( + fmt: *const ::aya_bpf_cty::c_char, + fmt_size: __u32, + data: *const ::aya_bpf_cty::c_void, + data_len: __u32, + ) -> ::aya_bpf_cty::c_long = ::core::mem::transmute(177usize); + fun(fmt, fmt_size, data, data_len) +} diff --git a/bpf/aya-bpf-bindings/src/armv7/bindings.rs b/bpf/aya-bpf-bindings/src/armv7/bindings.rs index e3946da5..c57d6a1e 100644 --- a/bpf/aya-bpf-bindings/src/armv7/bindings.rs +++ b/bpf/aya-bpf-bindings/src/armv7/bindings.rs @@ -228,6 +228,9 @@ pub const SO_TIMESTAMPING_NEW: u32 = 65; pub const SO_RCVTIMEO_NEW: u32 = 66; pub const SO_SNDTIMEO_NEW: u32 = 67; pub const SO_DETACH_REUSEPORT_BPF: u32 = 68; +pub const SO_PREFER_BUSY_POLL: u32 = 69; +pub const SO_BUSY_POLL_BUDGET: u32 = 70; +pub const SO_NETNS_COOKIE: u32 = 71; pub const SO_TIMESTAMP: u32 = 29; pub const SO_TIMESTAMPNS: u32 = 35; pub const SO_TIMESTAMPING: u32 = 37; @@ -431,6 +434,9 @@ pub struct __sk_buff { pub gso_segs: __u32, pub __bindgen_anon_2: __sk_buff__bindgen_ty_2, pub gso_size: __u32, + pub _bitfield_align_1: [u8; 0], + pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, + pub hwtstamp: __u64, } #[repr(C)] #[derive(Copy, Clone)] @@ -438,7 +444,6 @@ pub union __sk_buff__bindgen_ty_1 { pub flow_keys: *mut bpf_flow_keys, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl __sk_buff__bindgen_ty_1 { #[inline] @@ -453,7 +458,6 @@ pub union __sk_buff__bindgen_ty_2 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl __sk_buff__bindgen_ty_2 { #[inline] @@ -462,6 +466,13 @@ impl __sk_buff__bindgen_ty_2 { __bindgen_bitfield_unit } } +impl __sk_buff { + #[inline] + pub fn new_bitfield_1() -> __BindgenBitfieldUnit<[u8; 4usize]> { + let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); + __bindgen_bitfield_unit + } +} #[repr(C)] #[derive(Copy, Clone)] pub struct bpf_tunnel_key { @@ -477,7 +488,6 @@ pub struct bpf_tunnel_key { pub union bpf_tunnel_key__bindgen_ty_1 { pub remote_ipv4: __u32, pub remote_ipv6: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] @@ -493,7 +503,6 @@ pub struct bpf_xfrm_state { pub union bpf_xfrm_state__bindgen_ty_1 { pub remote_ipv4: __u32, pub remote_ipv6: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -553,7 +562,6 @@ pub struct bpf_sock_tuple { pub union bpf_sock_tuple__bindgen_ty_1 { pub ipv4: bpf_sock_tuple__bindgen_ty_1__bindgen_ty_1, pub ipv6: bpf_sock_tuple__bindgen_ty_1__bindgen_ty_2, - _bindgen_union_align: [u32; 9usize], } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -615,7 +623,6 @@ pub union sk_msg_md__bindgen_ty_1 { pub data: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_msg_md__bindgen_ty_1 { #[inline] @@ -630,7 +637,6 @@ pub union sk_msg_md__bindgen_ty_2 { pub data_end: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_msg_md__bindgen_ty_2 { #[inline] @@ -645,7 +651,6 @@ pub union sk_msg_md__bindgen_ty_3 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_msg_md__bindgen_ty_3 { #[inline] @@ -673,7 +678,6 @@ pub union sk_reuseport_md__bindgen_ty_1 { pub data: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_1 { #[inline] @@ -688,7 +692,6 @@ pub union sk_reuseport_md__bindgen_ty_2 { pub data_end: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_2 { #[inline] @@ -703,7 +706,6 @@ pub union sk_reuseport_md__bindgen_ty_3 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_3 { #[inline] @@ -718,7 +720,6 @@ pub union sk_reuseport_md__bindgen_ty_4 { pub migrating_sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_4 { #[inline] @@ -765,7 +766,6 @@ pub union bpf_sock_addr__bindgen_ty_1 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_addr__bindgen_ty_1 { #[inline] @@ -824,7 +824,6 @@ pub union bpf_sock_ops__bindgen_ty_1 { pub args: [__u32; 4usize], pub reply: __u32, pub replylong: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] @@ -832,7 +831,6 @@ pub union bpf_sock_ops__bindgen_ty_2 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_ops__bindgen_ty_2 { #[inline] @@ -847,7 +845,6 @@ pub union bpf_sock_ops__bindgen_ty_3 { pub skb_data: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_ops__bindgen_ty_3 { #[inline] @@ -862,7 +859,6 @@ pub union bpf_sock_ops__bindgen_ty_4 { pub skb_data_end: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_ops__bindgen_ty_4 { #[inline] @@ -969,7 +965,6 @@ pub struct bpf_fib_lookup { pub union bpf_fib_lookup__bindgen_ty_1 { pub tot_len: __u16, pub mtu_result: __u16, - _bindgen_union_align: u16, } #[repr(C)] #[derive(Copy, Clone)] @@ -977,21 +972,18 @@ pub union bpf_fib_lookup__bindgen_ty_2 { pub tos: __u8, pub flowinfo: __be32, pub rt_metric: __u32, - _bindgen_union_align: u32, } #[repr(C)] #[derive(Copy, Clone)] pub union bpf_fib_lookup__bindgen_ty_3 { pub ipv4_src: __be32, pub ipv6_src: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] pub union bpf_fib_lookup__bindgen_ty_4 { pub ipv4_dst: __be32, pub ipv6_dst: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] @@ -1004,7 +996,6 @@ pub struct bpf_redir_neigh { pub union bpf_redir_neigh__bindgen_ty_1 { pub ipv4_nh: __be32, pub ipv6_nh: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } pub const BPF_FLOW_DISSECTOR_F_PARSE_1ST_FRAG: ::aya_bpf_cty::c_uint = 1; pub const BPF_FLOW_DISSECTOR_F_STOP_AT_FLOW_LABEL: ::aya_bpf_cty::c_uint = 2; @@ -1032,7 +1023,6 @@ pub struct bpf_flow_keys { pub union bpf_flow_keys__bindgen_ty_1 { pub __bindgen_anon_1: bpf_flow_keys__bindgen_ty_1__bindgen_ty_1, pub __bindgen_anon_2: bpf_flow_keys__bindgen_ty_1__bindgen_ty_2, - _bindgen_union_align: [u32; 8usize], } #[repr(C)] #[derive(Debug, Copy, Clone)] diff --git a/bpf/aya-bpf-bindings/src/armv7/getters.rs b/bpf/aya-bpf-bindings/src/armv7/getters.rs index 39534eb9..fa62dbce 100644 --- a/bpf/aya-bpf-bindings/src/armv7/getters.rs +++ b/bpf/aya-bpf-bindings/src/armv7/getters.rs @@ -107,6 +107,9 @@ impl __sk_buff { pub fn gso_size(&self) -> Option<__u32> { unsafe { crate::bpf_probe_read(&self.gso_size) }.ok() } + pub fn hwtstamp(&self) -> Option<__u64> { + unsafe { crate::bpf_probe_read(&self.hwtstamp) }.ok() + } } impl __sk_buff__bindgen_ty_1 { pub fn flow_keys(&self) -> Option<*mut bpf_flow_keys> { diff --git a/bpf/aya-bpf-bindings/src/armv7/helpers.rs b/bpf/aya-bpf-bindings/src/armv7/helpers.rs index 8ce046b6..f8cb0f24 100644 --- a/bpf/aya-bpf-bindings/src/armv7/helpers.rs +++ b/bpf/aya-bpf-bindings/src/armv7/helpers.rs @@ -1759,3 +1759,34 @@ pub unsafe fn bpf_get_attach_cookie(ctx: *mut ::aya_bpf_cty::c_void) -> __u64 { ::core::mem::transmute(174usize); fun(ctx) } +pub unsafe fn bpf_task_pt_regs(task: *mut task_struct) -> ::aya_bpf_cty::c_long { + let fun: unsafe extern "C" fn(task: *mut task_struct) -> ::aya_bpf_cty::c_long = + ::core::mem::transmute(175usize); + fun(task) +} +pub unsafe fn bpf_get_branch_snapshot( + entries: *mut ::aya_bpf_cty::c_void, + size: __u32, + flags: __u64, +) -> ::aya_bpf_cty::c_long { + let fun: unsafe extern "C" fn( + entries: *mut ::aya_bpf_cty::c_void, + size: __u32, + flags: __u64, + ) -> ::aya_bpf_cty::c_long = ::core::mem::transmute(176usize); + fun(entries, size, flags) +} +pub unsafe fn bpf_trace_vprintk( + fmt: *const ::aya_bpf_cty::c_char, + fmt_size: __u32, + data: *const ::aya_bpf_cty::c_void, + data_len: __u32, +) -> ::aya_bpf_cty::c_long { + let fun: unsafe extern "C" fn( + fmt: *const ::aya_bpf_cty::c_char, + fmt_size: __u32, + data: *const ::aya_bpf_cty::c_void, + data_len: __u32, + ) -> ::aya_bpf_cty::c_long = ::core::mem::transmute(177usize); + fun(fmt, fmt_size, data, data_len) +} diff --git a/bpf/aya-bpf-bindings/src/x86_64/bindings.rs b/bpf/aya-bpf-bindings/src/x86_64/bindings.rs index e3946da5..c57d6a1e 100644 --- a/bpf/aya-bpf-bindings/src/x86_64/bindings.rs +++ b/bpf/aya-bpf-bindings/src/x86_64/bindings.rs @@ -228,6 +228,9 @@ pub const SO_TIMESTAMPING_NEW: u32 = 65; pub const SO_RCVTIMEO_NEW: u32 = 66; pub const SO_SNDTIMEO_NEW: u32 = 67; pub const SO_DETACH_REUSEPORT_BPF: u32 = 68; +pub const SO_PREFER_BUSY_POLL: u32 = 69; +pub const SO_BUSY_POLL_BUDGET: u32 = 70; +pub const SO_NETNS_COOKIE: u32 = 71; pub const SO_TIMESTAMP: u32 = 29; pub const SO_TIMESTAMPNS: u32 = 35; pub const SO_TIMESTAMPING: u32 = 37; @@ -431,6 +434,9 @@ pub struct __sk_buff { pub gso_segs: __u32, pub __bindgen_anon_2: __sk_buff__bindgen_ty_2, pub gso_size: __u32, + pub _bitfield_align_1: [u8; 0], + pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, + pub hwtstamp: __u64, } #[repr(C)] #[derive(Copy, Clone)] @@ -438,7 +444,6 @@ pub union __sk_buff__bindgen_ty_1 { pub flow_keys: *mut bpf_flow_keys, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl __sk_buff__bindgen_ty_1 { #[inline] @@ -453,7 +458,6 @@ pub union __sk_buff__bindgen_ty_2 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl __sk_buff__bindgen_ty_2 { #[inline] @@ -462,6 +466,13 @@ impl __sk_buff__bindgen_ty_2 { __bindgen_bitfield_unit } } +impl __sk_buff { + #[inline] + pub fn new_bitfield_1() -> __BindgenBitfieldUnit<[u8; 4usize]> { + let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); + __bindgen_bitfield_unit + } +} #[repr(C)] #[derive(Copy, Clone)] pub struct bpf_tunnel_key { @@ -477,7 +488,6 @@ pub struct bpf_tunnel_key { pub union bpf_tunnel_key__bindgen_ty_1 { pub remote_ipv4: __u32, pub remote_ipv6: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] @@ -493,7 +503,6 @@ pub struct bpf_xfrm_state { pub union bpf_xfrm_state__bindgen_ty_1 { pub remote_ipv4: __u32, pub remote_ipv6: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -553,7 +562,6 @@ pub struct bpf_sock_tuple { pub union bpf_sock_tuple__bindgen_ty_1 { pub ipv4: bpf_sock_tuple__bindgen_ty_1__bindgen_ty_1, pub ipv6: bpf_sock_tuple__bindgen_ty_1__bindgen_ty_2, - _bindgen_union_align: [u32; 9usize], } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -615,7 +623,6 @@ pub union sk_msg_md__bindgen_ty_1 { pub data: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_msg_md__bindgen_ty_1 { #[inline] @@ -630,7 +637,6 @@ pub union sk_msg_md__bindgen_ty_2 { pub data_end: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_msg_md__bindgen_ty_2 { #[inline] @@ -645,7 +651,6 @@ pub union sk_msg_md__bindgen_ty_3 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_msg_md__bindgen_ty_3 { #[inline] @@ -673,7 +678,6 @@ pub union sk_reuseport_md__bindgen_ty_1 { pub data: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_1 { #[inline] @@ -688,7 +692,6 @@ pub union sk_reuseport_md__bindgen_ty_2 { pub data_end: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_2 { #[inline] @@ -703,7 +706,6 @@ pub union sk_reuseport_md__bindgen_ty_3 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_3 { #[inline] @@ -718,7 +720,6 @@ pub union sk_reuseport_md__bindgen_ty_4 { pub migrating_sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl sk_reuseport_md__bindgen_ty_4 { #[inline] @@ -765,7 +766,6 @@ pub union bpf_sock_addr__bindgen_ty_1 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_addr__bindgen_ty_1 { #[inline] @@ -824,7 +824,6 @@ pub union bpf_sock_ops__bindgen_ty_1 { pub args: [__u32; 4usize], pub reply: __u32, pub replylong: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] @@ -832,7 +831,6 @@ pub union bpf_sock_ops__bindgen_ty_2 { pub sk: *mut bpf_sock, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_ops__bindgen_ty_2 { #[inline] @@ -847,7 +845,6 @@ pub union bpf_sock_ops__bindgen_ty_3 { pub skb_data: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_ops__bindgen_ty_3 { #[inline] @@ -862,7 +859,6 @@ pub union bpf_sock_ops__bindgen_ty_4 { pub skb_data_end: *mut ::aya_bpf_cty::c_void, pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, - _bindgen_union_align: u64, } impl bpf_sock_ops__bindgen_ty_4 { #[inline] @@ -969,7 +965,6 @@ pub struct bpf_fib_lookup { pub union bpf_fib_lookup__bindgen_ty_1 { pub tot_len: __u16, pub mtu_result: __u16, - _bindgen_union_align: u16, } #[repr(C)] #[derive(Copy, Clone)] @@ -977,21 +972,18 @@ pub union bpf_fib_lookup__bindgen_ty_2 { pub tos: __u8, pub flowinfo: __be32, pub rt_metric: __u32, - _bindgen_union_align: u32, } #[repr(C)] #[derive(Copy, Clone)] pub union bpf_fib_lookup__bindgen_ty_3 { pub ipv4_src: __be32, pub ipv6_src: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] pub union bpf_fib_lookup__bindgen_ty_4 { pub ipv4_dst: __be32, pub ipv6_dst: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } #[repr(C)] #[derive(Copy, Clone)] @@ -1004,7 +996,6 @@ pub struct bpf_redir_neigh { pub union bpf_redir_neigh__bindgen_ty_1 { pub ipv4_nh: __be32, pub ipv6_nh: [__u32; 4usize], - _bindgen_union_align: [u32; 4usize], } pub const BPF_FLOW_DISSECTOR_F_PARSE_1ST_FRAG: ::aya_bpf_cty::c_uint = 1; pub const BPF_FLOW_DISSECTOR_F_STOP_AT_FLOW_LABEL: ::aya_bpf_cty::c_uint = 2; @@ -1032,7 +1023,6 @@ pub struct bpf_flow_keys { pub union bpf_flow_keys__bindgen_ty_1 { pub __bindgen_anon_1: bpf_flow_keys__bindgen_ty_1__bindgen_ty_1, pub __bindgen_anon_2: bpf_flow_keys__bindgen_ty_1__bindgen_ty_2, - _bindgen_union_align: [u32; 8usize], } #[repr(C)] #[derive(Debug, Copy, Clone)] diff --git a/bpf/aya-bpf-bindings/src/x86_64/getters.rs b/bpf/aya-bpf-bindings/src/x86_64/getters.rs index 39534eb9..fa62dbce 100644 --- a/bpf/aya-bpf-bindings/src/x86_64/getters.rs +++ b/bpf/aya-bpf-bindings/src/x86_64/getters.rs @@ -107,6 +107,9 @@ impl __sk_buff { pub fn gso_size(&self) -> Option<__u32> { unsafe { crate::bpf_probe_read(&self.gso_size) }.ok() } + pub fn hwtstamp(&self) -> Option<__u64> { + unsafe { crate::bpf_probe_read(&self.hwtstamp) }.ok() + } } impl __sk_buff__bindgen_ty_1 { pub fn flow_keys(&self) -> Option<*mut bpf_flow_keys> { diff --git a/bpf/aya-bpf-bindings/src/x86_64/helpers.rs b/bpf/aya-bpf-bindings/src/x86_64/helpers.rs index 8ce046b6..f8cb0f24 100644 --- a/bpf/aya-bpf-bindings/src/x86_64/helpers.rs +++ b/bpf/aya-bpf-bindings/src/x86_64/helpers.rs @@ -1759,3 +1759,34 @@ pub unsafe fn bpf_get_attach_cookie(ctx: *mut ::aya_bpf_cty::c_void) -> __u64 { ::core::mem::transmute(174usize); fun(ctx) } +pub unsafe fn bpf_task_pt_regs(task: *mut task_struct) -> ::aya_bpf_cty::c_long { + let fun: unsafe extern "C" fn(task: *mut task_struct) -> ::aya_bpf_cty::c_long = + ::core::mem::transmute(175usize); + fun(task) +} +pub unsafe fn bpf_get_branch_snapshot( + entries: *mut ::aya_bpf_cty::c_void, + size: __u32, + flags: __u64, +) -> ::aya_bpf_cty::c_long { + let fun: unsafe extern "C" fn( + entries: *mut ::aya_bpf_cty::c_void, + size: __u32, + flags: __u64, + ) -> ::aya_bpf_cty::c_long = ::core::mem::transmute(176usize); + fun(entries, size, flags) +} +pub unsafe fn bpf_trace_vprintk( + fmt: *const ::aya_bpf_cty::c_char, + fmt_size: __u32, + data: *const ::aya_bpf_cty::c_void, + data_len: __u32, +) -> ::aya_bpf_cty::c_long { + let fun: unsafe extern "C" fn( + fmt: *const ::aya_bpf_cty::c_char, + fmt_size: __u32, + data: *const ::aya_bpf_cty::c_void, + data_len: __u32, + ) -> ::aya_bpf_cty::c_long = ::core::mem::transmute(177usize); + fun(fmt, fmt_size, data, data_len) +} diff --git a/xtask/src/codegen/aya.rs b/xtask/src/codegen/aya.rs index 71164eeb..7164a246 100644 --- a/xtask/src/codegen/aya.rs +++ b/xtask/src/codegen/aya.rs @@ -112,8 +112,8 @@ fn codegen_bindings(opts: &Options) -> Result<(), anyhow::Error> { "SO_ATTACH_BPF", "SO_DETACH_BPF", // BTF - "BTF_KIND_.*", "BTF_INT_.*", + "BTF_KIND_.*", // PERF "PERF_FLAG_.*", "PERF_EVENT_.*", @@ -161,7 +161,7 @@ fn codegen_bindings(opts: &Options) -> Result<(), anyhow::Error> { bindgen = bindgen.allowlist_type(x); } for x in &vars { - bindgen = bindgen.allowlist_var(x); + bindgen = bindgen.allowlist_var(x).constified_enum("BTF_KIND_.*"); } // FIXME: this stuff is probably debian/ubuntu specific