Thread (18 messages) flat view 18 messages, 4 authors, 2007-05-28

Re: fsl booke MM vs. SMP questions

From: Gabriel Paubert <hidden>
Date: 2007-05-22 10:02:21

On Tue, May 22, 2007 at 07:14:38PM +1000, Benjamin Herrenschmidt wrote:
quoted
Why do you want to clear the reservation here? 

Coming out of some code path with the reservation still held 
can only affect buggy code (someone doing st[dw]cx. before 
l[dw]arx) AFAIK.
And buggy CPUs :-)

Seriously, lots of CPU implementations don't test the address for local
lwarx stwcx. so if your kernel code "replaces" a reservation with
another that is left set, the userland stwcx. might well succeed which
is bogus.
Well, there should always be an stwcx. to clear reservation before
any interrupt return. Otherwise you'll be able to cause hard to
reproduce bugs in the interrupted code.

Checking or not that the reservation address matches the stwcx.
is irrelevant.

	Gabriel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help