From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 74D921B104 for ; Wed, 21 Nov 2018 17:06:21 +0100 (CET) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D424381F0B; Wed, 21 Nov 2018 16:06:20 +0000 (UTC) Received: from ktraynor.remote.csb (unknown [10.36.118.7]) by smtp.corp.redhat.com (Postfix) with ESMTP id D128C608E7; Wed, 21 Nov 2018 16:06:19 +0000 (UTC) From: Kevin Traynor To: Bruce Richardson Cc: Luca Boccassi , dpdk stable Date: Wed, 21 Nov 2018 16:04:14 +0000 Message-Id: <20181121160440.9014-24-ktraynor@redhat.com> In-Reply-To: <20181121160440.9014-1-ktraynor@redhat.com> References: <20181121160440.9014-1-ktraynor@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Wed, 21 Nov 2018 16:06:20 +0000 (UTC) Subject: [dpdk-stable] patch 'net/avf: fix unused variables and label' has been queued to stable release 18.08.1 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Nov 2018 16:06:21 -0000 Hi, FYI, your patch has been queued to stable release 18.08.1 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 11/26/18. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. If the code is different (ie: not only metadata diffs), due for example to a change in context or macro names, please double check it. Thanks. Kevin Traynor --- >>From 9dd8605b36d338c28d02435b873aad37be821c38 Mon Sep 17 00:00:00 2001 From: Bruce Richardson Date: Wed, 19 Sep 2018 11:04:15 +0100 Subject: [PATCH] net/avf: fix unused variables and label [ upstream commit 584798f8e8abd403e01dd8579ccfc3a4f3d1e83b ] Compiling with all warnings turned on causes errors about unused variables and an unused label. Remove these to allow building without having to disable those warnings. Fixes: 69dd4c3d0898 ("net/avf: enable queue and device") Fixes: 3fd7a3719c66 ("net/avf: enable ops for MTU setting") Fixes: d6bde6b5eae9 ("net/avf: enable Rx interrupt") Fixes: 22b123a36d07 ("net/avf: initialize PMD") Fixes: 319c421f3890 ("net/avf: enable SSE Rx Tx") Fixes: a2b29a7733ef ("net/avf: enable basic Rx Tx") Fixes: 1060591eada5 ("net/avf: enable bulk allocate Rx") Signed-off-by: Bruce Richardson Acked-by: Luca Boccassi --- drivers/net/avf/avf_ethdev.c | 15 +-------------- drivers/net/avf/avf_rxtx.c | 19 ++++++------------- drivers/net/avf/avf_vchnl.c | 2 -- 3 files changed, 7 insertions(+), 29 deletions(-) diff --git a/drivers/net/avf/avf_ethdev.c b/drivers/net/avf/avf_ethdev.c index 3a2baaf28..be9f163be 100644 --- a/drivers/net/avf/avf_ethdev.c +++ b/drivers/net/avf/avf_ethdev.c @@ -155,5 +155,4 @@ avf_init_rss(struct avf_adapter *adapter) { struct avf_info *vf = AVF_DEV_PRIVATE_TO_VF(adapter); - struct avf_hw *hw = AVF_DEV_PRIVATE_TO_HW(adapter); struct rte_eth_rss_conf *rss_conf; uint8_t i, j, nb_q; @@ -260,9 +259,6 @@ static int avf_init_queues(struct rte_eth_dev *dev) { - struct avf_info *vf = AVF_DEV_PRIVATE_TO_VF(dev->data->dev_private); struct avf_rx_queue **rxq = (struct avf_rx_queue **)dev->data->rx_queues; - struct avf_tx_queue **txq = - (struct avf_tx_queue **)dev->data->tx_queues; int i, ret = AVF_SUCCESS; @@ -416,5 +412,4 @@ avf_dev_start(struct rte_eth_dev *dev) struct avf_info *vf = AVF_DEV_PRIVATE_TO_VF(dev->data->dev_private); struct avf_hw *hw = AVF_DEV_PRIVATE_TO_HW(dev->data->dev_private); - struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(dev); struct rte_intr_handle *intr_handle = dev->intr_handle; @@ -477,7 +472,5 @@ avf_dev_stop(struct rte_eth_dev *dev) AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); struct avf_hw *hw = AVF_DEV_PRIVATE_TO_HW(dev->data->dev_private); - struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(dev); struct rte_intr_handle *intr_handle = dev->intr_handle; - int ret, i; PMD_INIT_FUNC_TRACE(); @@ -504,6 +497,4 @@ static void avf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) { - struct avf_adapter *adapter = - AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); struct avf_info *vf = AVF_DEV_PRIVATE_TO_VF(dev->data->dev_private); @@ -916,5 +907,4 @@ static int avf_dev_mtu_set(struct rte_eth_dev *dev, uint16_t mtu) { - struct avf_info *vf = AVF_DEV_PRIVATE_TO_VF(dev->data->dev_private); uint32_t frame_size = mtu + AVF_ETH_OVERHEAD; int ret = 0; @@ -1046,6 +1036,4 @@ static int avf_dev_rx_queue_intr_disable(struct rte_eth_dev *dev, uint16_t queue_id) { - struct avf_adapter *adapter = - AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(dev); struct avf_hw *hw = AVF_DEV_PRIVATE_TO_HW(dev->data->dev_private); @@ -1090,5 +1078,5 @@ static int avf_init_vf(struct rte_eth_dev *dev) { - int i, err, bufsz; + int err, bufsz; struct avf_adapter *adapter = AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); @@ -1199,5 +1187,4 @@ avf_dev_interrupt_handler(void *param) avf_handle_virtchnl_msg(dev); -done: avf_enable_irq0(hw); } diff --git a/drivers/net/avf/avf_rxtx.c b/drivers/net/avf/avf_rxtx.c index e03a136fc..6b3b0191c 100644 --- a/drivers/net/avf/avf_rxtx.c +++ b/drivers/net/avf/avf_rxtx.c @@ -248,5 +248,4 @@ static inline void release_rxq_mbufs(struct avf_rx_queue *rxq) { - struct rte_mbuf *mbuf; uint16_t i; @@ -311,7 +310,6 @@ avf_dev_rx_queue_setup(struct rte_eth_dev *dev, uint16_t queue_idx, const struct rte_memzone *mz; uint32_t ring_size; - uint16_t len, i; + uint16_t len; uint16_t rx_free_thresh; - uint16_t base, bsf, tc_mapping; PMD_INIT_FUNC_TRACE(); @@ -429,11 +427,8 @@ avf_dev_tx_queue_setup(struct rte_eth_dev *dev, { struct avf_hw *hw = AVF_DEV_PRIVATE_TO_HW(dev->data->dev_private); - struct avf_adapter *ad = - AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); struct avf_tx_queue *txq; const struct rte_memzone *mz; uint32_t ring_size; uint16_t tx_rs_thresh, tx_free_thresh; - uint16_t i, base, bsf, tc_mapping; uint64_t offloads; @@ -516,6 +511,9 @@ avf_dev_tx_queue_setup(struct rte_eth_dev *dev, #ifdef RTE_LIBRTE_AVF_INC_VECTOR - if (check_tx_vec_allow(txq) == FALSE) + if (check_tx_vec_allow(txq) == FALSE) { + struct avf_adapter *ad = + AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); ad->tx_vec_allowed = false; + } #endif @@ -1269,5 +1267,4 @@ rx_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts) { struct avf_rx_queue *rxq = (struct avf_rx_queue *)rx_queue; - struct rte_eth_dev *dev; uint16_t nb_rx = 0; @@ -1585,8 +1582,4 @@ avf_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) if (nb_ctx) { /* Setup TX context descriptor if required */ - volatile struct avf_tx_context_desc *ctx_txd = - (volatile struct avf_tx_context_desc *) - &txr[tx_id]; - uint16_t cd_l2tag2 = 0; uint64_t cd_type_cmd_tso_mss = AVF_TX_DESC_DTYPE_CONTEXT; @@ -1604,5 +1597,5 @@ avf_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) avf_set_tso_ctx(tx_pkt, tx_offload); - AVF_DUMP_TX_DESC(txq, ctx_txd, tx_id); + AVF_DUMP_TX_DESC(txq, &txr[tx_id], tx_id); txe->last_id = tx_last; tx_id = txe->next_id; diff --git a/drivers/net/avf/avf_vchnl.c b/drivers/net/avf/avf_vchnl.c index fa71014e1..fd90cc2c3 100644 --- a/drivers/net/avf/avf_vchnl.c +++ b/drivers/net/avf/avf_vchnl.c @@ -70,5 +70,4 @@ avf_execute_vf_cmd(struct avf_adapter *adapter, struct avf_cmd_info *args) struct avf_hw *hw = AVF_DEV_PRIVATE_TO_HW(adapter); struct avf_info *vf = AVF_DEV_PRIVATE_TO_VF(adapter); - struct avf_arq_event_info event_info; enum avf_status_code ret; int err = 0; @@ -601,5 +600,4 @@ avf_config_irq_map(struct avf_adapter *adapter) struct virtchnl_vector_map *vecmap; struct avf_cmd_info args; - uint32_t vector_id; int len, i, err; -- 2.19.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2018-11-21 15:59:14.237046383 +0000 +++ 0024-net-avf-fix-unused-variables-and-label.patch 2018-11-21 15:59:13.000000000 +0000 @@ -1,8 +1,10 @@ -From 584798f8e8abd403e01dd8579ccfc3a4f3d1e83b Mon Sep 17 00:00:00 2001 +From 9dd8605b36d338c28d02435b873aad37be821c38 Mon Sep 17 00:00:00 2001 From: Bruce Richardson Date: Wed, 19 Sep 2018 11:04:15 +0100 Subject: [PATCH] net/avf: fix unused variables and label +[ upstream commit 584798f8e8abd403e01dd8579ccfc3a4f3d1e83b ] + Compiling with all warnings turned on causes errors about unused variables and an unused label. Remove these to allow building without having to disable those warnings. @@ -15,8 +17,6 @@ Fixes: a2b29a7733ef ("net/avf: enable basic Rx Tx") Fixes: 1060591eada5 ("net/avf: enable bulk allocate Rx") -CC: stable@dpdk.org - Signed-off-by: Bruce Richardson Acked-by: Luca Boccassi --- @@ -26,7 +26,7 @@ 3 files changed, 7 insertions(+), 29 deletions(-) diff --git a/drivers/net/avf/avf_ethdev.c b/drivers/net/avf/avf_ethdev.c -index a7d69828c..6b6ff7d55 100644 +index 3a2baaf28..be9f163be 100644 --- a/drivers/net/avf/avf_ethdev.c +++ b/drivers/net/avf/avf_ethdev.c @@ -155,5 +155,4 @@ avf_init_rss(struct avf_adapter *adapter) @@ -66,27 +66,27 @@ - AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); struct avf_info *vf = AVF_DEV_PRIVATE_TO_VF(dev->data->dev_private); -@@ -915,5 +906,4 @@ static int +@@ -916,5 +907,4 @@ static int avf_dev_mtu_set(struct rte_eth_dev *dev, uint16_t mtu) { - struct avf_info *vf = AVF_DEV_PRIVATE_TO_VF(dev->data->dev_private); uint32_t frame_size = mtu + AVF_ETH_OVERHEAD; int ret = 0; -@@ -1045,6 +1035,4 @@ static int +@@ -1046,6 +1036,4 @@ static int avf_dev_rx_queue_intr_disable(struct rte_eth_dev *dev, uint16_t queue_id) { - struct avf_adapter *adapter = - AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(dev); struct avf_hw *hw = AVF_DEV_PRIVATE_TO_HW(dev->data->dev_private); -@@ -1089,5 +1077,5 @@ static int +@@ -1090,5 +1078,5 @@ static int avf_init_vf(struct rte_eth_dev *dev) { - int i, err, bufsz; + int err, bufsz; struct avf_adapter *adapter = AVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private); -@@ -1198,5 +1186,4 @@ avf_dev_interrupt_handler(void *param) +@@ -1199,5 +1187,4 @@ avf_dev_interrupt_handler(void *param) avf_handle_virtchnl_msg(dev); -done: