[PATCH] xen-netback: Remove set but unused variable 'pending_idx'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Variable pending_idx is not effectively used in the function, so delete
it.

drivers/net/xen-netback/netback.c:886:7: warning: variable ‘pending_idx’ set but not used.

Link: https://bugzilla.openanolis.cn/show_bug.cgi?id=3399
Reported-by: Abaci Robot <abaci@xxxxxxxxxxxxxxxxx>
Signed-off-by: Jiapeng Chong <jiapeng.chong@xxxxxxxxxxxxxxxxx>
---
 drivers/net/xen-netback/netback.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/xen-netback/netback.c b/drivers/net/xen-netback/netback.c
index 054ac0e897f6..19d928389473 100644
--- a/drivers/net/xen-netback/netback.c
+++ b/drivers/net/xen-netback/netback.c
@@ -883,7 +883,6 @@ static void xenvif_tx_build_gops(struct xenvif_queue *queue,
 		struct xen_netif_tx_request txfrags[XEN_NETBK_LEGACY_SLOTS_MAX];
 		struct xen_netif_extra_info extras[XEN_NETIF_EXTRA_TYPE_MAX-1];
 		unsigned int extra_count;
-		u16 pending_idx;
 		RING_IDX idx;
 		int work_to_do;
 		unsigned int data_len;
@@ -984,7 +983,6 @@ static void xenvif_tx_build_gops(struct xenvif_queue *queue,
 		}
 
 		index = pending_index(queue->pending_cons);
-		pending_idx = queue->pending_ring[index];
 
 		if (ret >= XEN_NETBK_LEGACY_SLOTS_MAX - 1 && data_len < txreq.size)
 			data_len = txreq.size;
-- 
2.20.1.7.g153144c




[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux