kernel/.gitgnore: remove stale timeconst.h and hz.bc
Subsystems (15)
PATCH 1/5 kernel/.gitgnore: remove stale timeconst.h and hz.bc
timeconst.h and hz.bc used to exist in kernel/.
Commit 5cee96459726 ("time/timers: Move all time(r) related files into kernel/time") moved them to kernel/time/.
Commit 0a227985d4a9 ("time: Move timeconst.h into include/generated") moved timeconst.h to include/generated/ and removed hz.bc .
---
kernel/.gitignore | 2 -- 1 file changed, 2 deletions(-)
kernel/.gitignore +0 -2
@@ -1,4 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only kheaders.md5 -timeconst.h -hz.bc
Signature · 1 line
2.27.0
PATCH 2/5 .gitignore: move tags and TAGS close to other tag files
For consistency, move tags and TAGS close to the cscope and GNU Global patterns.
I removed the '/' prefix in case somebody wants to manually create tag files in sub-directories.
---
.gitignore | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
.gitignore +4 -2
@@ -54,8 +54,6 @@ modules.order # # Top-level generic files # -/tags -/TAGS /linux /modules-only.symvers /vmlinux
@@ -114,6 +112,10 @@ patches-* patches series +# ctags files +tags +TAGS + # cscope files cscope.* ncscope.*
Signature · 1 line
2.27.0
PATCH 3/5 .gitignore: ignore only top-level modules.builtin
In reply to Masahiro Yamadamodules.builtin used to be created in every directory.
Since commit 8b41fc4454e3 ("kbuild: create modules.builtin without Makefile.modbuiltin or tristate.conf"), modules.builtin is created only in the top directory.
Add the '/' prefix so that it matches to only the modules.builtin located in the top directory.
It has been more than one year since that change. I hope this will not flood 'Untracked files' of 'git status'.
---
.gitignore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
.gitignore +1 -1
@@ -48,7 +48,6 @@ *.xz *.zst Module.symvers -modules.builtin modules.order #
@@ -64,6 +63,7 @@ modules.order /vmlinuz /System.map /Module.markers +/modules.builtin /modules.builtin.modinfo /modules.nsdeps
Signature · 1 line
2.27.0
PATCH 4/5 .gitignore: prefix local generated files with a slash
In reply to Masahiro YamadaThe pattern prefixed with '/' matches a file in the same directory, but not a one in sub-directories.
---
Documentation/devicetree/bindings/.gitignore | 4 ++-- arch/.gitignore | 4 ++-- certs/.gitignore | 2 +- drivers/memory/.gitignore | 2 +- drivers/tty/vt/.gitignore | 6 +++--- kernel/.gitignore | 2 +- lib/.gitignore | 10 +++++----- samples/auxdisplay/.gitignore | 2 +- samples/binderfs/.gitignore | 3 ++- samples/connector/.gitignore | 2 +- samples/hidraw/.gitignore | 2 +- samples/mei/.gitignore | 2 +- samples/nitro_enclaves/.gitignore | 2 +- samples/pidfd/.gitignore | 2 +- samples/seccomp/.gitignore | 8 ++++---- samples/timers/.gitignore | 2 +- samples/vfs/.gitignore | 4 ++-- samples/watch_queue/.gitignore | 3 ++- samples/watchdog/.gitignore | 2 +- scripts/.gitignore | 18 +++++++++--------- scripts/basic/.gitignore | 2 +- scripts/dtc/.gitignore | 4 ++-- scripts/gcc-plugins/.gitignore | 2 +- scripts/genksyms/.gitignore | 2 +- scripts/mod/.gitignore | 8 ++++---- usr/.gitignore | 4 ++-- 26 files changed, 53 insertions(+), 51 deletions(-)
Documentation/devicetree/bindings/.gitignore +2 -2
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only *.example.dts -processed-schema*.yaml -processed-schema*.json +/processed-schema*.yaml +/processed-schema*.json
arch/.gitignore +2 -2
@@ -1,3 +1,3 @@ # SPDX-License-Identifier: GPL-2.0-only -i386 -x86_64 +/i386/ +/x86_64/
certs/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -x509_certificate_list +/x509_certificate_list
drivers/memory/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -ti-emif-asm-offsets.h +/ti-emif-asm-offsets.h
drivers/tty/vt/.gitignore +3 -3
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0 -conmakehash -consolemap_deftbl.c -defkeymap.c +/conmakehash +/consolemap_deftbl.c +/defkeymap.c
kernel/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -kheaders.md5 +/kheaders.md5
lib/.gitignore +5 -5
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only -gen_crc32table -gen_crc64table -crc32table.h -crc64table.h -oid_registry_data.c +/crc32table.h +/crc64table.h +/gen_crc32table +/gen_crc64table +/oid_registry_data.c
samples/auxdisplay/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -cfag12864b-example +/cfag12864b-example
samples/binderfs/.gitignore +2 -1
@@ -1 +1,2 @@ -binderfs_example +# SPDX-License-Identifier: GPL-2.0 +/binderfs_example
samples/connector/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -ucon +/ucon
samples/hidraw/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -hid-example +/hid-example
samples/mei/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -mei-amt-version +/mei-amt-version
samples/nitro_enclaves/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0 -ne_ioctl_sample +/ne_ioctl_sample
samples/pidfd/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -pidfd-metadata +/pidfd-metadata
samples/seccomp/.gitignore +4 -4
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -bpf-direct -bpf-fancy -dropper -user-trap +/bpf-direct +/bpf-fancy +/dropper +/user-trap
samples/timers/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -hpet_example +/hpet_example
samples/vfs/.gitignore +2 -2
@@ -1,3 +1,3 @@ # SPDX-License-Identifier: GPL-2.0-only -test-fsmount -test-statx +/test-fsmount +/test-statx
samples/watch_queue/.gitignore +2 -1
@@ -1 +1,2 @@ -watch_test +# SPDX-License-Identifier: GPL-2.0-only +/watch_test
samples/watchdog/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -watchdog-simple +/watchdog-simple
scripts/.gitignore +9 -9
@@ -1,11 +1,11 @@ # SPDX-License-Identifier: GPL-2.0-only -bin2c -kallsyms -unifdef -recordmcount -sorttable -asn1_compiler -extract-cert -sign-file -insert-sys-cert +/asn1_compiler +/bin2c +/extract-cert +/insert-sys-cert +/kallsyms /module.lds +/recordmcount +/sign-file +/sorttable +/unifdef
scripts/basic/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -fixdep +/fixdep
scripts/dtc/.gitignore +2 -2
@@ -1,3 +1,3 @@ # SPDX-License-Identifier: GPL-2.0-only -dtc -fdtoverlay +/dtc +/fdtoverlay
scripts/gcc-plugins/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -randomize_layout_seed.h +/randomize_layout_seed.h
scripts/genksyms/.gitignore +1 -1
@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -genksyms +/genksyms
scripts/mod/.gitignore +4 -4
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -elfconfig.h -mk_elfconfig -modpost -devicetable-offsets.h +/elfconfig.h +/mk_elfconfig +/modpost +/devicetable-offsets.h
usr/.gitignore +2 -2
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -gen_init_cpio -initramfs_data.cpio +/gen_init_cpio +/initramfs_data.cpio /initramfs_inc_data
Signature · 1 line
2.27.0
Re: [PATCH 4/5] .gitignore: prefix local generated files with a slash
Quoted 5 lines · Masahiro Yamada
The pattern prefixed with '/' matches a file in the same directory, but not a one in sub-directories.
Signed-off-by Masahiro Yamada <[email protected]>
Good idea, it helps to be more explicit.
Cheers,
Miguel
Re: [PATCH 4/5] .gitignore: prefix local generated files with a slash
In reply to Masahiro YamadaQuoted 26 lines · Masahiro Yamada
The pattern prefixed with '/' matches a file in the same directory, but not a one in sub-directories.
Signed-off-by Masahiro Yamada <[email protected]>---
Documentation/devicetree/bindings/.gitignore | 4 ++-- arch/.gitignore | 4 ++-- certs/.gitignore | 2 +- drivers/memory/.gitignore | 2 +- drivers/tty/vt/.gitignore | 6 +++--- kernel/.gitignore | 2 +- lib/.gitignore | 10 +++++----- samples/auxdisplay/.gitignore | 2 +- samples/binderfs/.gitignore | 3 ++- samples/connector/.gitignore | 2 +- samples/hidraw/.gitignore | 2 +- samples/mei/.gitignore | 2 +- samples/nitro_enclaves/.gitignore | 2 +- samples/pidfd/.gitignore | 2 +- samples/seccomp/.gitignore | 8 ++++---- samples/timers/.gitignore | 2 +- samples/vfs/.gitignore | 4 ++-- samples/watch_queue/.gitignore | 3 ++- samples/watchdog/.gitignore | 2 +-
Quoted 8 lines
scripts/.gitignore | 18 +++++++++--------- scripts/basic/.gitignore | 2 +- scripts/dtc/.gitignore | 4 ++-- scripts/gcc-plugins/.gitignore | 2 +- scripts/genksyms/.gitignore | 2 +- scripts/mod/.gitignore | 8 ++++---- usr/.gitignore | 4 ++-- 26 files changed, 53 insertions(+), 51 deletions(-)
Re: [PATCH 4/5] .gitignore: prefix local generated files with a slash
In reply to Masahiro YamadaQuoted 297 lines · Masahiro Yamada
The pattern prefixed with '/' matches a file in the same directory, but not a one in sub-directories.
Signed-off-by Masahiro Yamada <[email protected]>---
Documentation/devicetree/bindings/.gitignore | 4 ++-- arch/.gitignore | 4 ++-- certs/.gitignore | 2 +- drivers/memory/.gitignore | 2 +- drivers/tty/vt/.gitignore | 6 +++--- kernel/.gitignore | 2 +- lib/.gitignore | 10 +++++----- samples/auxdisplay/.gitignore | 2 +- samples/binderfs/.gitignore | 3 ++- samples/connector/.gitignore | 2 +- samples/hidraw/.gitignore | 2 +- samples/mei/.gitignore | 2 +- samples/nitro_enclaves/.gitignore | 2 +- samples/pidfd/.gitignore | 2 +- samples/seccomp/.gitignore | 8 ++++---- samples/timers/.gitignore | 2 +- samples/vfs/.gitignore | 4 ++-- samples/watch_queue/.gitignore | 3 ++- samples/watchdog/.gitignore | 2 +- scripts/.gitignore | 18 +++++++++--------- scripts/basic/.gitignore | 2 +- scripts/dtc/.gitignore | 4 ++-- scripts/gcc-plugins/.gitignore | 2 +- scripts/genksyms/.gitignore | 2 +- scripts/mod/.gitignore | 8 ++++---- usr/.gitignore | 4 ++-- 26 files changed, 53 insertions(+), 51 deletions(-)Documentation/devicetree/bindings/.gitignore +2
-2@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only *.example.dts -processed-schema*.yaml -processed-schema*.json +/processed-schema*.yaml +/processed-schema*.jsonarch/.gitignore +2
-2@@ -1,3 +1,3 @@ # SPDX-License-Identifier: GPL-2.0-only -i386 -x86_64 +/i386/ +/x86_64/certs/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -x509_certificate_list +/x509_certificate_listdrivers/memory/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -ti-emif-asm-offsets.h +/ti-emif-asm-offsets.hdrivers/tty/vt/.gitignore +3
-3@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0 -conmakehash -consolemap_deftbl.c -defkeymap.c +/conmakehash +/consolemap_deftbl.c +/defkeymap.ckernel/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -kheaders.md5 +/kheaders.md5lib/.gitignore +5
-5@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only -gen_crc32table -gen_crc64table -crc32table.h -crc64table.h -oid_registry_data.c +/crc32table.h +/crc64table.h +/gen_crc32table +/gen_crc64table +/oid_registry_data.csamples/auxdisplay/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -cfag12864b-example +/cfag12864b-examplesamples/binderfs/.gitignore +2
-1@@ -1 +1,2 @@ -binderfs_example +# SPDX-License-Identifier: GPL-2.0 +/binderfs_examplesamples/connector/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -ucon +/uconsamples/hidraw/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -hid-example +/hid-examplesamples/mei/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -mei-amt-version +/mei-amt-versionsamples/nitro_enclaves/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0 -ne_ioctl_sample +/ne_ioctl_samplesamples/pidfd/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -pidfd-metadata +/pidfd-metadatasamples/seccomp/.gitignore +4
-4@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -bpf-direct -bpf-fancy -dropper -user-trap +/bpf-direct +/bpf-fancy +/dropper +/user-trapsamples/timers/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -hpet_example +/hpet_examplesamples/vfs/.gitignore +2
-2@@ -1,3 +1,3 @@ # SPDX-License-Identifier: GPL-2.0-only -test-fsmount -test-statx +/test-fsmount +/test-statxsamples/watch_queue/.gitignore +2
-1@@ -1 +1,2 @@ -watch_test +# SPDX-License-Identifier: GPL-2.0-only +/watch_testsamples/watchdog/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -watchdog-simple +/watchdog-simplescripts/.gitignore +9
-9@@ -1,11 +1,11 @@ # SPDX-License-Identifier: GPL-2.0-only -bin2c -kallsyms -unifdef -recordmcount -sorttable -asn1_compiler -extract-cert -sign-file -insert-sys-cert +/asn1_compiler +/bin2c +/extract-cert +/insert-sys-cert +/kallsyms /module.lds +/recordmcount +/sign-file +/sorttable +/unifdefscripts/basic/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -fixdep +/fixdepscripts/dtc/.gitignore +2
-2@@ -1,3 +1,3 @@ # SPDX-License-Identifier: GPL-2.0-only -dtc -fdtoverlay +/dtc +/fdtoverlayscripts/gcc-plugins/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -randomize_layout_seed.h +/randomize_layout_seed.hscripts/genksyms/.gitignore +1
-1@@ -1,2 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only -genksyms +/genksymsscripts/mod/.gitignore +4
-4@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -elfconfig.h -mk_elfconfig -modpost -devicetable-offsets.h +/elfconfig.h +/mk_elfconfig +/modpost +/devicetable-offsets.husr/.gitignore +2
-3@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -gen_init_cpio -initramfs_data.cpio +/gen_init_cpio +/initramfs_data.cpio /initramfs_inc_data --
Quoted 2 lines
2.27.0
Thanks,
Andra
Amazon Development Center (Romania) S.R.L. registered office: 27A Sf. Lazar Street, UBC5, floor 2, Iasi, Iasi County, 700045, Romania. Registered in Romania. Registration number J22/2621/2005.
PATCH 5/5 kbuild: update config_data.gz only when the content of .config is changed
In reply to Masahiro YamadaIf the timestamp of the .config file is updated, config_data.gz is regenerated, then vmlinux is re-linked. This occurs even if the content of the .config has actually not changed.
This issue was mitigated by commit 67424f61f813 ("kconfig: do not write .config if the content is the same"); Kconfig does not update the .config when it ends up with the identical configuration.
The issue is remaining when the .config is created by *_defconfig with some config fragment(s) applied on top.
This is typical for powerpc and mips, where several *_defconfig targets are constructed by (ab)using merge_config.sh.
One workaround is to have the copy of the .config. The filechk rule updates the copy, kernel/config_data, by checking the content instead of the timestamp.
With this commit, the second run with the same configuration avoids the needless rebuilds.
$ make ARCH=mips defconfig all
[ snip ]
$ make ARCH=mips defconfig all
*** Default configuration is based on target '32r2el_defconfig'
Using ./arch/mips/configs/generic_defconfig as base
Merging arch/mips/configs/generic/32r2.config
Merging arch/mips/configs/generic/el.config
Merging ./arch/mips/configs/generic/board-boston.config
Merging ./arch/mips/configs/generic/board-ni169445.config
Merging ./arch/mips/configs/generic/board-ocelot.config
Merging ./arch/mips/configs/generic/board-ranchu.config
Merging ./arch/mips/configs/generic/board-sead-3.config
Merging ./arch/mips/configs/generic/board-xilfpga.config
#
# configuration written to .config
#
SYNC include/config/auto.conf
CALL scripts/checksyscalls.sh
CALL scripts/atomic/check-atomics.sh
CHK include/generated/compile.h
CHK include/generated/autoksyms.h---
kernel/.gitignore | 1 + kernel/Makefile | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-)
kernel/.gitignore +1 -0
@@ -1,2 +1,3 @@ # SPDX-License-Identifier: GPL-2.0-only +/config_data /kheaders.md5
kernel/Makefile +7 -2
@@ -138,10 +138,15 @@ obj-$(CONFIG_SCF_TORTURE_TEST) += scftorture.o $(obj)/configs.o: $(obj)/config_data.gz -targets += config_data.gz -$(obj)/config_data.gz: $(KCONFIG_CONFIG) FORCE +targets += config_data config_data.gz +$(obj)/config_data.gz: $(obj)/config_data FORCE $(call if_changed,gzip) +filechk_cat = cat $< + +$(obj)/config_data: $(KCONFIG_CONFIG) FORCE + $(call filechk,cat) + $(obj)/kheaders.o: $(obj)/kheaders_data.tar.xz quiet_cmd_genikh = CHK $(obj)/kheaders_data.tar.xz
Signature · 1 line
2.27.0
Quoted 11 lines · Masahiro Yamada
timeconst.hand hz.bc used to exist inkernel/.Commit
5cee96459726("time/timers: Move all time(r) related files into kernel/time") moved them tokernel/time/.Commit
0a227985d4a9("time: Movetimeconst.hintoinclude/generated") movedtimeconst.htoinclude/generated/and removed hz.bc .Signed-off-by Masahiro Yamada <[email protected]>---
Applied to linux-kbuild.
Quoted 16 lines
kernel/.gitignore | 2 -- 1 file changed, 2 deletions(-)kernel/.gitignore +0
-3@@ -1,4 +1,2 @@ # SPDX-License-Identifier: GPL-2.0-only kheaders.md5 -timeconst.h -hz.bc --2.27.0
Signature · 2 lines
Best Regards Masahiro Yamada