Commit 2e85283d authored by Colin Ian King's avatar Colin Ian King Committed by David S. Miller
Browse files

be2net: remove redundant initialization of 'head' and pointer txq



Variable head is initialized to a value that is never read and is
being updated to a new value a few lines later, hence this
initialization is redundant and can be safely removed as well
as the now unused pointer txq.

Cleans up clang warning:
drivers/net/ethernet/emulex/benet/be_main.c:996:6: warning: Value
stored to 'head' during its initialization is never read

Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 26c26ab0
Loading
Loading
Loading
Loading
+1 −2
Original line number Original line Diff line number Diff line
@@ -991,9 +991,8 @@ static u32 be_xmit_enqueue(struct be_adapter *adapter, struct be_tx_obj *txo,
{
{
	u32 i, copied = 0, wrb_cnt = skb_wrb_cnt(skb);
	u32 i, copied = 0, wrb_cnt = skb_wrb_cnt(skb);
	struct device *dev = &adapter->pdev->dev;
	struct device *dev = &adapter->pdev->dev;
	struct be_queue_info *txq = &txo->q;
	bool map_single = false;
	bool map_single = false;
	u32 head = txq->head;
	u32 head;
	dma_addr_t busaddr;
	dma_addr_t busaddr;
	int len;
	int len;