net/mlx5: optimize Rx hash fields conversion
authorDekel Peled <dekelp@mellanox.com>
Wed, 15 Jan 2020 21:19:39 +0000 (23:19 +0200)
committerFerruh Yigit <ferruh.yigit@intel.com>
Mon, 20 Jan 2020 17:02:17 +0000 (18:02 +0100)
commit70ccb6056847a87bba374d703f51705344982eec
treee46df74c43a5e5dea94ff2b9f07484f567ace931
parent89ef76db3b7627d4a7e656c7e51807b5bf8bdedc
net/mlx5: optimize Rx hash fields conversion

Previous fix added translation of Rx hash fields to PRM format.

This patch optimizes the fix, to perform value translation only
if value is not zero.
In case value is zero, there is no need to translate it.

Fixes: c3e33304a7f6 ("net/mlx5: fix setting of Rx hash fields")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
drivers/net/mlx5/mlx5_rxq.c