MCPcopy Create free account
hub / github.com/F-Stack/f-stack / pdcp_crypto_xfrm_get

Function pdcp_crypto_xfrm_get

dpdk/lib/pdcp/pdcp_process.c:193–214  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

191}
192
193static int
194pdcp_crypto_xfrm_get(const struct rte_pdcp_entity_conf *conf, struct rte_crypto_sym_xform **c_xfrm,
195 struct rte_crypto_sym_xform **a_xfrm)
196{
197 *c_xfrm = NULL;
198 *a_xfrm = NULL;
199
200 if (conf->crypto_xfrm == NULL)
201 return -EINVAL;
202
203 if (conf->crypto_xfrm->type == RTE_CRYPTO_SYM_XFORM_CIPHER) {
204 *c_xfrm = conf->crypto_xfrm;
205 *a_xfrm = conf->crypto_xfrm->next;
206 } else if (conf->crypto_xfrm->type == RTE_CRYPTO_SYM_XFORM_AUTH) {
207 *a_xfrm = conf->crypto_xfrm;
208 *c_xfrm = conf->crypto_xfrm->next;
209 } else {
210 return -EINVAL;
211 }
212
213 return 0;
214}
215
216static int
217pdcp_iv_gen_func_set(struct rte_pdcp_entity *entity, const struct rte_pdcp_entity_conf *conf)

Callers 2

pdcp_iv_gen_func_setFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected