When building with DPDK support, 'struct dpif_packet' won't have 'dp_hash'
member. dpif_packet_set_dp_hash() and dpif_packet_get_dp_hash() should be used.
Furthermore, the masked set action shouldn't read 'md->dp_hash' (which is
shared in a batch), but should use dpif_packet_get_dp_hash() to get each packet
private hash.
This commit fixes the build with DPDK.
Signed-off-by: Daniele Di Proietto <ddiproietto@vmware.com>
Acked-by: Jarno Rajahalme <jrajahalme@nicira.com>
break;
case OVS_KEY_ATTR_DP_HASH:
- packet->dp_hash = md->dp_hash = nl_attr_get_u32(a)
- | (md->dp_hash & ~*get_mask(a, uint32_t));
+ md->dp_hash = nl_attr_get_u32(a)
+ | (dpif_packet_get_dp_hash(packet) & ~*get_mask(a, uint32_t));
+ dpif_packet_set_dp_hash(packet, md->dp_hash);
break;
case OVS_KEY_ATTR_RECIRC_ID: