[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20090702183223.D527B5D2D7@cooldavid.org>
Date: Mon, 29 Jun 2009 04:37:30 +0800
From: Guo-Fu Tseng <cooldavid@...ldavid.org>
To: "David Miller" <davem@...emloft.net>
Cc: "netdev" <netdev@...r.kernel.org>,
"Ethan Hsiao" <ethanhsiao@...cron.com>
Subject: [PATCH net-2.6 2/7] jme: Fix unmatched tasklet_{enable|disable} pair
Fix faulty tasklet function usage.
It's kind of silly and critical bug, hopefully it can be applied to
2.6.31.
Signed-off-by: Guo-Fu Tseng <cooldavid@...ldavid.org>
---
drivers/net/jme.c | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/drivers/net/jme.c b/drivers/net/jme.c
index abf82cd..8de3940 100644
--- a/drivers/net/jme.c
+++ b/drivers/net/jme.c
@@ -1566,6 +1566,7 @@ jme_open(struct net_device *netdev)
jme_clear_pm(jme);
JME_NAPI_ENABLE(jme);
+ tasklet_enable(&jme->linkch_task);
tasklet_enable(&jme->txclean_task);
tasklet_hi_enable(&jme->rxclean_task);
tasklet_hi_enable(&jme->rxempty_task);
@@ -1647,10 +1648,10 @@ jme_close(struct net_device *netdev)
JME_NAPI_DISABLE(jme);
- tasklet_kill(&jme->linkch_task);
- tasklet_kill(&jme->txclean_task);
- tasklet_kill(&jme->rxclean_task);
- tasklet_kill(&jme->rxempty_task);
+ tasklet_disable(&jme->linkch_task);
+ tasklet_disable(&jme->txclean_task);
+ tasklet_disable(&jme->rxclean_task);
+ tasklet_disable(&jme->rxempty_task);
jme_reset_ghc_speed(jme);
jme_disable_rx_engine(jme);
@@ -2768,6 +2769,7 @@ jme_init_one(struct pci_dev *pdev,
tasklet_init(&jme->rxempty_task,
&jme_rx_empty_tasklet,
(unsigned long) jme);
+ tasklet_disable_nosync(&jme->linkch_task);
tasklet_disable_nosync(&jme->txclean_task);
tasklet_disable_nosync(&jme->rxclean_task);
tasklet_disable_nosync(&jme->rxempty_task);
--
1.6.0.6
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists