lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Sat, 2 Dec 2017 19:31:27 -0800
From:   Randy Dunlap <rdunlap@...radead.org>
To:     Andrew Randrianasulu <randrianasulu@...il.com>,
        linux-kernel@...r.kernel.org
Subject: Re: New ORC unwinder in 4.14 broke cross-compilation?

On 11/13/2017 10:33 AM, Andrew Randrianasulu wrote:
> Hello!
> 
> I was building my new 4.14 kernel, and on first instance I got working kernel + 
> modules, booted ok, found my fb console was missing, recompiled kernel with 
> framebuffer console built-in (it resetted itself from M to N, because I was 
> using menuconfig on .config from 4.12 where I had fbcon = M). After reboot into 
> new kernel everything works, so far. But if I select new ORC unwinder under 
> kernel hacking submenu - I get compilation error early:
> 
> guest@...x:/dev/shm/src/linux-2.6$ LANG=C make ARCH=x86_64 
> CROSS_COMPILE=x86_64-unknown-linux-gnu-
>   CHK     include/config/kernel.release
>   CHK     include/generated/uapi/linux/version.h
>   CHK     include/generated/utsrelease.h
>   CHK     include/generated/bounds.h
>   CHK     include/generated/timeconst.h
>   CHK     include/generated/asm-offsets.h
>   CALL    scripts/checksyscalls.sh
>   DESCEND  objtool
>   CC       /dev/shm/src/linux-2.6/tools/objtool/orc_dump.o
> orc_dump.c: In function 'orc_dump':
> orc_dump.c:105:2: error: passing argument 2 of 'elf_getshdrnum' from 
> incompatible pointer type [-Werror]
>   if (elf_getshdrnum(elf, &nr_sections)) {
>   ^
> In file included from /usr/include/gelf.h:32:0,
>                  from elf.h:22,
>                  from warn.h:26,
>                  from orc_dump.c:20:
> /usr/include/libelf.h:244:12: note: expected 'size_t *' but argument is of 
> type 'long unsigned int *'
>  extern int elf_getshdrnum (Elf *__elf, size_t *__dst);
>             ^
> orc_dump.c:190:4: error: format '%lx' expects argument of type 'long unsigned 
> int', but argument 3 has type 'Elf64_Sxword' [-Werror=format=]
>     printf("%s+%lx:", name, rela.r_addend);
>     ^
> cc1: all warnings being treated as errors
> mv: cannot stat '/dev/shm/src/linux-2.6/tools/objtool/.orc_dump.o.tmp': No such 
> file or directory
> make[3]: *** [/dev/shm/src/linux-2.6/tools/objtool/orc_dump.o] Error 1
> make[2]: *** [/dev/shm/src/linux-2.6/tools/objtool/objtool-in.o] Error 2
> make[1]: *** [objtool] Error 2
> make: *** [tools/objtool] Error 2
> 
> 
> --------------
> 
> I try to cross-compile from 32-bit slackware with self-built minimal 
> cross-compiler:
> 
> LANG=C /opt/kgcc64/bin/x86_64-unknown-linux-gnu-gcc --version
> x86_64-unknown-linux-gnu-gcc (GCC) 4.9.2
> Copyright (C) 2014 Free Software Foundation, Inc.
> This is free software; see the source for copying conditions.  There is NO
> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
> 
> I basically just followed steps from https://www.linux-mips.org/wiki/Toolchains 
> but replaced mips with x86_64 . It worked on many kernels for long time. This 
> new kernel first complained about missing gelf.h include, and after installing 
> elfutils-0.163-i586-1 (compiled on 32-bit slackware) I now have this error. 
> Problem is, even if I unselect ORC unwinder and choose Frame-pointer based 
> unwinder again - error remain, at least after make clean.
> 
> I usually monitor LKML via web-interface, but please CC me just in case I miss 
> my answers. Attached .config after changing unwinder back to frame-pointer 
> based.

Hi,
Please try the patch that was posted today:
https://marc.info/?l=linux-kernel&m=151225312110866&w=2



-- 
~Randy

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ