Lines Matching refs:vnet_hdr
1101 struct virtio_net_hdr vnet_hdr = { 0 };
1139 vnet_hdr_len = sizeof(vnet_hdr);
1147 err = memcpy_fromiovec((void *)&vnet_hdr, msg->msg_iov,
1152 if ((vnet_hdr.flags & VIRTIO_NET_HDR_F_NEEDS_CSUM) &&
1153 (vnet_hdr.csum_start + vnet_hdr.csum_offset + 2 >
1154 vnet_hdr.hdr_len))
1155 vnet_hdr.hdr_len = vnet_hdr.csum_start +
1156 vnet_hdr.csum_offset + 2;
1159 if (vnet_hdr.hdr_len > len)
1162 if (vnet_hdr.gso_type != VIRTIO_NET_HDR_GSO_NONE) {
1163 switch (vnet_hdr.gso_type & ~VIRTIO_NET_HDR_GSO_ECN) {
1177 if (vnet_hdr.gso_type & VIRTIO_NET_HDR_GSO_ECN)
1180 if (vnet_hdr.gso_size == 0)
1192 LL_RESERVED_SPACE(dev), len, vnet_hdr.hdr_len,
1218 if (vnet_hdr.flags & VIRTIO_NET_HDR_F_NEEDS_CSUM) {
1219 if (!skb_partial_csum_set(skb, vnet_hdr.csum_start,
1220 vnet_hdr.csum_offset)) {
1226 skb_shinfo(skb)->gso_size = vnet_hdr.gso_size;
1600 struct virtio_net_hdr vnet_hdr = { 0 };
1603 vnet_hdr_len = sizeof(vnet_hdr);
1613 vnet_hdr.hdr_len = skb_headlen(skb);
1614 vnet_hdr.gso_size = sinfo->gso_size;
1616 vnet_hdr.gso_type = VIRTIO_NET_HDR_GSO_TCPV4;
1618 vnet_hdr.gso_type = VIRTIO_NET_HDR_GSO_TCPV6;
1620 vnet_hdr.gso_type = VIRTIO_NET_HDR_GSO_UDP;
1626 vnet_hdr.gso_type |= VIRTIO_NET_HDR_GSO_ECN;
1628 vnet_hdr.gso_type = VIRTIO_NET_HDR_GSO_NONE;
1631 vnet_hdr.flags = VIRTIO_NET_HDR_F_NEEDS_CSUM;
1632 vnet_hdr.csum_start = skb->csum_start -
1634 vnet_hdr.csum_offset = skb->csum_offset;
1637 err = memcpy_toiovec(msg->msg_iov, (void *)&vnet_hdr,