[prev in list] [next in list] [prev in thread] [next in thread] 

List:       netbsd-tech-kern
Subject:    Re: USB stack needs early review (Re: Someone should fix our USB stack...)
From:       Reinoud Zandijk <reinoud () NetBSD ! org>
Date:       2007-05-29 11:01:20
Message-ID: 20070529110120.GB12323 () rangerover ! 13thmonkey ! org
[Download RAW message or body]


On Tue, May 29, 2007 at 06:15:22PM +0900, SODA Noriyuki wrote:
> No.
> The spl(x) before tsleep() and the splfoo() after tsleep() are both
> redundant.
> 
> > How would otherwise the interrupt handler be able to enter the spl 
> > level/interrupt level needed to modify the value's :-) Or am i wrong in 
> > this and is tsleep() taking care of that in this situation?
> 
> Yes, you are wrong. ;-)
> As you suppose, tsleep() modifies current priority level to allow
> interrupts.  See the Xspllower call in sys/arch/i386/i386/locore.S,
> of netbsd-4 branch, for example.

Thanks for the tip! But i guess the tsleep() set the spl back to the level 
it entered? That would be good... hmm... have to scout my code now ;)

Thanks,
Reinoud


[Attachment #3 (application/pgp-signature)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic