DPDK
25.11.0
Toggle main menu visibility
Loading...
Searching...
No Matches
rte_pdcp.h
Go to the documentation of this file.
1
/* SPDX-License-Identifier: BSD-3-Clause
2
* Copyright(C) 2023 Marvell.
3
*/
4
5
#ifndef RTE_PDCP_H
6
#define RTE_PDCP_H
7
15
16
#include <rte_compat.h>
17
#include <
rte_common.h
>
18
#include <
rte_mempool.h
>
19
#include <
rte_pdcp_hdr.h
>
20
#include <
rte_security.h
>
21
22
/* Forward declarations. */
23
struct
rte_pdcp_entity
;
24
25
/* PDCP pre-process function based on entity configuration. */
26
typedef
uint16_t (*rte_pdcp_pre_p_t)(
const
struct
rte_pdcp_entity
*entity,
27
struct
rte_mbuf
*mb[],
28
struct
rte_crypto_op
*cop[],
29
uint16_t num, uint16_t *nb_err);
30
31
/* PDCP post-process function based on entity configuration. */
32
typedef
uint16_t (*rte_pdcp_post_p_t)(
const
struct
rte_pdcp_entity
*entity,
33
struct
rte_mbuf
*in_mb[],
34
struct
rte_mbuf
*out_mb[],
35
uint16_t num, uint16_t *nb_err);
36
48
struct
__rte_cache_aligned
rte_pdcp_entity
{
50
rte_pdcp_pre_p_t
pre_process
;
52
rte_pdcp_post_p_t
post_process
;
64
uint32_t
max_pkt_cache
;
65
};
66
80
typedef
void (*
rte_pdcp_t_reordering_start_cb_t
)(
void
*timer,
void
*args);
81
94
typedef
void (*
rte_pdcp_t_reordering_stop_cb_t
)(
void
*timer,
void
*args);
95
101
/* Structure rte_pdcp_t_reordering 8< */
102
struct
rte_pdcp_t_reordering
{
104
void
*
timer
;
106
void
*
args
;
108
rte_pdcp_t_reordering_start_cb_t
start
;
110
rte_pdcp_t_reordering_stop_cb_t
stop
;
111
};
112
/* >8 End of structure rte_pdcp_t_reordering. */
113
117
/* Structure rte_pdcp_entity_conf 8< */
118
struct
rte_pdcp_entity_conf
{
120
struct
rte_security_pdcp_xform
pdcp_xfrm
;
122
struct
rte_crypto_sym_xform
*
crypto_xfrm
;
124
struct
rte_mempool
*
sess_mpool
;
126
struct
rte_mempool
*
cop_pool
;
128
struct
rte_mempool
*
ctrl_pdu_pool
;
134
uint32_t
sn
;
136
bool
is_slrb
;
138
bool
en_sec_offload
;
140
uint8_t
dev_id
;
145
bool
reverse_iv_direction
;
155
bool
status_report_required
;
157
bool
out_of_order_delivery
;
159
struct
rte_pdcp_t_reordering
t_reordering
;
160
};
161
/* >8 End of structure rte_pdcp_entity_conf. */
162
177
__rte_experimental
178
struct
rte_pdcp_entity
*
179
rte_pdcp_entity_establish
(
const
struct
rte_pdcp_entity_conf
*conf);
180
207
__rte_experimental
208
int
209
rte_pdcp_entity_release
(
struct
rte_pdcp_entity
*pdcp_entity,
210
struct
rte_mbuf
*out_mb[]);
211
236
__rte_experimental
237
int
238
rte_pdcp_entity_suspend
(
struct
rte_pdcp_entity
*pdcp_entity,
239
struct
rte_mbuf
*out_mb[]);
240
256
__rte_experimental
257
struct
rte_mbuf
*
258
rte_pdcp_control_pdu_create
(
struct
rte_pdcp_entity
*pdcp_entity,
259
enum
rte_pdcp_ctrl_pdu_type
type);
260
287
__rte_experimental
288
static
inline
uint16_t
289
rte_pdcp_pkt_pre_process
(
const
struct
rte_pdcp_entity
*entity,
290
struct
rte_mbuf
*mb[],
struct
rte_crypto_op
*cop[],
291
uint16_t num, uint16_t *nb_err)
292
{
293
return
entity->
pre_process
(entity, mb, cop, num, nb_err);
294
}
295
328
__rte_experimental
329
static
inline
uint16_t
330
rte_pdcp_pkt_post_process
(
const
struct
rte_pdcp_entity
*entity,
331
struct
rte_mbuf
*in_mb[],
332
struct
rte_mbuf
*out_mb[],
333
uint16_t num, uint16_t *nb_err)
334
{
335
return
entity->
post_process
(entity, in_mb, out_mb, num, nb_err);
336
}
337
361
__rte_experimental
362
uint16_t
363
rte_pdcp_t_reordering_expiry_handle
(
const
struct
rte_pdcp_entity
*entity,
364
struct
rte_mbuf
*out_mb[]);
365
370
#include <
rte_pdcp_group.h
>
371
372
#ifdef __cplusplus
373
extern
"C"
{
374
#endif
375
376
#ifdef __cplusplus
377
}
378
#endif
379
380
#endif
/* RTE_PDCP_H */
rte_common.h
__rte_cache_aligned
#define __rte_cache_aligned
Definition
rte_common.h:739
rte_mempool.h
rte_pdcp_entity_establish
__rte_experimental struct rte_pdcp_entity * rte_pdcp_entity_establish(const struct rte_pdcp_entity_conf *conf)
rte_pdcp_entity_release
__rte_experimental int rte_pdcp_entity_release(struct rte_pdcp_entity *pdcp_entity, struct rte_mbuf *out_mb[])
rte_pdcp_pkt_pre_process
static __rte_experimental uint16_t rte_pdcp_pkt_pre_process(const struct rte_pdcp_entity *entity, struct rte_mbuf *mb[], struct rte_crypto_op *cop[], uint16_t num, uint16_t *nb_err)
Definition
rte_pdcp.h:289
rte_pdcp_entity_suspend
__rte_experimental int rte_pdcp_entity_suspend(struct rte_pdcp_entity *pdcp_entity, struct rte_mbuf *out_mb[])
rte_pdcp_control_pdu_create
__rte_experimental struct rte_mbuf * rte_pdcp_control_pdu_create(struct rte_pdcp_entity *pdcp_entity, enum rte_pdcp_ctrl_pdu_type type)
rte_pdcp_t_reordering_stop_cb_t
void(* rte_pdcp_t_reordering_stop_cb_t)(void *timer, void *args)
Definition
rte_pdcp.h:94
rte_pdcp_pkt_post_process
static __rte_experimental uint16_t rte_pdcp_pkt_post_process(const struct rte_pdcp_entity *entity, struct rte_mbuf *in_mb[], struct rte_mbuf *out_mb[], uint16_t num, uint16_t *nb_err)
Definition
rte_pdcp.h:330
rte_pdcp_t_reordering_start_cb_t
void(* rte_pdcp_t_reordering_start_cb_t)(void *timer, void *args)
Definition
rte_pdcp.h:80
rte_pdcp_t_reordering_expiry_handle
__rte_experimental uint16_t rte_pdcp_t_reordering_expiry_handle(const struct rte_pdcp_entity *entity, struct rte_mbuf *out_mb[])
rte_pdcp_group.h
rte_pdcp_hdr.h
rte_pdcp_ctrl_pdu_type
rte_pdcp_ctrl_pdu_type
Definition
rte_pdcp_hdr.h:37
rte_security.h
rte_crypto_op
Definition
rte_crypto.h:91
rte_crypto_sym_xform
Definition
rte_crypto_sym.h:581
rte_mbuf
Definition
rte_mbuf_core.h:475
rte_mempool
Definition
rte_mempool.h:230
rte_pdcp_entity_conf
Definition
rte_pdcp.h:118
rte_pdcp_entity_conf::dev_id
uint8_t dev_id
Definition
rte_pdcp.h:140
rte_pdcp_entity_conf::out_of_order_delivery
bool out_of_order_delivery
Definition
rte_pdcp.h:157
rte_pdcp_entity_conf::ctrl_pdu_pool
struct rte_mempool * ctrl_pdu_pool
Definition
rte_pdcp.h:128
rte_pdcp_entity_conf::status_report_required
bool status_report_required
Definition
rte_pdcp.h:155
rte_pdcp_entity_conf::sess_mpool
struct rte_mempool * sess_mpool
Definition
rte_pdcp.h:124
rte_pdcp_entity_conf::t_reordering
struct rte_pdcp_t_reordering t_reordering
Definition
rte_pdcp.h:159
rte_pdcp_entity_conf::sn
uint32_t sn
Definition
rte_pdcp.h:134
rte_pdcp_entity_conf::en_sec_offload
bool en_sec_offload
Definition
rte_pdcp.h:138
rte_pdcp_entity_conf::cop_pool
struct rte_mempool * cop_pool
Definition
rte_pdcp.h:126
rte_pdcp_entity_conf::reverse_iv_direction
bool reverse_iv_direction
Definition
rte_pdcp.h:145
rte_pdcp_entity_conf::crypto_xfrm
struct rte_crypto_sym_xform * crypto_xfrm
Definition
rte_pdcp.h:122
rte_pdcp_entity_conf::is_slrb
bool is_slrb
Definition
rte_pdcp.h:136
rte_pdcp_entity_conf::pdcp_xfrm
struct rte_security_pdcp_xform pdcp_xfrm
Definition
rte_pdcp.h:120
rte_pdcp_entity
Definition
rte_pdcp.h:48
rte_pdcp_entity::post_process
rte_pdcp_post_p_t post_process
Definition
rte_pdcp.h:52
rte_pdcp_entity::max_pkt_cache
uint32_t max_pkt_cache
Definition
rte_pdcp.h:64
rte_pdcp_entity::pre_process
rte_pdcp_pre_p_t pre_process
Definition
rte_pdcp.h:50
rte_pdcp_t_reordering
Definition
rte_pdcp.h:102
rte_pdcp_t_reordering::stop
rte_pdcp_t_reordering_stop_cb_t stop
Definition
rte_pdcp.h:110
rte_pdcp_t_reordering::timer
void * timer
Definition
rte_pdcp.h:104
rte_pdcp_t_reordering::args
void * args
Definition
rte_pdcp.h:106
rte_pdcp_t_reordering::start
rte_pdcp_t_reordering_start_cb_t start
Definition
rte_pdcp.h:108
rte_security_pdcp_xform
Definition
rte_security.h:536
lib
pdcp
rte_pdcp.h
Generated by
1.17.0