Anyone feeling _dangerous_ out there?!?!?

David S. Miller (davem@jenolan.rutgers.edu)
Sun, 19 Jan 1997 19:23:38 -0500


If so, good, I need some testers. All you have to do is sacrifice
your hard drives to the cause of furthering Linux SMP.

I have made extensive modifications to the SMP code in the kernel so
that true multi-threading work can truly begin (and in fact I have
done some of it for certain code paths and data structures already,
but I want this first stage code tested and submitted to Pinhead first
before I integrate these further modifications).

Of course it works flawlessly on the Sparc. I have gotten it all to
compile and have checked it all to the best of my ability on the
Intel, but I can't punt the box I used for builds at the moment.
Therefore, it is very likely to have bugs for the SMP side of things.
Uniprocessor should be just fine though I think.

In essence I have:

1) Moved all acquisition of the kernel master lock into
c-code where you can actually see it.

2) Got rid of syscall_count, kernel_counter, etc. that
was all disgusting. The lock depth is stored exclusively
in current->lock_depth, this kills a whole bunch of cycles
at task switch time, and we had that task_struct member
already so it worked out nicely.

3) Nearly all the gross trap level SMP conditionalized code
has been eliminated, this was gross too, on both Intel
and Sparc.

I'm not much of a low level Intel expert, so it is likely that I might
have gotten something wrong. Intel guru's want to take a look at the
changes in:

arch/i386/kernel/process.c
arch/i386/kernel/entry.S
include/asm-i386/irq.h

as those were the places where I wasn't exactly sure I had done things
right. In particular the bit masking to eflags done in copy_thread()
for SMP needs to be verified.

Oh and if one of you Intel gurus are bored, you might want to
implement optimized versions of the spin_lock routines, see
asm-sparc/smp_lock.h for the interfaces you need to provide and the
data types + declarations needed as well. This will be the first SMP
locking primitive I will be using for the initial multi-threaded work,
and as well just about any other primitive can be implemented
generically using these spin locks as the only hardware primitive.

Still sounds yummy? I thought so. Please note that all of Richard
Henderson's latest modutils diffs are included in this tree as well.
Essentially it is a fresh CVS checkout of the current SparcLinux
development sources.

Get it at:

vger.rutgers.edu:/pub/linux/SMP/testing/linux-smp-971019.tar.gz

I have not provided this in diff form, because there was not much
difference in size from the complete tarball. Sorry ;-(
But over the next few days as I receive bug fixes I will make patches
relative to this tarball for sure.

---------------------------------------------////
Yow! 11.26 MB/s remote host TCP bandwidth & ////
199 usec remote TCP latency over 100Mb/s ////
ethernet. Beat that! ////
-----------------------------------------////__________ o
David S. Miller, davem@caip.rutgers.edu /_____________/ / // /_/ ><