From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id F2C09A04AB; Mon, 11 Nov 2019 16:39:33 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 695D32AB; Mon, 11 Nov 2019 16:39:33 +0100 (CET) Received: from inva020.nxp.com (inva020.nxp.com [92.121.34.13]) by dpdk.org (Postfix) with ESMTP id 0150627D; Mon, 11 Nov 2019 16:39:31 +0100 (CET) Received: from inva020.nxp.com (localhost [127.0.0.1]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 6AEF61A014E; Mon, 11 Nov 2019 16:39:31 +0100 (CET) Received: from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com [165.114.16.14]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id D333C1A0006; Mon, 11 Nov 2019 16:39:28 +0100 (CET) Received: from bf-netperf1.ap.freescale.net (bf-netperf1.ap.freescale.net [10.232.133.63]) by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id B8277402C7; Mon, 11 Nov 2019 23:39:24 +0800 (SGT) From: Sachin Saxena To: dev@dpdk.org, ferruh.yigit@intel.com Cc: stable@dpdk.org, thomas@monjalon.net, Sachin Saxena Date: Mon, 11 Nov 2019 21:06:14 +0530 Message-Id: <20191111153614.12079-1-sachin.saxena@nxp.com> X-Mailer: git-send-email 2.17.1 X-Virus-Scanned: ClamAV using ClamSMTP Subject: [dpdk-dev] [PATCH v1] net/dpaa2: fixes issue of accidentally resetting rx offloads flags X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" The JUMBO frame handling in dpaa2_dev_mtu_set api was not correct. When frame_size is greater than RTE_ETHER_MAX_LEN, the intention is to add JUMBO flag in rx offload while it was resetting all other flags other than JUMBO as AND operator was used instead of OR. Fixes: 0ebce6129bc6 ("net/dpaa2: support new ethdev offload APIs") Cc: stable@dpdk.org Signed-off-by: Sachin Saxena Reviewed-by: Gagandeep Singh --- drivers/net/dpaa2/dpaa2_ethdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/dpaa2/dpaa2_ethdev.c b/drivers/net/dpaa2/dpaa2_ethdev.c index 03131b903..6434a223b 100644 --- a/drivers/net/dpaa2/dpaa2_ethdev.c +++ b/drivers/net/dpaa2/dpaa2_ethdev.c @@ -1288,7 +1288,7 @@ dpaa2_dev_mtu_set(struct rte_eth_dev *dev, uint16_t mtu) return -EINVAL; if (frame_size > RTE_ETHER_MAX_LEN) - dev->data->dev_conf.rxmode.offloads &= + dev->data->dev_conf.rxmode.offloads |= DEV_RX_OFFLOAD_JUMBO_FRAME; else dev->data->dev_conf.rxmode.offloads &= -- 2.17.1