From: Michael Chan <mchan@broadcom.com>
Date: Tue, 22 Jan 2008 01:06:41 +0000 (-0800)
Subject: [BNX2]: Fix minor bug in bnx2_has_work().
X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=1097f5e92107ca3950fabf5e1d724faa80c91e7f;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git

[BNX2]: Fix minor bug in bnx2_has_work().

It is more correct to get the status block from the bnx2_napi struct
instead of the bnx2 struct.  It happens that they are the same in this
case because we are using the first MSIX vector.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
---

diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c
index 44734613ab37..18ed8068dc2d 100644
--- a/drivers/net/bnx2.c
+++ b/drivers/net/bnx2.c
@@ -2903,8 +2903,7 @@ bnx2_tx_msix(int irq, void *dev_instance)
 static inline int
 bnx2_has_work(struct bnx2_napi *bnapi)
 {
-	struct bnx2 *bp = bnapi->bp;
-	struct status_block *sblk = bp->status_blk;
+	struct status_block *sblk = bnapi->status_blk;
 
 	if ((bnx2_get_hw_rx_cons(bnapi) != bnapi->rx_cons) ||
 	    (bnx2_get_hw_tx_cons(bnapi) != bnapi->hw_tx_cons))