Lines Matching refs:uctx

484 	struct xfrm_user_sec_ctx *uctx = NULL;  in pfkey_sadb2xfrm_user_sec_ctx()  local
487 uctx = kmalloc((sizeof(*uctx)+ctx_size), gfp); in pfkey_sadb2xfrm_user_sec_ctx()
489 if (!uctx) in pfkey_sadb2xfrm_user_sec_ctx()
492 uctx->len = pfkey_sec_ctx_len(sec_ctx); in pfkey_sadb2xfrm_user_sec_ctx()
493 uctx->exttype = sec_ctx->sadb_x_sec_exttype; in pfkey_sadb2xfrm_user_sec_ctx()
494 uctx->ctx_doi = sec_ctx->sadb_x_ctx_doi; in pfkey_sadb2xfrm_user_sec_ctx()
495 uctx->ctx_alg = sec_ctx->sadb_x_ctx_alg; in pfkey_sadb2xfrm_user_sec_ctx()
496 uctx->ctx_len = sec_ctx->sadb_x_ctx_len; in pfkey_sadb2xfrm_user_sec_ctx()
497 memcpy(uctx + 1, sec_ctx + 1, in pfkey_sadb2xfrm_user_sec_ctx()
498 uctx->ctx_len); in pfkey_sadb2xfrm_user_sec_ctx()
500 return uctx; in pfkey_sadb2xfrm_user_sec_ctx()
1174 struct xfrm_user_sec_ctx *uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_KERNEL); in pfkey_msg2xfrm_state() local
1176 if (!uctx) in pfkey_msg2xfrm_state()
1179 err = security_xfrm_state_alloc(x, uctx); in pfkey_msg2xfrm_state()
1180 kfree(uctx); in pfkey_msg2xfrm_state()
2304 struct xfrm_user_sec_ctx *uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_KERNEL); in pfkey_spdadd() local
2306 if (!uctx) { in pfkey_spdadd()
2311 err = security_xfrm_policy_alloc(&xp->security, uctx, GFP_KERNEL); in pfkey_spdadd()
2312 kfree(uctx); in pfkey_spdadd()
2406 struct xfrm_user_sec_ctx *uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_KERNEL); in pfkey_spddelete() local
2408 if (!uctx) in pfkey_spddelete()
2411 err = security_xfrm_policy_alloc(&pol_ctx, uctx, GFP_KERNEL); in pfkey_spddelete()
2412 kfree(uctx); in pfkey_spddelete()
3310 struct xfrm_user_sec_ctx *uctx; in pfkey_compile_policy() local
3321 uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_ATOMIC); in pfkey_compile_policy()
3322 *dir = security_xfrm_policy_alloc(&xp->security, uctx, GFP_ATOMIC); in pfkey_compile_policy()
3323 kfree(uctx); in pfkey_compile_policy()