modules fail to load for 64bit kernel with 32bit ELF format

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Building for 64bit kernel with 32bit ELF format produces the correct
object files for loading, but attempting to load them produces
ENOEXEC.

This is because the object file is failing ELF header checks in
load_module().

Elf_Ehdr in include/asm-mips/module.h is being defined as Elf64_Ehdr
based on CONFIG_MIPS64 instead of CONFIG_BUILD_ELF64.

elf_check_arch() also needs some fixing in include/asm-mips/elf.h as
it too is invoked from load_module(), however elf_check_arch() is also
used in binfmt_elf*.c.

Simply changing the defines produces loads of warnings due to casting
pointers around in module.c. Any suggestions on the best way to fix
this?

-- 
Dave Johnson
Starent Networks



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux