packet-dpif: Add dpif_packet_{get, set}_hash()
authorDaniele Di Proietto <ddiproietto@vmware.com>
Fri, 29 Aug 2014 23:06:42 +0000 (16:06 -0700)
committerPravin B Shelar <pshelar@nicira.com>
Fri, 29 Aug 2014 23:32:21 +0000 (16:32 -0700)
commit61a2647e155c835e946407aa365c4d2adb5b57d5
treecc1bd308ae1e6d36fde54325cfe14df08e49b56f
parent9230662a879921f3f35905d0f978db201323e5c6
packet-dpif: Add dpif_packet_{get, set}_hash()

These function are used to stored the packet hash. 'netdev-dpdk'
automatically set this value to the RSS hash returned by the
NIC. Other 'netdev's set it to 0 (which is an invalid hash
value), so that callers can compute the hash on their own.

If DPDK support is enabled, struct dpif_packet's member
'dp_hash' is removed and 'pkt.hash.rss' from DPDK mbuf is used

This commit also configure DPDK devices to compute RSS hash
for UDP and IPv6 packets

Signed-off-by: Daniele Di Proietto <ddiproietto@vmware.com>
Acked-by: Pravin B Shelar <pshelar@nicira.com>
lib/dpif-netdev.c
lib/netdev-bsd.c
lib/netdev-dpdk.c
lib/netdev-dummy.c
lib/netdev-linux.c
lib/odp-execute.c
lib/packet-dpif.c
lib/packet-dpif.h