Jamie Lokier wrote: > Look in arch/arm/kernel/entry-armv.S for __kernel_cmpxchg, > kuser_cmpxchg_fixup, and all the places where kuser_cmpxchg_fixup is > called in that file. >
Here they say: /* * The only thing that can break atomicity in this cmpxchg * implementation is either an IRQ or a data abort exception * causing another process/thread to be scheduled in the middle * of the critical sequence. To prevent this, code is added to * the IRQ and data abort exception handlers to set the pc back * to the beginning of the critical section if it is found to be * within that critical section (see kuser_cmpxchg_fixup). */ So the "trick" involves modifying the basic interrupt handler code. This of course is a *nasty* trick. I'll take a look if this is viable for the NIOS architecture. Thanks for pointing me there, -Michael _______________________________________________ uClinux-dev mailing list uClinux-dev@uclinux.org http://mailman.uclinux.org/mailman/listinfo/uclinux-dev This message was resent by uclinux-dev@uclinux.org To unsubscribe see: http://mailman.uclinux.org/mailman/options/uclinux-dev