Lines Matching refs:ip
614 struct net_pkt *ip; in capture_send() local
633 ip = net_pkt_alloc_from_slab(ctx->context->tx_slab(), PKT_ALLOC_TIME); in capture_send()
634 if (!ip) { in capture_send()
638 net_pkt_set_context(ip, ctx->context); in capture_send()
639 net_pkt_set_family(ip, ctx->local.sa_family); in capture_send()
640 net_pkt_set_iface(ip, ctx->tunnel_iface); in capture_send()
642 ret = net_pkt_alloc_buffer(ip, len, IPPROTO_UDP, PKT_ALLOC_TIME); in capture_send()
644 net_pkt_unref(ip); in capture_send()
649 net_pkt_set_ipv4_ttl(ip, in capture_send()
652 ret = net_ipv4_create(ip, &net_sin(&ctx->local)->sin_addr, in capture_send()
655 ret = net_ipv6_create(ip, &net_sin6(&ctx->local)->sin6_addr, in capture_send()
662 net_pkt_unref(ip); in capture_send()
666 (void)net_udp_create(ip, net_sin(&ctx->local)->sin_port, in capture_send()
669 net_buf_frag_add(ip->buffer, pkt->buffer); in capture_send()
670 pkt->buffer = ip->buffer; in capture_send()
671 ip->buffer = NULL; in capture_send()
672 net_pkt_unref(ip); in capture_send()