From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id D9455A0C47; Thu, 19 Aug 2021 11:03:01 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6BA544067E; Thu, 19 Aug 2021 11:03:01 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id 96F9240141 for ; Thu, 19 Aug 2021 11:02:59 +0200 (CEST) X-IronPort-AV: E=McAfee;i="6200,9189,10080"; a="302099994" X-IronPort-AV: E=Sophos;i="5.84,334,1620716400"; d="scan'208";a="302099994" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Aug 2021 02:02:58 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.84,334,1620716400"; d="scan'208";a="511715593" Received: from unknown (HELO npg-dpdk-cvl-simeisu-118d193.sh.intel.com) ([10.67.119.195]) by fmsmga004.fm.intel.com with ESMTP; 19 Aug 2021 02:02:56 -0700 From: Simei Su To: kirill.rybalchenko@intel.com, ferruh.yigit@intel.com Cc: dev@dpdk.org, qi.z.zhang@intel.com, haiyue.wang@intel.com, Simei Su Date: Thu, 19 Aug 2021 16:58:34 +0800 Message-Id: <20210819085834.30550-1-simei.su@intel.com> X-Mailer: git-send-email 2.9.5 Subject: [dpdk-dev] [PATCH] examples/ptpclient: enable Rx queue configuration X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 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 patch adds support to enable per-queue Rx offloads so that it can convey the configuration to PMD. Signed-off-by: Simei Su --- examples/ptpclient/ptpclient.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/examples/ptpclient/ptpclient.c b/examples/ptpclient/ptpclient.c index 4f32ade..d083a2e 100644 --- a/examples/ptpclient/ptpclient.c +++ b/examples/ptpclient/ptpclient.c @@ -217,8 +217,13 @@ port_init(uint16_t port, struct rte_mempool *mbuf_pool) /* Allocate and set up 1 RX queue per Ethernet port. */ for (q = 0; q < rx_rings; q++) { + struct rte_eth_rxconf *rxconf; + + rxconf = &dev_info.default_rxconf; + rxconf->offloads = port_conf.rxmode.offloads; + retval = rte_eth_rx_queue_setup(port, q, nb_rxd, - rte_eth_dev_socket_id(port), NULL, mbuf_pool); + rte_eth_dev_socket_id(port), rxconf, mbuf_pool); if (retval < 0) return retval; -- 2.9.5