#[non_exhaustive]#[repr(u32)]pub enum BpfHelper {
Show 209 variants
Unspec = 0,
MapLookupElem = 1,
MapUpdateElem = 2,
MapDeleteElem = 3,
ProbeRead = 4,
KtimeGetNs = 5,
TracePrintk = 6,
GetPrandomU32 = 7,
GetSmpProcessorId = 8,
SkbStoreBytes = 9,
L3CsumReplace = 10,
L4CsumReplace = 11,
TailCall = 12,
CloneRedirect = 13,
GetCurrentPidTgid = 14,
GetCurrentUidGid = 15,
GetCurrentComm = 16,
GetCgroupClassid = 17,
SkbVlanPush = 18,
SkbVlanPop = 19,
SkbGetTunnelKey = 20,
SkbSetTunnelKey = 21,
PerfEventRead = 22,
Redirect = 23,
GetRouteRealm = 24,
PerfEventOutput = 25,
SkbLoadBytes = 26,
GetStackid = 27,
CsumDiff = 28,
SkbGetTunnelOpt = 29,
SkbSetTunnelOpt = 30,
SkbChangeProto = 31,
SkbChangeType = 32,
SkbUnderCgroup = 33,
GetHashRecalc = 34,
GetCurrentTask = 35,
ProbeWriteUser = 36,
CurrentTaskUnderCgroup = 37,
SkbChangeTail = 38,
SkbPullData = 39,
CsumUpdate = 40,
SetHashInvalid = 41,
GetNumaNodeId = 42,
SkbChangeHead = 43,
XdpAdjustHead = 44,
ProbeReadStr = 45,
GetSocketCookie = 46,
GetSocketUid = 47,
SetHash = 48,
Setsockopt = 49,
SkbAdjustRoom = 50,
RedirectMap = 51,
SkRedirectMap = 52,
SockMapUpdate = 53,
XdpAdjustMeta = 54,
PerfEventReadValue = 55,
PerfProgReadValue = 56,
Getsockopt = 57,
OverrideReturn = 58,
SockOpsCbFlagsSet = 59,
MsgRedirectMap = 60,
MsgApplyBytes = 61,
MsgCorkBytes = 62,
MsgPullData = 63,
Bind = 64,
XdpAdjustTail = 65,
SkbGetXfrmState = 66,
GetStack = 67,
SkbLoadBytesRelative = 68,
FibLookup = 69,
SockHashUpdate = 70,
MsgRedirectHash = 71,
SkRedirectHash = 72,
LwtPushEncap = 73,
LwtSeg6StoreBytes = 74,
LwtSeg6AdjustSrh = 75,
LwtSeg6Action = 76,
RcRepeat = 77,
RcKeydown = 78,
SkbCgroupId = 79,
GetCurrentCgroupId = 80,
GetLocalStorage = 81,
SkSelectReuseport = 82,
SkbAncestorCgroupId = 83,
SkLookupTcp = 84,
SkLookupUdp = 85,
SkRelease = 86,
MapPushElem = 87,
MapPopElem = 88,
MapPeekElem = 89,
MsgPushData = 90,
MsgPopData = 91,
RcPointerRel = 92,
SpinLock = 93,
SpinUnlock = 94,
SkFullsock = 95,
TcpSock = 96,
SkbEcnSetCe = 97,
GetListenerSock = 98,
SkcLookupTcp = 99,
TcpCheckSyncookie = 100,
SysctlGetName = 101,
SysctlGetCurrentValue = 102,
SysctlGetNewValue = 103,
SysctlSetNewValue = 104,
Strtol = 105,
Strtoul = 106,
SkStorageGet = 107,
SkStorageDelete = 108,
SendSignal = 109,
TcpGenSyncookie = 110,
SkbOutput = 111,
ProbeReadUser = 112,
ProbeReadKernel = 113,
ProbeReadUserStr = 114,
ProbeReadKernelStr = 115,
TcpSendAck = 116,
SendSignalThread = 117,
Jiffies64 = 118,
ReadBranchRecords = 119,
GetNsCurrentPidTgid = 120,
XdpOutput = 121,
GetNetnsCookie = 122,
GetCurrentAncestorCgroupId = 123,
SkAssign = 124,
KtimeGetBootNs = 125,
SeqPrintf = 126,
SeqWrite = 127,
SkCgroupId = 128,
SkAncestorCgroupId = 129,
RingbufOutput = 130,
RingbufReserve = 131,
RingbufSubmit = 132,
RingbufDiscard = 133,
RingbufQuery = 134,
CsumLevel = 135,
SkcToTcp6Sock = 136,
SkcToTcpSock = 137,
SkcToTcpTimewaitSock = 138,
SkcToTcpRequestSock = 139,
SkcToUdp6Sock = 140,
GetTaskStack = 141,
LoadHdrOpt = 142,
StoreHdrOpt = 143,
ReserveHdrOpt = 144,
InodeStorageGet = 145,
InodeStorageDelete = 146,
DPath = 147,
CopyFromUser = 148,
SnprintfBtf = 149,
SeqPrintfBtf = 150,
SkbCgroupClassid = 151,
RedirectNeigh = 152,
PerCpuPtr = 153,
ThisCpuPtr = 154,
RedirectPeer = 155,
TaskStorageGet = 156,
TaskStorageDelete = 157,
GetCurrentTaskBtf = 158,
BprmOptsSet = 159,
KtimeGetCoarseNs = 160,
ImaInodeHash = 161,
SockFromFile = 162,
CheckMtu = 163,
ForEachMapElem = 164,
Snprintf = 165,
SysBpf = 166,
BtfFindByNameKind = 167,
SysClose = 168,
TimerInit = 169,
TimerSetCallback = 170,
TimerStart = 171,
TimerCancel = 172,
GetFuncIp = 173,
GetAttachCookie = 174,
TaskPtRegs = 175,
GetBranchSnapshot = 176,
TraceVprintk = 177,
SkcToUnixSock = 178,
KallsymsLookupName = 179,
FindVma = 180,
Loop = 181,
Strncmp = 182,
GetFuncArg = 183,
GetFuncRet = 184,
GetFuncArgCnt = 185,
GetRetval = 186,
SetRetval = 187,
XdpGetBuffLen = 188,
XdpLoadBytes = 189,
XdpStoreBytes = 190,
CopyFromUserTask = 191,
SkbSetTstamp = 192,
ImaFileHash = 193,
KptrXchg = 194,
MapLookupPercpuElem = 195,
SkcToMptcpSock = 196,
DynptrFromMem = 197,
RingbufReserveDynptr = 198,
RingbufSubmitDynptr = 199,
RingbufDiscardDynptr = 200,
DynptrRead = 201,
DynptrWrite = 202,
DynptrData = 203,
TcpRawGenSyncookieIpv4 = 204,
TcpRawGenSyncookieIpv6 = 205,
TcpRawCheckSyncookieIpv4 = 206,
TcpRawCheckSyncookieIpv6 = 207,
KtimeGetTaiNs = 208,
}
Expand description
eBPF helper functions. See bpf-helpers(7)
The enum value represents the unique id reserved by the kernel to represent the helper function. This
unique id works almost as a counter with a max value:
__BPF_FUNC_MAX_ID
.
This max limit changes between kernel versions due to the addition of eBPF helper functions.
For more information on eBPF helper functions, check out (although slightly outdated) Marsden’s Oracle blog post.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Unspec = 0
MapLookupElem = 1
MapUpdateElem = 2
MapDeleteElem = 3
ProbeRead = 4
KtimeGetNs = 5
TracePrintk = 6
GetPrandomU32 = 7
GetSmpProcessorId = 8
SkbStoreBytes = 9
L3CsumReplace = 10
L4CsumReplace = 11
TailCall = 12
CloneRedirect = 13
GetCurrentPidTgid = 14
GetCurrentUidGid = 15
GetCurrentComm = 16
GetCgroupClassid = 17
SkbVlanPush = 18
SkbVlanPop = 19
SkbGetTunnelKey = 20
SkbSetTunnelKey = 21
PerfEventRead = 22
Redirect = 23
GetRouteRealm = 24
PerfEventOutput = 25
SkbLoadBytes = 26
GetStackid = 27
CsumDiff = 28
SkbGetTunnelOpt = 29
SkbSetTunnelOpt = 30
SkbChangeProto = 31
SkbChangeType = 32
SkbUnderCgroup = 33
GetHashRecalc = 34
GetCurrentTask = 35
ProbeWriteUser = 36
CurrentTaskUnderCgroup = 37
SkbChangeTail = 38
SkbPullData = 39
CsumUpdate = 40
SetHashInvalid = 41
GetNumaNodeId = 42
SkbChangeHead = 43
XdpAdjustHead = 44
ProbeReadStr = 45
GetSocketCookie = 46
GetSocketUid = 47
SetHash = 48
Setsockopt = 49
SkbAdjustRoom = 50
RedirectMap = 51
SkRedirectMap = 52
SockMapUpdate = 53
XdpAdjustMeta = 54
PerfEventReadValue = 55
PerfProgReadValue = 56
Getsockopt = 57
OverrideReturn = 58
SockOpsCbFlagsSet = 59
MsgRedirectMap = 60
MsgApplyBytes = 61
MsgCorkBytes = 62
MsgPullData = 63
Bind = 64
XdpAdjustTail = 65
SkbGetXfrmState = 66
GetStack = 67
SkbLoadBytesRelative = 68
FibLookup = 69
SockHashUpdate = 70
MsgRedirectHash = 71
SkRedirectHash = 72
LwtPushEncap = 73
LwtSeg6StoreBytes = 74
LwtSeg6AdjustSrh = 75
LwtSeg6Action = 76
RcRepeat = 77
RcKeydown = 78
SkbCgroupId = 79
GetCurrentCgroupId = 80
GetLocalStorage = 81
SkSelectReuseport = 82
SkbAncestorCgroupId = 83
SkLookupTcp = 84
SkLookupUdp = 85
SkRelease = 86
MapPushElem = 87
MapPopElem = 88
MapPeekElem = 89
MsgPushData = 90
MsgPopData = 91
RcPointerRel = 92
SpinLock = 93
SpinUnlock = 94
SkFullsock = 95
TcpSock = 96
SkbEcnSetCe = 97
GetListenerSock = 98
SkcLookupTcp = 99
SysctlGetName = 101
SysctlGetCurrentValue = 102
SysctlGetNewValue = 103
SysctlSetNewValue = 104
Strtol = 105
Strtoul = 106
SkStorageGet = 107
SkStorageDelete = 108
SendSignal = 109
SkbOutput = 111
ProbeReadUser = 112
ProbeReadKernel = 113
ProbeReadUserStr = 114
ProbeReadKernelStr = 115
TcpSendAck = 116
SendSignalThread = 117
Jiffies64 = 118
ReadBranchRecords = 119
GetNsCurrentPidTgid = 120
XdpOutput = 121
GetNetnsCookie = 122
GetCurrentAncestorCgroupId = 123
SkAssign = 124
KtimeGetBootNs = 125
SeqPrintf = 126
SeqWrite = 127
SkCgroupId = 128
SkAncestorCgroupId = 129
RingbufOutput = 130
RingbufReserve = 131
RingbufSubmit = 132
RingbufDiscard = 133
RingbufQuery = 134
CsumLevel = 135
SkcToTcp6Sock = 136
SkcToTcpSock = 137
SkcToTcpTimewaitSock = 138
SkcToTcpRequestSock = 139
SkcToUdp6Sock = 140
GetTaskStack = 141
LoadHdrOpt = 142
StoreHdrOpt = 143
ReserveHdrOpt = 144
InodeStorageGet = 145
InodeStorageDelete = 146
DPath = 147
CopyFromUser = 148
SnprintfBtf = 149
SeqPrintfBtf = 150
SkbCgroupClassid = 151
RedirectNeigh = 152
PerCpuPtr = 153
ThisCpuPtr = 154
RedirectPeer = 155
TaskStorageGet = 156
TaskStorageDelete = 157
GetCurrentTaskBtf = 158
BprmOptsSet = 159
KtimeGetCoarseNs = 160
ImaInodeHash = 161
SockFromFile = 162
CheckMtu = 163
ForEachMapElem = 164
Snprintf = 165
SysBpf = 166
BtfFindByNameKind = 167
SysClose = 168
TimerInit = 169
TimerSetCallback = 170
TimerStart = 171
TimerCancel = 172
GetFuncIp = 173
GetAttachCookie = 174
TaskPtRegs = 175
GetBranchSnapshot = 176
TraceVprintk = 177
SkcToUnixSock = 178
KallsymsLookupName = 179
FindVma = 180
Loop = 181
Strncmp = 182
GetFuncArg = 183
GetFuncRet = 184
GetFuncArgCnt = 185
GetRetval = 186
SetRetval = 187
XdpGetBuffLen = 188
XdpLoadBytes = 189
XdpStoreBytes = 190
CopyFromUserTask = 191
SkbSetTstamp = 192
ImaFileHash = 193
KptrXchg = 194
MapLookupPercpuElem = 195
SkcToMptcpSock = 196
DynptrFromMem = 197
RingbufReserveDynptr = 198
RingbufSubmitDynptr = 199
RingbufDiscardDynptr = 200
DynptrRead = 201
DynptrWrite = 202
DynptrData = 203
KtimeGetTaiNs = 208
Implementations§
Trait Implementations§
Source§impl TryFromPrimitive for BpfHelper
impl TryFromPrimitive for BpfHelper
impl Copy for BpfHelper
impl Eq for BpfHelper
impl StructuralPartialEq for BpfHelper
Auto Trait Implementations§
impl Freeze for BpfHelper
impl RefUnwindSafe for BpfHelper
impl Send for BpfHelper
impl Sync for BpfHelper
impl Unpin for BpfHelper
impl UnwindSafe for BpfHelper
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more