|
From: <jo...@hy...> - 2002-06-08 17:43:40
|
Hi Tim,
>
> I upgraded a 2.4.7-10 kernel (RedHat 7.2) box to 2.4.18-3 (RedHat 7.3),
> using the RedHat upgrade. I had 286 binaries running under the x286emul,
> binfmt_xout, binfmt_aout, abi-ibcs on the 7.2 load. I have modules.conf
> autoloading as per the autoload.txt description of the personality/module
> relationships.
>
> I got the 2.4.18 kernel patch from the link to the bitkeeper site on the ABI
> home page and applied that to my source. After that the new kernel and abi
> modules will run the 286 binaries.
In abi for kernel 2.4.12 the handling of Xenix personality changed. According to
this, the personality entries in /etc/modules.conf changed too. I guess you have
a line
alias personality-7 abi-ibcs
this line has to be
alias personality-7 abi-sco
that's all.
Actually this change should be documented in Documentation/abi/autoload.txt.
> So the question is why does dfrun show different personalities?
The answer to this question is a bit more complicated. Let us have a closer
look at the three cases:
A) personality-7 is linked to abi-ibcs and no abi modules are loaded, the
only iregistered exec domain (cat /proc/execdomains) is "0-0 Linux [kernel]":
1. dfrun is loaded by binfmt_xout . binfmt_xout tries to set the
personality of the current process to PER_XENIX (which is 7). The kernel
loads the module linked to personality 7. abi-ibcs registers an execdomain
"1-2 iBCS2/iABI4 [abi-ibcs]" . As there is still no personality 7, the
kernel assigns the default execdomain to this process which is Linux. As the
personality didn't change, there is no message.
2. When the first lcall7 happens, the default_handler for execdomain Linux
detects, that the personality has been set incorrectly and sets it to 1
(PER_SVR4). So you get the message
> "Linux Kernel:[dfrun:#####]: set personality to 4100001".
(The personality is the last byte).
From now on, lcall7 for this process is handled by abi-ibcs.
B) personality-7 is linked to abi-ibcs and abi-sco has been loaded (by running some COFF
binary).
In step 1 the kernel finds personality 7 as ist has been registered by abi-sco and
you get the message
> [dfrun:#####]: set personality to 50000007.
and everything is fine.
C) personality-7 is linked to abi-sco and no abi modules are loaded, the
only registered exec domain (cat /proc/execdomains) is "0-0 Linux [kernel]":
In step 1, abi-sco is loaded while binfmt_xout requests personality 7 .
This is confusing and I would like to have a guide "for those who want to know"
covering the internal mecanisms of linux-abi. I only know a small part of the whole
thing, so I am not able to write such a guide myself.
Joerg
--
------------------------------------------------------------------------------
Joerg Ahrens _/
Koenigsberger Strasse 32 _/_/
31226 Peine _/ _/
Tel.: 05171/57308 _/ _/_/_/_/
e-mail: jo...@hy... _/_/_/_/ _/
------------------------------------------------------------------------------
|