Skip to content

Commit 501db51

Browse files
rndavem330
authored andcommitted
virtio: don't set VIRTIO_NET_HDR_F_DATA_VALID on xmit
This patch part reverts fd2a043 and e858fae which introduced a subtle change in how the virtio_net flags are derived from the SKBs ip_summed field. With the above commits, the flags are set to VIRTIO_NET_HDR_F_DATA_VALID when ip_summed == CHECKSUM_UNNECESSARY, thus treating it differently to ip_summed == CHECKSUM_NONE, which should be the same. Further, the virtio spec 1.0 / CS04 explicitly says that VIRTIO_NET_HDR_F_DATA_VALID must not be set by the driver. Fixes: fd2a043 ("virtio_net: introduce virtio_net_hdr_{from,to}_skb") Fixes: e858fae (" virtio_net: use common code for virtio_net_hdr and skb GSO conversion") Signed-off-by: Rolf Neugebauer <[email protected]> Acked-by: Michael S. Tsirkin <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 4b19a9e commit 501db51

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

include/linux/virtio_net.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,6 @@ static inline int virtio_net_hdr_from_skb(const struct sk_buff *skb,
9191
skb_checksum_start_offset(skb));
9292
hdr->csum_offset = __cpu_to_virtio16(little_endian,
9393
skb->csum_offset);
94-
} else if (skb->ip_summed == CHECKSUM_UNNECESSARY) {
95-
hdr->flags = VIRTIO_NET_HDR_F_DATA_VALID;
9694
} /* else everything is zero */
9795

9896
return 0;

0 commit comments

Comments
 (0)