2020-04-09 02:03:54

by youling 257

[permalink] [raw]
Subject: Re: Merge branch 'core-objtool-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

d937a6dfc9428f470c3ce4d459c390944ddef538 caused 64bit kernel build
failed on 32bit userspace.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d937a6dfc9428f470c3ce4d459c390944ddef538

2020-04-08 16:13 GMT+08:00, youling 257 <[email protected]>:
> after this merge branch, build 64bit kernel failed on 32bit userspace.
>
>
> CC tools/objtool/builtin-check.o
> CC tools/objtool/builtin-orc.o
> In file included from check.h:10,
> from builtin-check.c:18:
> elf.h: In function ‘sec_offset_hash’:
> elf.h:102:14: error: right shift count >= width of type
> [-Werror=shift-count-overflow]
> 102 | oh = offset >> 32;
> | ^~
> cc1: all warnings being treated as errors
> mv: 无法获取'tools/objtool/.builtin-check.o.tmp' 的文件状态(stat): 没有那个文件或目录
> make[6]: *** [/tools/build/Makefile.build:97:tools/objtool/builtin-check.o]
> 错误 1
> make[6]: *** 正在等待未完成的任务....
> HOSTCC scripts/kallsyms
> In file included from check.h:10,
> from builtin-orc.c:17:
> elf.h: In function ‘sec_offset_hash’:
> elf.h:102:14: error: right shift count >= width of type
> [-Werror=shift-count-overflow]
> 102 | oh = offset >> 32;
> | ^~
> In file included from arch/x86/decode.c:14:
> arch/x86/../../elf.h: In function ‘sec_offset_hash’:
> arch/x86/../../elf.h:102:14: error: right shift count >= width of type
> [-Werror=shift-count-overflow]
> 102 | oh = offset >> 32;
> | ^~
> cc1: all warnings being treated as errors
> mv: 无法获取'tools/objtool/.builtin-orc.o.tmp' 的文件状态(stat) CC
> tools/objtool/help.o
> : 没有那个文件或目录
> make[6]: *** [/tools/build/Makefile.build:97:tools/objtool/builtin-orc.o] 错误
> 1
> CC tools/objtool/pager.o
> CC tools/objtool/parse-options.o
> CC tools/objtool/run-command.o
> CC tools/objtool/sigchain.o
> HOSTCC scripts/recordmcount
> CC tools/objtool/subcmd-config.o
> HOSTCC scripts/sorttable
> HOSTCC scripts/asn1_compiler
> HOSTCC scripts/extract-cert
> HOSTLD scripts/genksyms/genksyms
> cc1: all warnings being treated as errors
> mv: 无法获取'tools/objtool/arch/x86/.decode.o.tmp' 的文件状态(stat): 没有那个文件或目录
> make[7]: ***
> [/tools/build/Makefile.build:97:tools/objtool/arch/x86/decode.o]
> 错误 1
> make[6]: *** [/tools/build/Makefile.build:139:arch/x86] 错误 2
> make[5]: *** [Makefile:46:tools/objtool/objtool-in.o] 错误 2
> make[5]: *** 正在等待未完成的任务....
>


2020-04-09 07:40:33

by Peter Zijlstra

[permalink] [raw]
Subject: Re: Merge branch 'core-objtool-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

On Thu, Apr 09, 2020 at 10:00:53AM +0800, youling 257 wrote:
> d937a6dfc9428f470c3ce4d459c390944ddef538 caused 64bit kernel build
> failed on 32bit userspace.
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d937a6dfc9428f470c3ce4d459c390944ddef538
>
> 2020-04-08 16:13 GMT+08:00, youling 257 <[email protected]>:
> > after this merge branch, build 64bit kernel failed on 32bit userspace.
> >
> >
> > CC tools/objtool/builtin-check.o
> > CC tools/objtool/builtin-orc.o
> > In file included from check.h:10,
> > from builtin-check.c:18:
> > elf.h: In function ‘sec_offset_hash’:
> > elf.h:102:14: error: right shift count >= width of type
> > [-Werror=shift-count-overflow]
> > 102 | oh = offset >> 32;
> > | ^~

Oh right; I figured it wouldn't matter since we don't do objtool for
32bit kernels, but I suppose you're cross building a 64bit kernel on a
32bit host or something daft like that?

I'll go fix it.

2020-04-11 17:32:04

by youling 257

[permalink] [raw]
Subject: Re: Merge branch 'core-objtool-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

i build 64bit kernel on 32bit host. please fix.

2020-04-09 15:38 GMT+08:00, Peter Zijlstra <[email protected]>:
> On Thu, Apr 09, 2020 at 10:00:53AM +0800, youling 257 wrote:
>> d937a6dfc9428f470c3ce4d459c390944ddef538 caused 64bit kernel build
>> failed on 32bit userspace.
>> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d937a6dfc9428f470c3ce4d459c390944ddef538
>>
>> 2020-04-08 16:13 GMT+08:00, youling 257 <[email protected]>:
>> > after this merge branch, build 64bit kernel failed on 32bit userspace.
>> >
>> >
>> > CC tools/objtool/builtin-check.o
>> > CC tools/objtool/builtin-orc.o
>> > In file included from check.h:10,
>> > from builtin-check.c:18:
>> > elf.h: In function ‘sec_offset_hash’:
>> > elf.h:102:14: error: right shift count >= width of type
>> > [-Werror=shift-count-overflow]
>> > 102 | oh = offset >> 32;
>> > | ^~
>
> Oh right; I figured it wouldn't matter since we don't do objtool for
> 32bit kernels, but I suppose you're cross building a 64bit kernel on a
> 32bit host or something daft like that?
>
> I'll go fix it.
>

2020-04-20 05:39:19

by youling 257

[permalink] [raw]
Subject: Re: Merge branch 'core-objtool-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Linux 5.7-rc2, Revert "objtool: Optimize find_rela_by_dest_range()"
Revert "objtool: Optimize read_sections()", can build 64bit kernel on
32bit userspace.