From patchwork Mon Aug 31 07:53:33 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nipun Gupta X-Patchwork-Id: 248733 Delivered-To: patch@linaro.org Received: by 2002:a92:5b9c:0:0:0:0:0 with SMTP id c28csp3110438ilg; Mon, 31 Aug 2020 00:59:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJys+E+OZggxkwiZYcb2jqQ82EyyOx7H2HSF3BtlRkOHexvYtK1AO6b4oNNIi2gn0wJ60Wtn X-Received: by 2002:a50:a2e6:: with SMTP id 93mr69258edm.147.1598860782863; Mon, 31 Aug 2020 00:59:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598860782; cv=none; d=google.com; s=arc-20160816; b=rp7YjCgicTQDzSva0nascZ+RPDpGOCyV2Ec7davmlusYixZCxhSPYXXVYZY9xov2aJ p7fyB5V9Gx+hNMMd8p9gzVrUDScDHcJaJK+udLtgjCWTtHryHPXDlVwfKPmb1coOAC7w FCpdQQh4HtMa1dolwNJmNr15FmZwESk3YlTTkG86UwMn463G4iZZeB6rUtZB/98gI3hO h79pFrDc9kHthzBIbC7cEZChWJJcEoXnkmsz+Fuhw+YkNygqFLeMhsf0Y4ZLQ+uPVd9r 53Y2bnCEsH8MH5zNi81Se/pDCOEjmP/ZzeISHlTjSvATp7RWDsD5HMXeGEGKPrcIZUvA ArGA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:message-id:date:cc:to :from; bh=aP0EP20/nvntrYu9xdzyaul9A0mrXmPkShlTANOAqSY=; b=DZHJ2Deo44EDz0HI3owPQUWwQCPaEZc6C7e3TXG/ECgC04+GMuZac/rIUG7Fu+Vdxb yLZHfgcJKi9VpVMPcDNB4U+rgiCpz2v04AFX4/yQUWusTV8ojivTfAZwqFGQjp2WBICi ch4inuIPCwLWTQh7dXlKLdfXgcdSAl/TcXsDyZ12liSMIYG3mpN8SBmla3ENcNDxurot xIoaKISEhS9M4iRjYEgZRCJeh0rFSZainCzV6os0ywE4e7ZnNjhdyxhfO3Co9wM40Wnu BkKcuABlx44KArm3AaeTXTYJeGsQ3/WnjKyW1kObOadLlEoNZazSNuVdHg0WLm3Z5rbx Hdqw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from dpdk.org (dpdk.org. [92.243.14.124]) by mx.google.com with ESMTP id s7si4913122edq.278.2020.08.31.00.59.42; Mon, 31 Aug 2020 00:59:42 -0700 (PDT) Received-SPF: pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) client-ip=92.243.14.124; Authentication-Results: mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8A7481DBD; Mon, 31 Aug 2020 09:59:41 +0200 (CEST) Received: from inva020.nxp.com (inva020.nxp.com [92.121.34.13]) by dpdk.org (Postfix) with ESMTP id 0CDBEDE0 for ; Mon, 31 Aug 2020 09:59:41 +0200 (CEST) Received: from inva020.nxp.com (localhost [127.0.0.1]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id BF42A1A02D0; Mon, 31 Aug 2020 09:59:40 +0200 (CEST) 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 B4E9B1A0867; Mon, 31 Aug 2020 09:59:37 +0200 (CEST) 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 4E4B2402B0; Mon, 31 Aug 2020 09:59:33 +0200 (CEST) From: Nipun Gupta To: dev@dpdk.org Cc: thomas@monjalon.net, ferruh.yigit@intel.com, arybchenko@solarflare.com, hemant.agrawal@nxp.com, Nipun Gupta , Rohit Raj Date: Mon, 31 Aug 2020 13:23:33 +0530 Message-Id: <20200831075333.10135-1-nipun.gupta@nxp.com> X-Mailer: git-send-email 2.17.1 X-Virus-Scanned: ClamAV using ClamSMTP Subject: [dpdk-dev] [PATCH] ethdev: add rx offload to drop error packets 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" This change adds a RX offload capability where hardware can drop the packets in case there is an error in the packet such as L3 checksum error or L4 checksum. Signed-off-by: Nipun Gupta Signed-off-by: Rohit Raj --- lib/librte_ethdev/rte_ethdev.h | 1 + 1 file changed, 1 insertion(+) -- 2.17.1 diff --git a/lib/librte_ethdev/rte_ethdev.h b/lib/librte_ethdev/rte_ethdev.h index a49242bcd..bb9df2fb9 100644 --- a/lib/librte_ethdev/rte_ethdev.h +++ b/lib/librte_ethdev/rte_ethdev.h @@ -1120,6 +1120,7 @@ struct rte_eth_conf { #define DEV_RX_OFFLOAD_SCTP_CKSUM 0x00020000 #define DEV_RX_OFFLOAD_OUTER_UDP_CKSUM 0x00040000 #define DEV_RX_OFFLOAD_RSS_HASH 0x00080000 +#define DEV_RX_OFFLOAD_ERR_PKT_DROP 0x00100000 #define DEV_RX_OFFLOAD_CHECKSUM (DEV_RX_OFFLOAD_IPV4_CKSUM | \ DEV_RX_OFFLOAD_UDP_CKSUM | \