DPDK
22.11.7
Toggle main menu visibility
Main Page
Related Pages
Data Structures
Data Structures
Data Fields
All
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
Variables
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Files
File List
Globals
All
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
Functions
_
c
g
r
Variables
a
c
d
e
l
r
s
Typedefs
a
c
d
e
h
l
m
p
r
s
t
Enumerations
d
r
Enumerator
c
e
f
r
s
w
Macros
_
b
c
i
l
m
o
p
r
s
t
u
v
Examples
•
All
Data Structures
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Pages
lib
net
rte_gtp.h
Go to the documentation of this file.
1
/* SPDX-License-Identifier: BSD-3-Clause
2
* Copyright(c) 1982, 1986, 1990, 1993
3
* The Regents of the University of California.
4
* Copyright(c) 2010-2014 Intel Corporation.
5
* All rights reserved.
6
*/
7
8
#ifndef _RTE_GTP_H_
9
#define _RTE_GTP_H_
10
17
#include <stdint.h>
18
#include <
rte_byteorder.h
>
19
20
#ifdef __cplusplus
21
extern
"C"
{
22
#endif
23
30
__extension__
31
struct
rte_gtp_hdr
{
32
union
{
33
uint8_t
gtp_hdr_info
;
34
struct
{
35
#if RTE_BYTE_ORDER == RTE_LITTLE_ENDIAN
36
uint8_t
pn
:1;
37
uint8_t
s
:1;
38
uint8_t
e
:1;
39
uint8_t
res1
:1;
40
uint8_t
pt
:1;
41
uint8_t
ver
:3;
42
#elif RTE_BYTE_ORDER == RTE_BIG_ENDIAN
43
uint8_t
ver
:3;
44
uint8_t
pt
:1;
45
uint8_t
res1
:1;
46
uint8_t
e
:1;
47
uint8_t
s
:1;
48
uint8_t
pn
:1;
49
#endif
50
};
51
};
52
uint8_t
msg_type
;
53
rte_be16_t
plen
;
54
rte_be32_t
teid
;
55
}
__rte_packed
;
56
57
/* Optional word of GTP header, present if any of E, S, PN is set. */
58
struct
rte_gtp_hdr_ext_word {
59
rte_be16_t
sqn;
60
uint8_t npdu;
61
uint8_t next_ext;
62
}
__rte_packed
;
63
68
__extension__
69
struct
rte_gtp_psc_generic_hdr
{
70
uint8_t
ext_hdr_len
;
71
#if RTE_BYTE_ORDER == RTE_BIG_ENDIAN
72
uint8_t
type
:4;
73
uint8_t
qmp
:1;
74
uint8_t
pad
:3;
75
uint8_t
spare
:2;
76
uint8_t
qfi
:6;
77
#else
78
uint8_t
pad
:3;
79
uint8_t
qmp
:1;
80
uint8_t
type
:4;
81
uint8_t
qfi
:6;
82
uint8_t
spare
:2;
83
#endif
84
uint8_t
data
[0];
85
}
__rte_packed
;
86
91
__extension__
92
struct
rte_gtp_psc_type0_hdr
{
93
uint8_t
ext_hdr_len
;
94
#if RTE_BYTE_ORDER == RTE_BIG_ENDIAN
95
uint8_t
type
:4;
96
uint8_t
qmp
:1;
97
uint8_t
snp
:1;
98
uint8_t
spare_dl1
:2;
99
uint8_t
ppp
:1;
100
uint8_t
rqi
:1;
101
uint8_t
qfi
:6;
102
#else
103
uint8_t
spare_dl1
:2;
104
uint8_t
snp
:1;
105
uint8_t
qmp
:1;
106
uint8_t
type
:4;
107
uint8_t
qfi
:6;
108
uint8_t
rqi
:1;
109
uint8_t
ppp
:1;
110
#endif
111
uint8_t
data
[0];
112
}
__rte_packed
;
113
118
__extension__
119
struct
rte_gtp_psc_type1_hdr
{
120
uint8_t
ext_hdr_len
;
121
#if RTE_BYTE_ORDER == RTE_BIG_ENDIAN
122
uint8_t
type
:4;
123
uint8_t
qmp
:1;
124
uint8_t
dl_delay_ind
:1;
125
uint8_t
ul_delay_ind
:1;
126
uint8_t
snp
:1;
127
uint8_t
n_delay_ind
:1;
128
uint8_t
spare_ul2
:1;
129
uint8_t
qfi
:6;
130
#else
131
uint8_t
snp
:1;
132
uint8_t
ul_delay_ind
:1;
133
uint8_t
dl_delay_ind
:1;
134
uint8_t
qmp
:1;
135
uint8_t
type
:4;
136
uint8_t
qfi
:6;
137
uint8_t
spare_ul2
:1;
138
uint8_t
n_delay_ind
:1;
139
#endif
140
uint8_t
data
[0];
141
}
__rte_packed
;
142
144
#define RTE_ETHER_GTP_HLEN \
145
(sizeof(struct rte_udp_hdr) + sizeof(struct rte_gtp_hdr))
146
/* GTP next protocol type */
147
#define RTE_GTP_TYPE_IPV4 0x40
148
#define RTE_GTP_TYPE_IPV6 0x60
149
/* GTP destination port number */
150
#define RTE_GTPC_UDP_PORT 2123
151
#define RTE_GTPU_UDP_PORT 2152
153
#ifdef __cplusplus
154
}
155
#endif
156
157
#endif
/* RTE_GTP_H_ */
rte_byteorder.h
rte_be32_t
uint32_t rte_be32_t
Definition:
rte_byteorder.h:111
rte_be16_t
uint16_t rte_be16_t
Definition:
rte_byteorder.h:110
__rte_packed
#define __rte_packed
Definition:
rte_common.h:83
rte_gtp_hdr
Definition:
rte_gtp.h:31
rte_gtp_hdr::gtp_hdr_info
uint8_t gtp_hdr_info
Definition:
rte_gtp.h:33
rte_gtp_hdr::plen
rte_be16_t plen
Definition:
rte_gtp.h:53
rte_gtp_hdr::pt
uint8_t pt
Definition:
rte_gtp.h:40
rte_gtp_hdr::s
uint8_t s
Definition:
rte_gtp.h:37
rte_gtp_hdr::e
uint8_t e
Definition:
rte_gtp.h:38
rte_gtp_hdr::teid
rte_be32_t teid
Definition:
rte_gtp.h:54
rte_gtp_hdr::res1
uint8_t res1
Definition:
rte_gtp.h:39
rte_gtp_hdr::ver
uint8_t ver
Definition:
rte_gtp.h:41
rte_gtp_hdr::pn
uint8_t pn
Definition:
rte_gtp.h:36
rte_gtp_hdr::msg_type
uint8_t msg_type
Definition:
rte_gtp.h:52
rte_gtp_psc_generic_hdr
Definition:
rte_gtp.h:69
rte_gtp_psc_generic_hdr::qmp
uint8_t qmp
Definition:
rte_gtp.h:73
rte_gtp_psc_generic_hdr::type
uint8_t type
Definition:
rte_gtp.h:72
rte_gtp_psc_generic_hdr::spare
uint8_t spare
Definition:
rte_gtp.h:75
rte_gtp_psc_generic_hdr::qfi
uint8_t qfi
Definition:
rte_gtp.h:76
rte_gtp_psc_generic_hdr::ext_hdr_len
uint8_t ext_hdr_len
Definition:
rte_gtp.h:70
rte_gtp_psc_generic_hdr::pad
uint8_t pad
Definition:
rte_gtp.h:74
rte_gtp_psc_generic_hdr::data
uint8_t data[0]
Definition:
rte_gtp.h:84
rte_gtp_psc_type0_hdr
Definition:
rte_gtp.h:92
rte_gtp_psc_type0_hdr::qmp
uint8_t qmp
Definition:
rte_gtp.h:96
rte_gtp_psc_type0_hdr::type
uint8_t type
Definition:
rte_gtp.h:95
rte_gtp_psc_type0_hdr::rqi
uint8_t rqi
Definition:
rte_gtp.h:100
rte_gtp_psc_type0_hdr::qfi
uint8_t qfi
Definition:
rte_gtp.h:101
rte_gtp_psc_type0_hdr::spare_dl1
uint8_t spare_dl1
Definition:
rte_gtp.h:98
rte_gtp_psc_type0_hdr::ext_hdr_len
uint8_t ext_hdr_len
Definition:
rte_gtp.h:93
rte_gtp_psc_type0_hdr::snp
uint8_t snp
Definition:
rte_gtp.h:97
rte_gtp_psc_type0_hdr::data
uint8_t data[0]
Definition:
rte_gtp.h:111
rte_gtp_psc_type0_hdr::ppp
uint8_t ppp
Definition:
rte_gtp.h:99
rte_gtp_psc_type1_hdr
Definition:
rte_gtp.h:119
rte_gtp_psc_type1_hdr::qmp
uint8_t qmp
Definition:
rte_gtp.h:123
rte_gtp_psc_type1_hdr::ul_delay_ind
uint8_t ul_delay_ind
Definition:
rte_gtp.h:125
rte_gtp_psc_type1_hdr::n_delay_ind
uint8_t n_delay_ind
Definition:
rte_gtp.h:127
rte_gtp_psc_type1_hdr::type
uint8_t type
Definition:
rte_gtp.h:122
rte_gtp_psc_type1_hdr::qfi
uint8_t qfi
Definition:
rte_gtp.h:129
rte_gtp_psc_type1_hdr::ext_hdr_len
uint8_t ext_hdr_len
Definition:
rte_gtp.h:120
rte_gtp_psc_type1_hdr::spare_ul2
uint8_t spare_ul2
Definition:
rte_gtp.h:128
rte_gtp_psc_type1_hdr::dl_delay_ind
uint8_t dl_delay_ind
Definition:
rte_gtp.h:124
rte_gtp_psc_type1_hdr::snp
uint8_t snp
Definition:
rte_gtp.h:126
rte_gtp_psc_type1_hdr::data
uint8_t data[0]
Definition:
rte_gtp.h:140
Generated by
1.9.4