Lines Matching refs:uctx

466 	struct xfrm_user_sec_ctx *uctx = NULL;  in pfkey_sadb2xfrm_user_sec_ctx()  local
469 uctx = kmalloc((sizeof(*uctx)+ctx_size), gfp); in pfkey_sadb2xfrm_user_sec_ctx()
471 if (!uctx) in pfkey_sadb2xfrm_user_sec_ctx()
474 uctx->len = pfkey_sec_ctx_len(sec_ctx); in pfkey_sadb2xfrm_user_sec_ctx()
475 uctx->exttype = sec_ctx->sadb_x_sec_exttype; in pfkey_sadb2xfrm_user_sec_ctx()
476 uctx->ctx_doi = sec_ctx->sadb_x_ctx_doi; in pfkey_sadb2xfrm_user_sec_ctx()
477 uctx->ctx_alg = sec_ctx->sadb_x_ctx_alg; in pfkey_sadb2xfrm_user_sec_ctx()
478 uctx->ctx_len = sec_ctx->sadb_x_ctx_len; in pfkey_sadb2xfrm_user_sec_ctx()
479 memcpy(uctx + 1, sec_ctx + 1, in pfkey_sadb2xfrm_user_sec_ctx()
480 uctx->ctx_len); in pfkey_sadb2xfrm_user_sec_ctx()
482 return uctx; in pfkey_sadb2xfrm_user_sec_ctx()
1154 struct xfrm_user_sec_ctx *uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_KERNEL); in pfkey_msg2xfrm_state() local
1156 if (!uctx) in pfkey_msg2xfrm_state()
1159 err = security_xfrm_state_alloc(x, uctx); in pfkey_msg2xfrm_state()
1160 kfree(uctx); in pfkey_msg2xfrm_state()
2293 struct xfrm_user_sec_ctx *uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_KERNEL); in pfkey_spdadd() local
2295 if (!uctx) { in pfkey_spdadd()
2300 err = security_xfrm_policy_alloc(&xp->security, uctx, GFP_KERNEL); in pfkey_spdadd()
2301 kfree(uctx); in pfkey_spdadd()
2395 struct xfrm_user_sec_ctx *uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_KERNEL); in pfkey_spddelete() local
2397 if (!uctx) in pfkey_spddelete()
2400 err = security_xfrm_policy_alloc(&pol_ctx, uctx, GFP_KERNEL); in pfkey_spddelete()
2401 kfree(uctx); in pfkey_spddelete()
3303 struct xfrm_user_sec_ctx *uctx; in pfkey_compile_policy() local
3314 uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_ATOMIC); in pfkey_compile_policy()
3315 *dir = security_xfrm_policy_alloc(&xp->security, uctx, GFP_ATOMIC); in pfkey_compile_policy()
3316 kfree(uctx); in pfkey_compile_policy()