Re: [RFC] disable_irq()/enable_irq() semantics and ide-probe.c

From: Jeff Garzik
Date: Thu Oct 09 2003 - 11:40:33 EST


Manfred Spraul wrote:
I'd like to use that for nic shutdown for natsemi:

disable_irq();
shutdown_nic();
free_irq();
enable_irq();


Why not just shutdown the NIC inside spin_lock_irqsave or disable_irq, and then free_irq separately?

If you can't stop the NIC hardware from generating interrupts, that's a driver bug. And if the driver cannot handle its interrupt handler between the spin_unlock_irqrestore() and free_irq() (shared irq case), it's also buggy.

Jeff



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/