Messages in this thread | | | From | Bret Indrelee <> | Subject | RE: linux interrupt handling problem | Date | Tue, 9 Nov 1999 16:18:25 -0600 |
| |
Alan Cox [mailto:alan@lxorguk.ukuu.org.uk] wrote: > > decide if it should be spin_lock() or spin_lock_irqsave(). > We could get rid > > of the spin_lock_irqsave() and spin_unlock_irqrestore() > routines by making > > spin_lock() and spin_unlock() look at if the mutex can be > called from > > interrupt or not. > > How do you handle nested locks in such a case ?
If you mean nesting to the same spin lock, as I recall that isn't allowed on Solaris. I can double check that, it has been a couple of months since I last looked at it.
I think the Solaris DDI/DKI manuals are online.
If you mean two separate locks, A & B, where sometimes you have to get both: When the spin lock is created, you have to say what the highest interrupt level it will ever be accessed from is.
-Bret
------------------------------------------------------------- SBS Technologies, Connectivity Products ... solutions for real-time connectivity
Bret Indrelee, Engineer SBS Technologies, Inc., Connectivity Products 1284 Corporate Center Drive, St. Paul MN 55121 Direct: (651) 905-4731 Main: (651) 905-4700 Fax: (651) 905-4701 E-mail: bindrelee@sbs-cp.com http://www.sbs.com -------------------------------------------------------------
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |