Glibc would NOT need an extra branch. It would simply load the library with
PII-specific syscalls before opening libc.so, which would cause all calls
to, say, __read(), to automagically execute the specific syscall instead of
the generic one.
In fact, glibc-2.1's /lib/ld-linux.so.2 already tries to do this.
> Jumping to kernel-specific thunking-code is the way glibc will have to
> implement this too. However, glibc doesn't know what kernel version
> is available unless it does a system call (or we could map a page with
> the version-number that it could read, but then we could just as well
> map the thunking-code directly).
>
The easy solution to this is to simply not install the specific library in
the first place.
I don't know offhand if the initialization code of the library is able to
check whether it can run, and then return "oops, take me out again" to the
loader.
-- Matthias Urlichs | noris network GmbH | smurf@noris.de The quote was selected randomly. Really. | http://www.noris.de/~smurf/-- Democrats name their children after currently popular sports figures, politicians, and entertainers. Republican children are named after their parents or grandparents, depending on where the money is.- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/faq.html