2024-03-21 15:18:06

by Masahiro Yamada

[permalink] [raw]
Subject: [GIT PULL] Kbuild updates for v6.9-rc1

Hello Linus,

Please pull Kbuild updates for v6.9-rc1.


You will see conflicts in two files.


- arch/hexagon/Kconfig
(commit 6b1c2a19cb30 vs commit ba89f9c8ccba)

- scripts/Makefile.lib
(commit 557f8c582a9b vs commit bf48d9b756b9)


The resolution is available in linux-next.

Thank you



The following changes since commit b401b621758e46812da61fa58a67c3fd8d91de0d:

Linux 6.8-rc5 (2024-02-18 12:56:25 -0800)

are available in the Git repository at:

git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild.git
tags/kbuild-v6.9

for you to fetch changes up to f2fd2aad1908554fbc4ad6e8ef23bad3086bebd1:

kconfig: tests: test dependency after shuffling choices (2024-03-21
02:40:39 +0900)

----------------------------------------------------------------
Kbuild updates for v6.9

- Generate a list of built DTB files (arch/*/boot/dts/dtbs-list)

- Use more threads when building Debian packages in parallel

- Fix warnings shown during the RPM kernel package uninstallation

- Change OBJECT_FILES_NON_STANDARD_*.o etc. to take a relative path to
Makefile

- Support GCC's -fmin-function-alignment flag

- Fix a null pointer dereference bug in modpost

- Add the DTB support to the RPM package

- Various fixes and cleanups in Kconfig

----------------------------------------------------------------
Jose Ignacio Tornos Martinez (1):
kbuild: rpm-pkg: add dtb files in kernel rpm

Masahiro Yamada (61):
kconfig: remove unneeded buffer allocation in zconf_initscan()
kconfig: fix line number in recursive inclusion detection
kbuild: create a list of all built DTB files
kbuild: simplify dtbs_install by reading the list of compiled DTBs
kbuild: deb-pkg: show verbose log for direct package builds
kbuild: deb-pkg: make debian/rules quiet for 'make deb-pkg'
kbuild: deb-pkg: build binary-arch in parallel
kbuild: deb-pkg: call more misc debhelper commands
kbuild: rpm-pkg: do not include depmod-generated files
kbuild: rpm-pkg: mark installed files in /boot as %ghost
Revert "kbuild/mkspec: support 'update-bootloader'-based systems"
Revert "kbuild/mkspec: clean boot loader configuration on rpm removal"
kconfig: fix infinite loop when expanding a macro at the end of file
kconfig: fix off-by-one in zconf_error()
kconfig: remove orphan lookup_file() declaration
kconfig: remove compat_getline()
kconfig: remove unneeded sym_find() call in conf_parse()
kconfig: write Kconfig files to autoconf.cmd in order
kconfig: call env_write_dep() right after yyparse()
kconfig: split preprocessor prototypes into preprocess.h
kconfig: replace current_pos with separate cur_{filename,lineno}
kconfig: remove zconf_curname() and zconf_lineno()
kconfig: associate struct menu with file name directly
kconfig: associate struct property with file name directly
kconfig: replace file->name with name in zconf_nextfile()
kconfig: do not delay the cur_filename update
kconfig: replace remaining current_file->name with cur_filename
kconfig: move the file and lineno in struct file to struct buffer
kconfig: make file::name a flexible array member
kconfig: change file_lookup() to return the file name
kconfig: split list_head into a separate header
kconfig: resync list.h
kconfig: import more list macros and inline functions
kconfig: add macros useful for hashtable
kconfig: move ARRAY_SIZE to a header
kconfig: move strhash() to util.c as a global function
kconfig: convert linked list of files to hash table
kconfig: do not imply the type of choice value
kconfig: print recursive dependency errors in the parsed order
kconfig: use generic macros to implement symbol hashtable
treewide: replace or remove redundant def_bool in Kconfig files
hexagon: select FRAME_POINTER instead of redefining it
hexagon: select GENERIC_IRQ_PROBE instead of redefining it
kbuild: remove EXPERT and !COMPILE_TEST guarding from TRIM_UNUSED_KSYMS
kbuild: change tool coverage variables to take the path relative to $(obj)
kbuild: change DTC_FLAGS_<basetarget>.o to take the path
relative to $(obj)
alpha: merge two entries for CONFIG_ALPHA_EV4
alpha: merge two entries for CONFIG_ALPHA_GAMMA
kbuild: fix inconsistent indentation in top Makefile
kconfig: link menus to a symbol
kconfig: use linked list in get_symbol_str() to iterate over menus
kconfig: remove named choice support
kbuild: unexport abs_srctree and abs_objtree
kbuild: remove GCC's default -Wpacked-bitfield-compat flag
kconfig: lxdialog: fix button color for blackbg theme
kconfig: lxdialog: remove unused dialog colors
kconfig: check prompt for choice while parsing
kconfig: remove unneeded menu_is_visible() call in conf_write_defconfig()
kconfig: tests: support KCONFIG_SEED for the randconfig runner
kconfig: tests: add a test for randconfig with dependent choices
kconfig: tests: test dependency after shuffling choices

Matthew Bystrin (1):
kconfig: lxdialog: fix cursor render in checklist

Max Kellermann (1):
modpost: fix null pointer dereference

Nathan Chancellor (1):
kbuild: Move -Wenum-{compare-conditional,enum-conversion} into W=1

Petr Pavlu (1):
kbuild: Use -fmin-function-alignment when available

Vegard Nossum (1):
docs: kbuild/kconfig: reformat/cleanup

.gitignore | 1 +
Documentation/kbuild/kconfig-language.rst | 6 +-
Documentation/kbuild/kconfig.rst | 363
++++++++++++++++++++++--------------------------
Makefile | 49 ++++---
arch/Kconfig | 12 ++
arch/alpha/Kconfig | 15 +-
arch/hexagon/Kconfig | 12 +-
arch/parisc/Kconfig | 4 +-
arch/riscv/kernel/tests/Kconfig.debug | 2 +-
arch/x86/entry/vdso/Makefile | 2 +
arch/x86/kvm/Kconfig | 2 +-
arch/x86/kvm/Makefile | 3 +-
arch/x86/xen/Kconfig | 1 -
drivers/acpi/Kconfig | 1 -
drivers/iommu/intel/Kconfig | 2 +-
drivers/md/Kconfig | 1 -
include/linux/compiler_types.h | 10 +-
init/Kconfig | 2 +-
kernel/module/Kconfig | 3 +-
lib/Kconfig.debug | 2 +-
mm/Kconfig | 7 +-
net/dccp/ccids/Kconfig | 2 +-
rust/Makefile | 4 +-
scripts/Kbuild.include | 6 -
scripts/Makefile.build | 22 +--
scripts/Makefile.dtbinst | 32 +++--
scripts/Makefile.extrawarn | 3 +-
scripts/Makefile.lib | 24 ++--
scripts/Makefile.package | 2 +-
scripts/kconfig/array_size.h | 11 ++
scripts/kconfig/conf.c | 12 +-
scripts/kconfig/confdata.c | 96 +++----------
scripts/kconfig/expr.h | 29 ++--
scripts/kconfig/hashtable.h | 48 +++++++
scripts/kconfig/internal.h | 12 ++
scripts/kconfig/lexer.l | 128
++++++++---------
scripts/kconfig/list.h | 254
++++++++++++++++++++++++---------
scripts/kconfig/list_types.h | 17 +++
scripts/kconfig/lkc.h | 6 +-
scripts/kconfig/lkc_proto.h | 15 --
scripts/kconfig/lxdialog/checklist.c | 5 +-
scripts/kconfig/lxdialog/dialog.h | 4 -
scripts/kconfig/lxdialog/util.c | 20 +--
scripts/kconfig/mconf.c | 1 +
scripts/kconfig/menu.c | 48 +++----
scripts/kconfig/nconf.c | 1 +
scripts/kconfig/parser.y | 125
++++++++++-------
scripts/kconfig/preprocess.c | 23 +--
scripts/kconfig/preprocess.h | 19 +++
scripts/kconfig/qconf.cc | 2 +-
scripts/kconfig/symbol.c | 49 +++----
scripts/kconfig/tests/choice_randomize/Kconfig | 22 +++
scripts/kconfig/tests/choice_randomize/__init__.py | 34 +++++
scripts/kconfig/tests/choice_randomize/expected_config0 | 6 +
scripts/kconfig/tests/choice_randomize/expected_config1 | 8 ++
scripts/kconfig/tests/choice_randomize/expected_config2 | 8 ++
scripts/kconfig/tests/choice_randomize2/Kconfig | 32 +++++
scripts/kconfig/tests/choice_randomize2/__init__.py | 18 +++
scripts/kconfig/tests/choice_randomize2/expected_config0 | 8 ++
scripts/kconfig/tests/choice_randomize2/expected_config1 | 7 +
scripts/kconfig/tests/choice_randomize2/expected_config2 | 6 +
scripts/kconfig/tests/conftest.py | 16 ++-
scripts/kconfig/tests/err_recursive_dep/expected_stderr | 24 ++--
scripts/kconfig/util.c | 47 +++++--
scripts/mod/modpost.c | 4 +-
scripts/package/builddeb | 48 ++-----
scripts/package/debian/rules | 63 +++++++--
scripts/package/kernel.spec | 48 +++++--
tools/lib/bpf/Makefile | 2 +-
69 files changed, 1131 insertions(+), 790 deletions(-)
create mode 100644 scripts/kconfig/array_size.h
create mode 100644 scripts/kconfig/hashtable.h
create mode 100644 scripts/kconfig/list_types.h
create mode 100644 scripts/kconfig/preprocess.h
create mode 100644 scripts/kconfig/tests/choice_randomize/Kconfig
create mode 100644 scripts/kconfig/tests/choice_randomize/__init__.py
create mode 100644 scripts/kconfig/tests/choice_randomize/expected_config0
create mode 100644 scripts/kconfig/tests/choice_randomize/expected_config1
create mode 100644 scripts/kconfig/tests/choice_randomize/expected_config2
create mode 100644 scripts/kconfig/tests/choice_randomize2/Kconfig
create mode 100644 scripts/kconfig/tests/choice_randomize2/__init__.py
create mode 100644 scripts/kconfig/tests/choice_randomize2/expected_config0
create mode 100644 scripts/kconfig/tests/choice_randomize2/expected_config1
create mode 100644 scripts/kconfig/tests/choice_randomize2/expected_config2

--
Best Regards
Masahiro Yamada


2024-03-21 22:25:36

by pr-tracker-bot

[permalink] [raw]
Subject: Re: [GIT PULL] Kbuild updates for v6.9-rc1

The pull request you sent on Fri, 22 Mar 2024 00:02:37 +0900:

> git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild.git tags/kbuild-v6.9

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/1d35aae78ffe739bf46c2bf9dea7b51a4eebfbe0

Thank you!

--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/prtracker.html

2024-05-05 04:55:39

by Ingo Molnar

[permalink] [raw]
Subject: Re: [GIT PULL] Kbuild updates for v6.9-rc1


* Masahiro Yamada <[email protected]> wrote:

> kbuild: simplify dtbs_install by reading the list of compiled DTBs
> kbuild: deb-pkg: show verbose log for direct package builds
> kbuild: deb-pkg: make debian/rules quiet for 'make deb-pkg'
> kbuild: deb-pkg: build binary-arch in parallel
> kbuild: deb-pkg: call more misc debhelper commands
> kbuild: rpm-pkg: do not include depmod-generated files
> kbuild: rpm-pkg: mark installed files in /boot as %ghost

Not sure whether it's related to these commits, but the kernel package
build on Ubuntu is broken currently - both the deb-pkg and bindeb-pkg
targets result in this build failure:

$ make -j32 deb-pkg
...

BTF [M] net/qrtr/qrtr-mhi.ko
BTF [M] net/qrtr/qrtr-tun.ko
BTF [M] net/batman-adv/batman-adv.ko
BTF [M] net/sctp/sctp.ko
BTF [M] net/mac80211/mac80211.ko
file
: No such file or directory
make[3]: *** [debian/rules:61: binary-image] Error 255
dpkg-buildpackage: error: make -f debian/rules binary subprocess returned exit status 2
make[2]: *** [scripts/Makefile.package:121: deb-pkg] Error 2
make[1]: *** [/home/mingo/tip.localinstall/Makefile:1541: deb-pkg] Error 2
make: *** [Makefile:240: __sub-make] Error 2

Notes:

- Yes, those weird 'file' and ': No such file or directory' strings are
pasted as-is. No idea what it's about, and the build log doesn't say.

- The .config is an unremarkable .config derived from Ubuntu's own kernel
config - can send it separately to you if it matters.

- Software version is Ununtu 23.10 with the latest updates. Can send
details if it matters. Is there an easy Make command to run to extract
the software versions you'd need, instead of having to manually extract
it from a zillion tools and packages? 'make build-environment' or so?

- The kernel package build is also incredibly slow, as reported by others
back in January AFAICS, which makes bisection impractical. There's no
other build failure visible in the build log.

I did one strace of the build (which is even more incredibly slow, takes
about an hour literally on a 4GHz box with 64 CPUs), which has shown this
weird instance shortly before the failure:

3027593 newfstatat(AT_FDCWD, "deb-pkg", 0x7ffeef9f9960, 0) = -1 ENOENT (No such file or directory)

... which might or might not be normal Make behavior.

Thanks,

Ingo

2024-05-05 05:01:26

by Ingo Molnar

[permalink] [raw]
Subject: Re: [GIT PULL] Kbuild updates for v6.9-rc1


* Ingo Molnar <[email protected]> wrote:

> Notes:
>
> - Yes, those weird 'file' and ': No such file or directory' strings are
> pasted as-is. No idea what it's about, and the build log doesn't say.

Forgot to mention that I also did a KBUILD_VERBOSE=2 build - which isn't
more verbose for this particular failure:


BTF [M] net/qrtr/qrtr.ko - due to: vmlinux
BTF [M] net/qrtr/qrtr-smd.ko - due to: vmlinux
BTF [M] net/qrtr/qrtr-tun.ko - due to: vmlinux
BTF [M] net/qrtr/qrtr-mhi.ko - due to: vmlinux
file
: No such file or directory
make[3]: *** [debian/rules:61: binary-image] Error 255
dpkg-buildpackage: error: make -f debian/rules binary subprocess returned exit status 2
make[2]: *** [scripts/Makefile.package:121: bindeb-pkg] Error 2
make[1]: *** [/home/mingo/tip.localinstall/Makefile:1541: bindeb-pkg] Error 2
make: *** [Makefile:240: __sub-make] Error 2
kepler:~/tip.localinstall>

Thanks,

Ingo

2024-05-05 05:33:30

by Ingo Molnar

[permalink] [raw]
Subject: Re: [GIT PULL] Kbuild updates for v6.9-rc1


* Ingo Molnar <[email protected]> wrote:

>
> * Ingo Molnar <[email protected]> wrote:
>
> > Notes:
> >
> > - Yes, those weird 'file' and ': No such file or directory' strings are
> > pasted as-is. No idea what it's about, and the build log doesn't say.
>
> Forgot to mention that I also did a KBUILD_VERBOSE=2 build - which isn't
> more verbose for this particular failure:

Another update - I reverted the 4 most recent commits to
scripts/package/debian/rules:

b8d18fee7aa2 Revert "kbuild: deb-pkg: show verbose log for direct package builds"
82ac586caf3d Revert "kbuild: deb-pkg: make debian/rules quiet for 'make deb-pkg'"
0b806eac90d6 Revert "kbuild: deb-pkg: build binary-arch in parallel"
4b16391dc462 Revert "kbuild: deb-pkg: call more misc debhelper commands"
f96beb84eff6 kbuild: deb-pkg: call more misc debhelper commands
1d7bae8f8c85 kbuild: deb-pkg: build binary-arch in parallel
caf400c8b68a kbuild: deb-pkg: make debian/rules quiet for 'make deb-pkg'
cc3df32c9f3a kbuild: deb-pkg: show verbose log for direct package builds

And this resolved the issue, the debs are built successfully:

...
dpkg-deb: building package 'linux-image-6.9.0-rc6-tip-00478-gb8d18fee7aa2-dbg' in '../linux-image-6.9.0-rc6-tip-00478-gb8d18fee7aa2-dbg_6.9.0-rc6-00478-gb8d18fee7aa2-8_amd64.deb'.
dpkg-genbuildinfo --build=binary -O../linux-upstream_6.9.0-rc6-00478-gb8d18fee7aa2-8_amd64.buildinfo
dpkg-genchanges --build=binary -O../linux-upstream_6.9.0-rc6-00478-gb8d18fee7aa2-8_amd64.changes
dpkg-genchanges: info: binary-only upload (no source code included)
dpkg-source --after-build .
dpkg-buildpackage: info: binary-only upload (no source included)

Thanks,

Ingo

2024-05-05 07:26:54

by Ingo Molnar

[permalink] [raw]
Subject: Re: [GIT PULL] Kbuild updates for v6.9-rc1


* Ingo Molnar <[email protected]> wrote:

>
> * Ingo Molnar <[email protected]> wrote:
>
> >
> > * Ingo Molnar <[email protected]> wrote:
> >
> > > Notes:
> > >
> > > - Yes, those weird 'file' and ': No such file or directory' strings are
> > > pasted as-is. No idea what it's about, and the build log doesn't say.
> >
> > Forgot to mention that I also did a KBUILD_VERBOSE=2 build - which isn't
> > more verbose for this particular failure:
>
> Another update - I reverted the 4 most recent commits to
> scripts/package/debian/rules:
>
> b8d18fee7aa2 Revert "kbuild: deb-pkg: show verbose log for direct package builds"
> 82ac586caf3d Revert "kbuild: deb-pkg: make debian/rules quiet for 'make deb-pkg'"
> 0b806eac90d6 Revert "kbuild: deb-pkg: build binary-arch in parallel"
> 4b16391dc462 Revert "kbuild: deb-pkg: call more misc debhelper commands"
> f96beb84eff6 kbuild: deb-pkg: call more misc debhelper commands
> 1d7bae8f8c85 kbuild: deb-pkg: build binary-arch in parallel
> caf400c8b68a kbuild: deb-pkg: make debian/rules quiet for 'make deb-pkg'
> cc3df32c9f3a kbuild: deb-pkg: show verbose log for direct package builds
>
> And this resolved the issue, the debs are built successfully:

Update, the bad commit is:

1d7bae8f8c85 kbuild: deb-pkg: build binary-arch in parallel

.. and reverting it solves the build bug.

And my Make-fu is weak, I don't see what's wrong with the commit.

Thanks,

Ingo

2024-05-05 08:46:52

by Masahiro Yamada

[permalink] [raw]
Subject: Re: [GIT PULL] Kbuild updates for v6.9-rc1

On Sun, May 5, 2024 at 4:26 PM Ingo Molnar <[email protected]> wrote:
>
>
> * Ingo Molnar <[email protected]> wrote:
>
> >
> > * Ingo Molnar <[email protected]> wrote:
> >
> > >
> > > * Ingo Molnar <[email protected]> wrote:
> > >
> > > > Notes:
> > > >
> > > > - Yes, those weird 'file' and ': No such file or directory' strings are
> > > > pasted as-is. No idea what it's about, and the build log doesn't say.
> > >
> > > Forgot to mention that I also did a KBUILD_VERBOSE=2 build - which isn't
> > > more verbose for this particular failure:
> >
> > Another update - I reverted the 4 most recent commits to
> > scripts/package/debian/rules:
> >
> > b8d18fee7aa2 Revert "kbuild: deb-pkg: show verbose log for direct package builds"
> > 82ac586caf3d Revert "kbuild: deb-pkg: make debian/rules quiet for 'make deb-pkg'"
> > 0b806eac90d6 Revert "kbuild: deb-pkg: build binary-arch in parallel"
> > 4b16391dc462 Revert "kbuild: deb-pkg: call more misc debhelper commands"
> > f96beb84eff6 kbuild: deb-pkg: call more misc debhelper commands
> > 1d7bae8f8c85 kbuild: deb-pkg: build binary-arch in parallel
> > caf400c8b68a kbuild: deb-pkg: make debian/rules quiet for 'make deb-pkg'
> > cc3df32c9f3a kbuild: deb-pkg: show verbose log for direct package builds
> >
> > And this resolved the issue, the debs are built successfully:
>
> Update, the bad commit is:
>
> 1d7bae8f8c85 kbuild: deb-pkg: build binary-arch in parallel
>
> ... and reverting it solves the build bug.
>
> And my Make-fu is weak, I don't see what's wrong with the commit.
>
> Thanks,
>
> Ingo


"make -j$(nproc) deb-pkg" works fine for me
on Ubuntu 23.10


If you provide the .config, I will test it on my machine.



--
Best Regards
Masahiro Yamada