[Top] [All Lists]

Re: userspace spinlocks

To: Mike Klar <>
Subject: Re: userspace spinlocks
From: Ralf Baechle <>
Date: Wed, 1 Nov 2000 14:36:11 +0100
Cc: Jun Sun <>,
In-reply-to: <>; from on Tue, Oct 31, 2000 at 10:50:39PM -0800
References: <> <>
On Tue, Oct 31, 2000 at 10:50:39PM -0800, Mike Klar wrote:

> > BTW, I didn't know the kernel already has ll/sc emulation.  That seems
> > to be necessary, even just for the binary compability sake.
> It's not complete in the Linux-MIPS tree, it is at least more so in the
> Linux VR tree, but still only supports locking between user contexts.  Patch
> is below, sorry if it doesn't apply cleanly, there were a few bits that I
> cut out that weren't pertinent to LL/SC.
> The bits that have to do with ll_task in the below patch look wrong, though,
> and I only just noticed when preparing this patch that it had gotten added.
> I'm not sure what the motivation for adding it was, maybe clearing ll_bit
> only on context switches was not sufficient to cover all cases (like thread
> creation, maybe?), but I thought I had looked into that already.

Ok, I'll take this and try to hack it into shape.  I especially don't
like putting anything into the scheduler - another 5 ns for a 200MHz box
per cotext switch go down the drain.  For sanity reasons I also think we
don't want to support SMP for the ll/sc emulation.


<Prev in Thread] Current Thread [Next in Thread>