]> git.proxmox.com Git - mirror_ovs.git/commit
flow: save "vlan_hdrs" memset for untagged traffic
authorYanqin Wei <Yanqin.Wei@arm.com>
Thu, 22 Aug 2019 10:09:50 +0000 (18:09 +0800)
committerBen Pfaff <blp@ovn.org>
Wed, 28 Aug 2019 21:45:54 +0000 (14:45 -0700)
commitf1dbe3796d332b5e84ac2685187b0f01e2645915
tree5ccf92cdcc2a3a2be4374b5628441de16e6090f9
parentc2c19ddd7c51c4221e9bd72908a0494d3e1e3888
flow: save "vlan_hdrs" memset for untagged traffic

For untagged traffic, it is unnecessary to clear vlan_hdrs as it costs 32B
memset. So the patch improves it by postponing to clear vlan_hdrs until
ethtype check. It can benefit both untagged and single-tagged traffic. From
testing, it does not impact performance of dual-tagged traffic.

Reviewed-by: Gavin Hu <Gavin.Hu@arm.com>
Signed-off-by: Yanqin Wei <Yanqin.Wei@arm.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
lib/flow.c