Thread (3 messages) 3 messages, 3 authors, 2009-02-19

Re: [PATCH v2] net/mv643xx: don't disable the mib timer too early and lock properly

flat view

From: David Miller <davem@davemloft.net>
Date: 2009-02-19 01:37:59

From: Lennert Buytenhek <redacted>
Date: Thu, 19 Feb 2009 02:05:29 +0100
On Mon, Feb 16, 2009 at 10:28:15PM +0100, Sebastian Andrzej Siewior wrote:
quoted
mib_counters_update() also restarts the timer.
So the timer is dequeued, the stats are read and then the timer is
enqueued again. This is "okay" unless someone unloads the module.
The locking here is also broken:
mib_counters_update() grabs just a simple spinlock. The only thing the
lock is good for is to protect the timer func against other callers
namely mv643xx_eth_stop() && mv643xx_eth_get_ethtool_stats(). That means
if the spinlock is taken via the ethtool path and than the timer kicks
in then the box will lock up.

Signed-off-by: Sebastian Andrzej Siewior <redacted>
Acked-by: Lennert Buytenhek <redacted>
Also applied, thanks!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help