From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:57016 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S932133AbeBSTrL (ORCPT ); Mon, 19 Feb 2018 14:47:11 -0500 Received: from pps.filterd (m0098419.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w1JJk5nH002525 for ; Mon, 19 Feb 2018 14:47:10 -0500 Received: from e14.ny.us.ibm.com (e14.ny.us.ibm.com [129.33.205.204]) by mx0b-001b2d01.pphosted.com with ESMTP id 2g840atkqm-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Mon, 19 Feb 2018 14:47:10 -0500 Received: from localhost by e14.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 19 Feb 2018 14:47:10 -0500 Subject: [PATCH V3 net-next 1/5] ibmvnic: Rename active queue count variables From: Nathan Fontenot To: netdev@vger.kernel.org Cc: jallen@linux.vnet.ibm.com, tlfalcon@linux.vnet.ibm.com Date: Mon, 19 Feb 2018 13:30:05 -0600 In-Reply-To: <151906852849.50602.3447088935471280931.stgit@ltcalpine2-lp14.aus.stglabs.ibm.com> References: <151906852849.50602.3447088935471280931.stgit@ltcalpine2-lp14.aus.stglabs.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <151906860107.50602.16661162370589951909.stgit@ltcalpine2-lp14.aus.stglabs.ibm.com> Sender: netdev-owner@vger.kernel.org List-ID: Rename the tx/rx active pool variables to be tx/rx active scrq counts. The tx/rx pools are per sub-crq so this is a more appropriate name. This also is a preparatory step for using thiese variables for handling updates to sub-crqs and napi based on the active count. Signed-off-by: Nathan Fontenot --- drivers/net/ethernet/ibm/ibmvnic.c | 16 ++++++++-------- drivers/net/ethernet/ibm/ibmvnic.h | 4 ++-- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c index 27447260215d..ca2e3fbfd848 100644 --- a/drivers/net/ethernet/ibm/ibmvnic.c +++ b/drivers/net/ethernet/ibm/ibmvnic.c @@ -461,7 +461,7 @@ static void release_rx_pools(struct ibmvnic_adapter *adapter) if (!adapter->rx_pool) return; - for (i = 0; i < adapter->num_active_rx_pools; i++) { + for (i = 0; i < adapter->num_active_rx_scrqs; i++) { rx_pool = &adapter->rx_pool[i]; netdev_dbg(adapter->netdev, "Releasing rx_pool[%d]\n", i); @@ -484,7 +484,7 @@ static void release_rx_pools(struct ibmvnic_adapter *adapter) kfree(adapter->rx_pool); adapter->rx_pool = NULL; - adapter->num_active_rx_pools = 0; + adapter->num_active_rx_scrqs = 0; } static int init_rx_pools(struct net_device *netdev) @@ -509,7 +509,7 @@ static int init_rx_pools(struct net_device *netdev) return -1; } - adapter->num_active_rx_pools = 0; + adapter->num_active_rx_scrqs = 0; for (i = 0; i < rxadd_subcrqs; i++) { rx_pool = &adapter->rx_pool[i]; @@ -554,7 +554,7 @@ static int init_rx_pools(struct net_device *netdev) rx_pool->next_free = 0; } - adapter->num_active_rx_pools = rxadd_subcrqs; + adapter->num_active_rx_scrqs = rxadd_subcrqs; return 0; } @@ -613,7 +613,7 @@ static void release_tx_pools(struct ibmvnic_adapter *adapter) if (!adapter->tx_pool) return; - for (i = 0; i < adapter->num_active_tx_pools; i++) { + for (i = 0; i < adapter->num_active_tx_scrqs; i++) { netdev_dbg(adapter->netdev, "Releasing tx_pool[%d]\n", i); tx_pool = &adapter->tx_pool[i]; kfree(tx_pool->tx_buff); @@ -624,7 +624,7 @@ static void release_tx_pools(struct ibmvnic_adapter *adapter) kfree(adapter->tx_pool); adapter->tx_pool = NULL; - adapter->num_active_tx_pools = 0; + adapter->num_active_tx_scrqs = 0; } static int init_tx_pools(struct net_device *netdev) @@ -641,7 +641,7 @@ static int init_tx_pools(struct net_device *netdev) if (!adapter->tx_pool) return -1; - adapter->num_active_tx_pools = 0; + adapter->num_active_tx_scrqs = 0; for (i = 0; i < tx_subcrqs; i++) { tx_pool = &adapter->tx_pool[i]; @@ -690,7 +690,7 @@ static int init_tx_pools(struct net_device *netdev) tx_pool->producer_index = 0; } - adapter->num_active_tx_pools = tx_subcrqs; + adapter->num_active_tx_scrqs = tx_subcrqs; return 0; } diff --git a/drivers/net/ethernet/ibm/ibmvnic.h b/drivers/net/ethernet/ibm/ibmvnic.h index fe21a6e2ddae..c6d0b4afe899 100644 --- a/drivers/net/ethernet/ibm/ibmvnic.h +++ b/drivers/net/ethernet/ibm/ibmvnic.h @@ -1091,8 +1091,8 @@ struct ibmvnic_adapter { u64 opt_rxba_entries_per_subcrq; __be64 tx_rx_desc_req; u8 map_id; - u64 num_active_rx_pools; - u64 num_active_tx_pools; + u64 num_active_rx_scrqs; + u64 num_active_tx_scrqs; struct tasklet_struct tasklet; enum vnic_state state;