Re: 2.5.31: modules don't work at all

Linus Torvalds (torvalds@transmeta.com)
Mon, 12 Aug 2002 16:45:05 -0700 (PDT)


On Mon, 12 Aug 2002, Andrew Morton wrote:
> Linus Torvalds wrote:
> >
> > On Mon, 12 Aug 2002, Andrew Morton wrote:
> > >
> > > Gets tricky with nested lock_kernels.
> >
> > No, lock-kernel already only increments once, at the first lock_kernel. We
> > have a totally separate counter for the BKL depth, see <asm/smplock.h>
> >
>
> There are eighteen smplock.h's, all different. At least one (SuperH)
> hasn't been converted to preempt.

Note that this should all be trivial, and in fact I think everybody shares
the same smplock.h these days. The x86 smplock.h is 100% C - even though
it's not actually totally visible because we still have some old asm
routines visible that are just #ifdef'ed out.

In fact, I'll clean that up a bit to make it clearer.

> However, soldiering on leads us to some difficulties. You're proposing,
> effectively, that preempt_count gets shifted left one bit and that bit
> zero becomes "has done lock_kernel()".

Actually, on slight introspection I suspect the better answer is to make
the BKL bit somewhere higher up, since BKL is much less interesting than
most spinlocks, and getting increasingly more so. But yes.

Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/