From patchwork Thu Sep 27 09:21:54 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Li, Xiaoyun" X-Patchwork-Id: 45489 X-Patchwork-Delegate: qi.z.zhang@intel.com Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 2968A1B156; Thu, 27 Sep 2018 11:38:57 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 935561B11A for ; Thu, 27 Sep 2018 11:38:51 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Sep 2018 02:38:49 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.54,310,1534834800"; d="scan'208";a="93725720" Received: from dpdk-xiaoyunl.sh.intel.com ([10.67.110.231]) by fmsmga001.fm.intel.com with ESMTP; 27 Sep 2018 02:38:17 -0700 From: Xiaoyun Li To: dev@dpdk.org, qi.z.zhang@intel.com, beilei.xing@intel.com, wenzhuo.lu@intel.com, jingjing.wu@intel.com Cc: Xiaoyun Li Date: Thu, 27 Sep 2018 05:21:54 -0400 Message-Id: <1538040115-44176-2-git-send-email-xiaoyun.li@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1538040115-44176-1-git-send-email-xiaoyun.li@intel.com> References: <1538040115-44176-1-git-send-email-xiaoyun.li@intel.com> Subject: [dpdk-dev] [PATCH 1/2] net/ixgbe: remove unnecessary call of rte intr enable 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" Since rte_intr_enable is called at init and start time. Remove it in interrupt_action function to avoid too many system calls. Signed-off-by: Xiaoyun Li --- drivers/net/ixgbe/ixgbe_ethdev.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c index 26b1927..9ffd8cb 100644 --- a/drivers/net/ixgbe/ixgbe_ethdev.c +++ b/drivers/net/ixgbe/ixgbe_ethdev.c @@ -217,8 +217,7 @@ static int ixgbe_dev_lsc_interrupt_setup(struct rte_eth_dev *dev, uint8_t on); static int ixgbe_dev_macsec_interrupt_setup(struct rte_eth_dev *dev); static int ixgbe_dev_rxq_interrupt_setup(struct rte_eth_dev *dev); static int ixgbe_dev_interrupt_get_status(struct rte_eth_dev *dev); -static int ixgbe_dev_interrupt_action(struct rte_eth_dev *dev, - struct rte_intr_handle *handle); +static int ixgbe_dev_interrupt_action(struct rte_eth_dev *dev); static void ixgbe_dev_interrupt_handler(void *param); static void ixgbe_dev_interrupt_delayed_handler(void *param); static int ixgbe_add_rar(struct rte_eth_dev *dev, struct ether_addr *mac_addr, @@ -4282,8 +4281,7 @@ ixgbe_dev_link_status_print(struct rte_eth_dev *dev) * - On failure, a negative value. */ static int -ixgbe_dev_interrupt_action(struct rte_eth_dev *dev, - struct rte_intr_handle *intr_handle) +ixgbe_dev_interrupt_action(struct rte_eth_dev *dev) { struct ixgbe_interrupt *intr = IXGBE_DEV_PRIVATE_TO_INTR(dev->data->dev_private); @@ -4334,7 +4332,6 @@ ixgbe_dev_interrupt_action(struct rte_eth_dev *dev, PMD_DRV_LOG(DEBUG, "enable intr immediately"); ixgbe_enable_intr(dev); - rte_intr_enable(intr_handle); return 0; } @@ -4417,7 +4414,7 @@ ixgbe_dev_interrupt_handler(void *param) struct rte_eth_dev *dev = (struct rte_eth_dev *)param; ixgbe_dev_interrupt_get_status(dev); - ixgbe_dev_interrupt_action(dev, dev->intr_handle); + ixgbe_dev_interrupt_action(dev); } static int From patchwork Thu Sep 27 09:21:55 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Li, Xiaoyun" X-Patchwork-Id: 45488 X-Patchwork-Delegate: qi.z.zhang@intel.com Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 5F30A1B14D; Thu, 27 Sep 2018 11:38:55 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 1D68D1B11A for ; Thu, 27 Sep 2018 11:38:50 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Sep 2018 02:38:49 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.54,310,1534834800"; d="scan'208";a="93725741" Received: from dpdk-xiaoyunl.sh.intel.com ([10.67.110.231]) by fmsmga001.fm.intel.com with ESMTP; 27 Sep 2018 02:38:22 -0700 From: Xiaoyun Li To: dev@dpdk.org, qi.z.zhang@intel.com, beilei.xing@intel.com, wenzhuo.lu@intel.com, jingjing.wu@intel.com Cc: Xiaoyun Li Date: Thu, 27 Sep 2018 05:21:55 -0400 Message-Id: <1538040115-44176-3-git-send-email-xiaoyun.li@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1538040115-44176-1-git-send-email-xiaoyun.li@intel.com> References: <1538040115-44176-1-git-send-email-xiaoyun.li@intel.com> Subject: [dpdk-dev] [PATCH 2/2] net/i40e: remove unnecessary call of rte intr enable 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" Since rte_intr_enable is called at init and start time. Remove it in interrupt_action function to avoid too many system calls. Signed-off-by: Xiaoyun Li --- drivers/net/i40e/i40e_ethdev.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c index 85a6a86..426d54c 100644 --- a/drivers/net/i40e/i40e_ethdev.c +++ b/drivers/net/i40e/i40e_ethdev.c @@ -6549,7 +6549,6 @@ i40e_dev_interrupt_handler(void *param) done: /* Enable interrupt */ i40e_pf_enable_irq0(hw); - rte_intr_enable(dev->intr_handle); } int