[PATCH 02/10] rtl8192e: Remove irq_enabled flag

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

 



Signed-off-by: Mike McCormack <mikem@xxxxxxxxxx>
---
 drivers/staging/rtl8192e/r8192E.h      |    1 -
 drivers/staging/rtl8192e/r8192E_core.c |    8 +-------
 2 files changed, 1 insertions(+), 8 deletions(-)

diff --git a/drivers/staging/rtl8192e/r8192E.h b/drivers/staging/rtl8192e/r8192E.h
index 33db522..92ecfc2 100644
--- a/drivers/staging/rtl8192e/r8192E.h
+++ b/drivers/staging/rtl8192e/r8192E.h
@@ -796,7 +796,6 @@ typedef struct r8192_priv
 	LED_STRATEGY_8190	LedStrategy;
 	u8	IC_Cut;
 	int irq;
-	short irq_enabled;
 	struct ieee80211_device *ieee80211;
 #ifdef ENABLE_LPS
 	bool ps_force;
diff --git a/drivers/staging/rtl8192e/r8192E_core.c b/drivers/staging/rtl8192e/r8192E_core.c
index 613fbe4..185d390 100644
--- a/drivers/staging/rtl8192e/r8192E_core.c
+++ b/drivers/staging/rtl8192e/r8192E_core.c
@@ -658,7 +658,6 @@ static void tx_timeout(struct net_device *dev)
 static void rtl8192_irq_enable(struct net_device *dev)
 {
 	struct r8192_priv *priv = (struct r8192_priv *)ieee80211_priv(dev);
-	priv->irq_enabled = 1;
 	write_nic_dword(priv, INTA_MASK, priv->irq_mask);
 }
 
@@ -667,7 +666,7 @@ void rtl8192_irq_disable(struct net_device *dev)
 	struct r8192_priv *priv = (struct r8192_priv *)ieee80211_priv(dev);
 
 	write_nic_dword(priv, INTA_MASK, 0);
-	priv->irq_enabled = 0;
+	synchronize_irq(dev->irq);
 }
 
 void rtl8192_update_msr(struct net_device *dev)
@@ -2003,7 +2002,6 @@ static void rtl8192_init_priv_variable(struct net_device* dev)
 	priv->txringcount = 64;//32;
 	priv->rxbuffersize = 9100;//2048;//1024;
 	priv->rxringcount = MAX_RX_COUNT;//64;
-	priv->irq_enabled=0;
 	priv->rx_skb_complete = 1;
 	priv->chan = 1; //set to channel 1
 	priv->RegWirelessMode = WIRELESS_MODE_AUTO;
@@ -5346,10 +5344,6 @@ static irqreturn_t rtl8192_interrupt(int irq, void *netdev)
 
 	spin_lock_irqsave(&priv->irq_th_lock, flags);
 
-	/* We should return IRQ_NONE, but for now let me keep this */
-	if (priv->irq_enabled == 0)
-		goto out_unlock;
-
 	/* ISR: 4bytes */
 
 	inta = read_nic_dword(priv, ISR); /* & priv->IntrMask; */
-- 
1.7.0.4


_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel


[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux