Skip to content

Commit

Permalink
netdev-dpdk: Stop relying on vhost-user Tx flags.
Browse files Browse the repository at this point in the history
vhost-user legacy behavior has been to mark mbuf with Tx offload flags
based on what the virtio-net header contained (but provide no
Rx information, like IP checksum or L4 checksum validity).

OVS current implementation was relying on this behavior so far,
though this clashed in some corner cases, like when a guest sends a
tunneled packet requesting outer udp checksum offload
(in such a case, the packet is marked as requesting UDP checksum).

Changing to the non legacy mode means that it is now OVS responsibility
to set Tx ol_flags (which should be the case already in
miniflow_extract()).

Signed-off-by: David Marchand <[email protected]>
  • Loading branch information
david-marchand committed Feb 13, 2025
1 parent 37ad9c9 commit 0c9e250
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/netdev-dpdk.c
Original file line number Diff line number Diff line change
Expand Up @@ -6387,6 +6387,11 @@ netdev_dpdk_vhost_client_reconfigure(struct netdev *netdev)
vhost_flags |= RTE_VHOST_USER_POSTCOPY_SUPPORT;
}

/* Prefer that the vhost library provides Rx ol_flags, rather than let
* it mark the packet with Tx ol_flags (which may collide with OVS Tx
* offloads decisions). */
vhost_flags |= RTE_VHOST_USER_NET_COMPLIANT_OL_FLAGS;

/* Enable External Buffers if TCP Segmentation Offload is enabled. */
if (enable_tso) {
vhost_flags |= RTE_VHOST_USER_EXTBUF_SUPPORT;
Expand Down

0 comments on commit 0c9e250

Please sign in to comment.