Re: [PATCH v2 4/9] x86: elf: Use e_machine to choose DLINFO in compat

From: Andy Lutomirski
Date: Thu Oct 01 2020 - 17:46:46 EST


On Thu, Oct 1, 2020 at 1:59 PM Gabriel Krisman Bertazi
<krisman@xxxxxxxxxxxxx> wrote:
>
> Since TIF_X32 is going away, avoid using it to find the ELF type on
> ARCH_DLINFO.
>
> According to SysV AMD64 ABI Draft, an AMD64 ELF object using ILP32 must
> have ELFCLASS32 with (E_MACHINE == EM_X86_64), so use that ELF field to
> differentiate a x32 object from a IA32 object when loading ARCH_DLINFO
> in compat mode.
>

Reviewed-by: Andy Lutomirski <luto@xxxxxxxxxx>

> Signed-off-by: Gabriel Krisman Bertazi <krisman@xxxxxxxxxxxxx>