[dpdk-dev] net/ena: use correct field for Rx offload features

Message ID 1483538334-9714-1-git-send-email-jpa@semihalf.com (mailing list archive)
State Accepted, archived
Delegated to: Ferruh Yigit
Headers

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel compilation success Compilation OK

Commit Message

Jakub Palider Jan. 4, 2017, 1:58 p.m. UTC
  Previously the capability bitmap for Rx offloads was mistakenly taken
from Tx capability bitmap field. This patch fixes the problem.

Signed-off-by: Jakub Palider <jpa@semihalf.com>
---
 drivers/net/ena/ena_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Ferruh Yigit Jan. 4, 2017, 2:27 p.m. UTC | #1
On 1/4/2017 1:58 PM, Jakub Palider wrote:
> Previously the capability bitmap for Rx offloads was mistakenly taken
> from Tx capability bitmap field. This patch fixes the problem.
> 
> Signed-off-by: Jakub Palider <jpa@semihalf.com>

Applied to dpdk-next-net/master, thanks.
  

Patch

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index dcee8ed..34e5577 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -1466,7 +1466,7 @@  static void ena_infos_get(struct rte_eth_dev *dev,
 			DEV_TX_OFFLOAD_UDP_CKSUM |
 			DEV_TX_OFFLOAD_TCP_CKSUM;
 
-	if (feat.offload.tx &
+	if (feat.offload.rx_supported &
 	    ENA_ADMIN_FEATURE_OFFLOAD_DESC_RX_L4_IPV4_CSUM_MASK)
 		rx_feat |= DEV_RX_OFFLOAD_IPV4_CKSUM |
 			DEV_RX_OFFLOAD_UDP_CKSUM  |