/openbmc/qemu/net/ |
H A D | tap-bsd.c | 38 int tap_open(char *ifname, int ifname_size, int *vnet_hdr, in tap_open() argument 90 if (*vnet_hdr) { in tap_open() 92 *vnet_hdr = 0; in tap_open() 94 if (vnet_hdr_required && !*vnet_hdr) { in tap_open() 153 int tap_open(char *ifname, int ifname_size, int *vnet_hdr, in tap_open() argument 176 if (*vnet_hdr) { in tap_open() 178 *vnet_hdr = 0; in tap_open() 180 if (vnet_hdr_required && !*vnet_hdr) { in tap_open()
|
H A D | tap.c | 356 int vnet_hdr) in net_tap_fd_init() argument 366 s->host_vnet_hdr_len = vnet_hdr ? sizeof(struct virtio_net_hdr) : 0; in net_tap_fd_init() 376 if (vnet_hdr) { in net_tap_fd_init() 582 int fd, vnet_hdr; in net_init_bridge() local 598 vnet_hdr = tap_probe_vnet_hdr(fd, errp); in net_init_bridge() 599 if (vnet_hdr < 0) { in net_init_bridge() 603 s = net_tap_fd_init(peer, "bridge", name, fd, vnet_hdr); in net_init_bridge() 610 static int net_tap_init(const NetdevTapOptions *tap, int *vnet_hdr, in net_tap_init() argument 618 *vnet_hdr = tap->vnet_hdr; in net_tap_init() 619 vnet_hdr_required = *vnet_hdr; in net_tap_init() [all …]
|
H A D | filter-mirror.c | 43 bool vnet_hdr; member 68 if (s->vnet_hdr) { in _filter_send() 295 net_socket_rs_init(&s->rs, redirector_rs_finalize, s->vnet_hdr); in filter_redirector_setup() 370 return s->vnet_hdr; in filter_mirror_get_vnet_hdr() 377 s->vnet_hdr = value; in filter_mirror_set_vnet_hdr() 401 return s->vnet_hdr; in filter_redirector_get_vnet_hdr() 410 s->vnet_hdr = value; in filter_redirector_set_vnet_hdr() 449 s->vnet_hdr = false; in filter_mirror_init() 456 s->vnet_hdr = false; in filter_redirector_init()
|
H A D | tap-linux.c | 40 int tap_open(char *ifname, int ifname_size, int *vnet_hdr, in tap_open() argument 65 if (*vnet_hdr) { in tap_open() 67 *vnet_hdr = 1; in tap_open() 70 *vnet_hdr = 0; in tap_open() 73 if (vnet_hdr_required && !*vnet_hdr) { in tap_open()
|
H A D | tap-solaris.c | 179 int tap_open(char *ifname, int ifname_size, int *vnet_hdr, in tap_open() argument 190 if (*vnet_hdr) { in tap_open() 192 *vnet_hdr = 0; in tap_open() 194 if (vnet_hdr_required && !*vnet_hdr) { in tap_open()
|
H A D | filter-rewriter.c | 37 bool vnet_hdr; member 269 if (s->vnet_hdr) { in colo_rewriter_receive_iov() 394 return s->vnet_hdr; in filter_rewriter_get_vnet_hdr() 403 s->vnet_hdr = value; in filter_rewriter_set_vnet_hdr() 410 s->vnet_hdr = false; in filter_rewriter_init()
|
H A D | colo-compare.c | 120 bool vnet_hdr; member 742 if (!sendco->notify_remote_frame && s->vnet_hdr) { in _compare_chr_send() 1040 return s->vnet_hdr; in compare_get_vnet_hdr() 1049 s->vnet_hdr = value; in compare_set_vnet_hdr() 1286 net_socket_rs_init(&s->pri_rs, compare_pri_rs_finalize, s->vnet_hdr); in colo_compare_complete() 1287 net_socket_rs_init(&s->sec_rs, compare_sec_rs_finalize, s->vnet_hdr); in colo_compare_complete() 1297 s->vnet_hdr); in colo_compare_complete() 1394 s->vnet_hdr = false; in colo_compare_init()
|
H A D | tap-stub.c | 29 int tap_open(char *ifname, int ifname_size, int *vnet_hdr, in tap_open() argument
|
H A D | tap_int.h | 31 int tap_open(char *ifname, int ifname_size, int *vnet_hdr,
|
H A D | trace-events | 12 colo_proxy_main_vnet_info(const char *sta, uint32_t vnet_hdr, int size) ": %s pkt->vnet_hdr_len = %…
|
H A D | net.c | 799 struct virtio_net_hdr_v1_hash vnet_hdr = { }; in qemu_deliver_packet_iov() local 821 iov_copy[0].iov_base = &vnet_hdr; in qemu_deliver_packet_iov() 2017 bool vnet_hdr) in net_socket_rs_init() argument 2020 rs->vnet_hdr = vnet_hdr; in net_socket_rs_init() 2057 if (rs->vnet_hdr) { in net_fill_rstate()
|
/openbmc/linux/drivers/net/ |
H A D | tap.c | 646 struct virtio_net_hdr vnet_hdr = { 0 }; in tap_get_user() local 663 if (!copy_from_iter_full(&vnet_hdr, sizeof(vnet_hdr), from)) in tap_get_user() 665 iov_iter_advance(from, vnet_hdr_len - sizeof(vnet_hdr)); in tap_get_user() 666 if ((vnet_hdr.flags & VIRTIO_NET_HDR_F_NEEDS_CSUM) && in tap_get_user() 667 tap16_to_cpu(q, vnet_hdr.csum_start) + in tap_get_user() 668 tap16_to_cpu(q, vnet_hdr.csum_offset) + 2 > in tap_get_user() 669 tap16_to_cpu(q, vnet_hdr.hdr_len)) in tap_get_user() 670 vnet_hdr.hdr_len = cpu_to_tap16(q, in tap_get_user() 671 tap16_to_cpu(q, vnet_hdr.csum_start) + in tap_get_user() 672 tap16_to_cpu(q, vnet_hdr.csum_offset) + 2); in tap_get_user() [all …]
|
/openbmc/linux/net/packet/ |
H A D | af_packet.c | 2144 struct virtio_net_hdr_mrg_rxbuf vnet_hdr = { .num_buffers = 0 }; in packet_rcv_vnet() local 2150 if (virtio_net_hdr_from_skb(skb, (struct virtio_net_hdr *)&vnet_hdr, vio_le(), true, 0)) in packet_rcv_vnet() 2153 return memcpy_to_msg(msg, (void *)&vnet_hdr, vnet_hdr_sz); in packet_rcv_vnet() 2589 static int __packet_snd_vnet_parse(struct virtio_net_hdr *vnet_hdr, size_t len) in __packet_snd_vnet_parse() argument 2591 if ((vnet_hdr->flags & VIRTIO_NET_HDR_F_NEEDS_CSUM) && in __packet_snd_vnet_parse() 2592 (__virtio16_to_cpu(vio_le(), vnet_hdr->csum_start) + in __packet_snd_vnet_parse() 2593 __virtio16_to_cpu(vio_le(), vnet_hdr->csum_offset) + 2 > in __packet_snd_vnet_parse() 2594 __virtio16_to_cpu(vio_le(), vnet_hdr->hdr_len))) in __packet_snd_vnet_parse() 2595 vnet_hdr->hdr_len = __cpu_to_virtio16(vio_le(), in __packet_snd_vnet_parse() 2596 __virtio16_to_cpu(vio_le(), vnet_hdr->csum_start) + in __packet_snd_vnet_parse() [all …]
|
/openbmc/qemu/include/net/ |
H A D | net.h | 132 bool vnet_hdr; member 261 bool vnet_hdr);
|
/openbmc/qemu/qapi/ |
H A D | net.json | 225 # @vnet_hdr: enable the IFF_VNET_HDR flag on the tap interface 253 '*vnet_hdr': 'bool',
|
/openbmc/qemu/ |
H A D | qemu-options.hx | 2770 " [,br=bridge][,helper=helper][,sndbuf=nbytes][,vnet_hdr=on|off][,vhost=on|off]\n" 2785 " use vnet_hdr=off to avoid enabling the IFF_VNET_HDR tap flag\n" 2786 " use vnet_hdr=on to make the lack of IFF_VNET_HDR support an error condition\n"
|