Lines Matching refs:encap
592 x->encap = kmemdup(nla_data(attrs[XFRMA_ENCAP]), in xfrm_state_construct()
593 sizeof(*x->encap), GFP_KERNEL); in xfrm_state_construct()
594 if (x->encap == NULL) in xfrm_state_construct()
1036 if (x->encap) { in copy_to_user_state_extra()
1037 ret = copy_to_user_encap(x->encap, skb); in copy_to_user_state_extra()
2633 struct xfrm_encap_tmpl *encap = NULL; in xfrm_do_migrate() local
2653 encap = kmemdup(nla_data(attrs[XFRMA_ENCAP]), in xfrm_do_migrate()
2654 sizeof(*encap), GFP_KERNEL); in xfrm_do_migrate()
2655 if (!encap) in xfrm_do_migrate()
2662 err = xfrm_migrate(&pi->sel, pi->dir, type, m, n, kmp, net, encap, if_id); in xfrm_do_migrate()
2664 kfree(encap); in xfrm_do_migrate()
2721 const struct xfrm_encap_tmpl *encap, u8 dir, u8 type) in build_migrate() argument
2743 if (encap) { in build_migrate()
2744 err = nla_put(skb, XFRMA_ENCAP, sizeof(*encap), encap); in build_migrate()
2768 const struct xfrm_encap_tmpl *encap) in xfrm_send_migrate() argument
2774 skb = nlmsg_new(xfrm_migrate_msgsize(num_migrate, !!k, !!encap), in xfrm_send_migrate()
2780 err = build_migrate(skb, m, num_migrate, k, sel, encap, dir, type); in xfrm_send_migrate()
2789 const struct xfrm_encap_tmpl *encap) in xfrm_send_migrate() argument
3105 if (x->encap) in xfrm_sa_len()
3106 l += nla_total_size(sizeof(*x->encap)); in xfrm_sa_len()
3594 um->old_sport = x->encap->encap_sport; in build_mapping()
3611 if (!x->encap) in xfrm_send_mapping()