On Mon, Aug 31, 2026 at 11:20 AM Tim Rozet via dev <[email protected]>
wrote:

> The userspace implementation of OVS_HASH_ALG_SYM_L4 calls
> flow_hash_symmetric_l3l4() with UDP port hashing disabled. As a
> result, UDP packets with identical addresses but different ports
> receive the same datapath hash.
>
> The Linux datapath implements this algorithm with
> __skb_get_hash_symmetric(). Its symmetric flow dissector requests
> FLOW_DISSECTOR_KEY_PORTS, and skb_flow_get_ports() extracts source
> and destination ports for IPPROTO_UDP. Thus, the two datapaths use
> different hash fields for the same OVS action.
>
> Include UDP ports in the userspace algorithm to align its field
> selection with Linux. The exact hash value remains datapath-specific
> and opaque to ovs-vswitchd.
>
> Add dummy-datapath coverage that verifies reversed UDP tuples remain
> symmetric while changing only the UDP source port produces more than
> one datapath hash.
>
> Tested with GitHub Actions and an HBN/OVN integration topology. The
> userspace datapath distributed 128 VXLAN flows across two underlay
> ECMP paths and moved all traffic to the remaining path after failover.
>
> Fixes: 6a0b0d3be857 ("userspace datapath: Add OVS_HASH_L4_SYMMETRIC
> dp_hash algorithm")
> Assisted-by: GPT-5, OpenAI Codex
> Signed-off-by: Tim Rozet <[email protected]>
> ---


Looks good to me.

Acked-by: Mike Pattrick <[email protected]>
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to