P4C
The P4 Compiler
Toggle main menu visibility
Main Page
P4C Repository Organization
Getting Started
P4C Intermediate Representation (IR)
Frontend
Midend
Backends
Behavioral Model Backend
DPDK Backend
eBPF Backend
TC Backend
uBPF Backend
P4test Backend
Graphs Backend
p4fmt (P4 Formatter)
P4Tools
P4Smith
P4Testgen
Contribute to the P4 Compiler Project
Releases
Namespaces
Namespace List
Namespace Members
All
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
w
x
z
Functions
a
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
w
x
Variables
Typedefs
Enumerations
Enumerator
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
y
z
~
Functions
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
y
Typedefs
Enumerations
Enumerator
Related Symbols
•
All
Classes
Namespaces
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Modules
Pages
Loading...
Searching...
No Matches
ebpf_map.h
1
/*
2
Copyright 2018 VMware, Inc.
3
4
Licensed under the Apache License, Version 2.0 (the "License");
5
you may not use this file except in compliance with the License.
6
You may obtain a copy of the License at
7
8
http://www.apache.org/licenses/LICENSE-2.0
9
10
Unless required by applicable law or agreed to in writing, software
11
distributed under the License is distributed on an "AS IS" BASIS,
12
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
See the License for the specific language governing permissions and
14
limitations under the License.
15
*/
16
17
20
#ifndef BACKENDS_EBPF_RUNTIME_EBPF_MAP_H_
21
#define BACKENDS_EBPF_RUNTIME_EBPF_MAP_H_
22
23
#include "contrib/uthash.h"
// exports string.h, stddef.h, and stdlib.h
24
25
struct
bpf_map
{
26
void
*key;
27
void
*value;
28
UT_hash_handle
hh;
// makes this structure hashable
29
};
25
struct
bpf_map
{
…
};
30
37
int
bpf_map_update_elem(
struct
bpf_map
**map,
void
*key,
unsigned
int
key_size,
void
*value,
unsigned
int
value_size,
unsigned
long
long
flags);
38
44
void
*bpf_map_lookup_elem(
struct
bpf_map
*map,
void
*key,
unsigned
int
key_size);
45
51
int
bpf_map_delete_elem(
struct
bpf_map
*map,
void
*key,
unsigned
int
key_size);
52
58
int
bpf_map_delete_map(
struct
bpf_map
*map);
59
60
61
#endif
// BACKENDS_EBPF_RUNTIME_EBPF_MAP_H_
UT_hash_handle
Definition
uthash.h:1206
bpf_map
Definition
ebpf_map.h:25
backends
ebpf
runtime
ebpf_map.h
Generated by
1.13.2