[PATCH 2/5] kconfig: nconf: fix NORMAL attributes

2021-04-10 Thread Masahiro Yamada
The lower 8-bit of attributes should be 0, but this code wrongly sets it to NORMAL (=1). The correct one is A_NORMAL. Signed-off-by: Masahiro Yamada --- scripts/kconfig/nconf.gui.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/kconfig/nconf.gui.c b/scripts

[PATCH 1/5] kconfig: mconf,nconf: remove unneeded '\0' termination after snprintf()

2021-04-10 Thread Masahiro Yamada
snprintf() always terminates the destination buffer with '\0' even if the buffer is not long enough. (In this case, the last element of the buffer becomes '\0'.) The explicit termination is unneeded. Signed-off-by: Masahiro Yamada --- scripts/kconfig/mconf.c | 11 +++ scripts/kconfig

Re: [PATCH 1/2] kbuild: dummy-tools: Add elfedit.

2021-04-10 Thread Masahiro Yamada
ff --git a/scripts/dummy-tools/elfedit b/scripts/dummy-tools/elfedit > new file mode 12 > index ..c0648b38dd42 > --- /dev/null > +++ b/scripts/dummy-tools/elfedit > @@ -0,0 +1 @@ > +ld > \ No newline at end of file > -- > 2.26.2 > -- Best Regards Masahiro Yamada

[PATCH] kconfig: use /boot/config-* etc. as DEFCONFIG_LIST only for native build

2021-04-10 Thread Masahiro Yamada
-* from the build host. It should default to arch/$(SRCARCH)/configs/$(KBUILD_DEFCONFIG). UML previously did not use DEFCONFIG_LIST at all, but it should be able to use arch/um/configs/$(KBUILD_DEFCONFIG) as a base config file. Signed-off-by: Masahiro Yamada --- Makefile | 5

Re: [PATCH v2] kconfig: nconf: stop endless search-up loops

2021-04-10 Thread Masahiro Yamada
On Sat, Apr 10, 2021 at 4:00 PM Mihai Moldovan wrote: > > * On 4/10/21 7:47 AM, Masahiro Yamada wrote: > > On Sun, Mar 28, 2021 at 6:52 PM Mihai Moldovan wrote: > >> + if ((index == -1) && (index == match_start)) > >> + re

[PATCH] kconfig: change sym_change_count into a boolean flag

2021-04-10 Thread Masahiro Yamada
-by: Masahiro Yamada --- scripts/kconfig/confdata.c | 31 +-- scripts/kconfig/lkc.h | 2 -- scripts/kconfig/lkc_proto.h | 1 + scripts/kconfig/mconf.c | 2 +- scripts/kconfig/nconf.c | 2 +- scripts/kconfig/parser.y| 2 +- scripts/kconfig/symbol.c

[PATCH] kconfig: nconf: fix core dump when searching in empty menu

2021-04-10 Thread Masahiro Yamada
should never become negative. Signed-off-by: Masahiro Yamada --- scripts/kconfig/nconf.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/scripts/kconfig/nconf.c b/scripts/kconfig/nconf.c index 42d63d7b0c52..7d2ab2944d81 100644 --- a/scripts/kconfig/nconf.c +++ b/scr

Re: [PATCH v2] kconfig: nconf: stop endless search-up loops

2021-04-09 Thread Masahiro Yamada
-504,8 +504,8 @@ static int get_mext_match(const char *match_str, match_f flag) else if (flag == FIND_NEXT_MATCH_UP) --match_start; + match_start = (match_start + items_num) % items_num; index = match_start; - index = (index + items_num) % items_num; while (true) { char *str = k_menu_items[index].str; if (strcasestr(str, match_str) != NULL) -- Best Regards Masahiro Yamada

Re: [PATCH 1/2] linux/kconfig.h: replace IF_ENABLED() with PTR_IF() in

2021-04-09 Thread Masahiro Yamada
On Fri, Apr 9, 2021 at 6:24 PM Andy Shevchenko wrote: > > On Fri, Apr 9, 2021 at 12:00 AM Masahiro Yamada wrote: > > > > is included from all the kernel-space source files, > > including C, assembly, linker scripts. It is intended to contain minimal > > a minimal &

Re: [PATCH][V2] clk: uniphier: Fix potential infinite loop

2021-04-09 Thread Masahiro Yamada
uniphier: add core support code for UniPhier clock > driver") > > Signed-off-by: Colin Ian King > --- > > V2: Make num_parents an unsigned int to match return type of > clk_hw_get_num_parents(). Reviewed-by: Masahiro Yamada > --- > drivers/clk/uniphier/clk-

Re: [PATCH 1/2] linux/kconfig.h: replace IF_ENABLED() with PTR_IF() in

2021-04-09 Thread Masahiro Yamada
On Fri, Apr 9, 2021 at 5:15 PM Paul Cercueil wrote: > > Hi Masahiro, > > Le ven. 9 avril 2021 à 5:58, Masahiro Yamada a > écrit : > > is included from all the kernel-space source files, > > including C, assembly, linker scripts. It is intended to contain &g

Re: [PATCH v2 05/13] mmc: sdhci-cadence: Add Pensando Elba SoC support

2021-04-09 Thread Masahiro Yamada
On Tue, Mar 30, 2021 at 7:31 PM Ulf Hansson wrote: > > + Masahiro Yamada (main author of the driver) > > On Mon, 29 Mar 2021 at 03:59, Brad Larson wrote: > > > > Add support for Pensando Elba SoC which explicitly controls > > byte-lane enables on writes. Refactor

Re: [PATCH] clk: uniphier: Fix potential infinite loop

2021-04-09 Thread Masahiro Yamada
+ int i; > > ret = regmap_read(mux->regmap, mux->reg, ); > if (ret) > -- > 2.30.2 > clk_hw_get_num_parents() returns 'unsigned int', so I think 'num_parents' should also have been 'unsigned int'. Maybe, the loop counter 'i' also should be 'unsigned int' then? -- Best Regards Masahiro Yamada

Re: [PATCH V11 3/5] kbuild: Allow .dtso format for overlay source files

2021-04-09 Thread Masahiro Yamada
On Tue, Mar 16, 2021 at 5:01 PM Geert Uytterhoeven wrote: > > Hi Frank, > > On Tue, Mar 16, 2021 at 6:39 AM Frank Rowand wrote: > > On 3/15/21 5:12 PM, Laurent Pinchart wrote: > > > On Tue, Mar 16, 2021 at 02:43:45AM +0900, Masahiro Yamada wrote: > > >> But

Re: [PATCH 1/7] x86/syscalls: fix -Wmissing-prototypes warnings from COND_SYSCALL()

2021-04-08 Thread Masahiro Yamada
Hello, x86 maintainers, Thanks for picking up 1/7. Could you check 2/7 - 7/7, please? Thank you. On Thu, Mar 25, 2021 at 11:31 PM Masahiro Yamada wrote: > > On Thu, Mar 25, 2021 at 8:48 PM Mickaël Salaün wrote: > > > > Hi Masahiro, > > > > What is the s

Re: [PATCH 2/2] pm: allow drivers to drop #ifdef and __maybe_unused from pm callbacks

2021-04-08 Thread Masahiro Yamada
On Fri, Apr 9, 2021 at 6:30 AM Arnd Bergmann wrote: > > On Thu, Apr 8, 2021 at 11:00 PM Masahiro Yamada wrote: > > > > Drivers typically surround suspend and resume callbacks with #ifdef > > CONFIG_PM(_SLEEP) or mark them as __maybe_unused in order to avoid > > -W

[PATCH 2/2] pm: allow drivers to drop #ifdef and __maybe_unused from pm callbacks

2021-04-08 Thread Masahiro Yamada
by the compiler instead of the preprocessor. Signed-off-by: Masahiro Yamada --- include/linux/pm.h | 67 +- 1 file changed, 24 insertions(+), 43 deletions(-) diff --git a/include/linux/pm.h b/include/linux/pm.h index 482313a8ccfc..ca764566692a 100644

[PATCH 0/2] linux/kconfig.h: move IF_ENABLED() out of

2021-04-08 Thread Masahiro Yamada
to allow driver cleanups. Masahiro Yamada (2): linux/kconfig.h: replace IF_ENABLED() with PTR_IF() in pm: allow drivers to drop #ifdef and __maybe_unused from pm callbacks drivers/pinctrl/pinctrl-ingenic.c | 20 - include/linux/kconfig.h | 6 --- include/linux/kernel.h

[PATCH 1/2] linux/kconfig.h: replace IF_ENABLED() with PTR_IF() in

2021-04-08 Thread Masahiro Yamada
(), pm_ptr() etc. for common use-cases. Signed-off-by: Masahiro Yamada --- drivers/pinctrl/pinctrl-ingenic.c | 20 ++-- include/linux/kconfig.h | 6 -- include/linux/kernel.h| 2 ++ 3 files changed, 12 insertions(+), 16 deletions(-) diff --git a/drivers

[PATCH] powerpc: remove old workaround for GCC < 4.9

2021-04-07 Thread Masahiro Yamada
According to Documentation/process/changes.rst, the minimum supported GCC version is 4.9. This workaround is dead code. Signed-off-by: Masahiro Yamada --- arch/powerpc/Makefile | 6 -- 1 file changed, 6 deletions(-) diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile index

Re: [PATCH v3] kbuild: add support for zstd compressed modules

2021-04-07 Thread Masahiro Yamada
-lzma2=dict=2MiB -f $< > +quiet_cmd_zstd = ZSTD $@ > + cmd_zstd = $(ZSTD) -T0 --rm -f -q $< > > $(dst)/%.ko.gz: $(dst)/%.ko FORCE > $(call cmd,gzip) > @@ -102,6 +105,9 @@ $(dst)/%.ko.gz: $(dst)/%.ko FORCE > $(dst)/%.ko.xz: $(dst)/%.ko FORCE > $(call cmd,xz) > > +$(dst)/%.ko.zst: $(dst)/%.ko FORCE > + $(call cmd,zstd) > + > PHONY += FORCE > FORCE: > > -- > 2.31.0.97.g1424303384 > -- Best Regards Masahiro Yamada

Re: [PATCH] MIPS: select ARCH_KEEP_MEMBLOCK unconditionally

2021-04-07 Thread Masahiro Yamada
; https://lore.kernel.org/linux-kbuild/20210313194836.372585-11-masahi...@kernel.org/ > Fixes: commit a8c0f1c634507 ("MIPS: Select ARCH_KEEP_MEMBLOCK if > DEBUG_KERNEL to enable sysfs memblock debug") > Cc: Masahiro Yamada Please replace it with: Reviewed-by: Masahiro Yama

Re: [PATCH] init: add support for zstd compressed modules

2021-04-07 Thread Masahiro Yamada
> bool "GZIP" > @@ -2281,6 +2281,9 @@ config MODULE_COMPRESS_GZIP > config MODULE_COMPRESS_XZ > bool "XZ" > > +config MODULE_COMPRESS_ZSTD > + bool "ZSTD" > + > endchoice > > config MODULE_ALLOW_MISSING_NAMESPACE_IMPORTS > -- > 2.31.0.97.g1424303384 > -- Best Regards Masahiro Yamada

Re: [PATCH 1/9] kbuild: remove unneeded mkdir for external modules_install

2021-04-07 Thread Masahiro Yamada
On Wed, Mar 31, 2021 at 10:38 PM Masahiro Yamada wrote: > > scripts/Makefile.modinst creates directories as needed. > > Signed-off-by: Masahiro Yamada > --- Applied to linux-kbuild. > > Makefile | 2 -- > 1 file changed, 2 deletions(-) > > diff --git

Re: [PATCH 9/9] kbuild: remove CONFIG_MODULE_COMPRESS

2021-04-07 Thread Masahiro Yamada
On Wed, Mar 31, 2021 at 10:39 PM Masahiro Yamada wrote: > > CONFIG_MODULE_COMPRESS is only used to activate the choice for module > compression algorithm. It will be simpler to make the choice visible > all the time by adding CONFIG_MODULE_COMPRESS_NONE to allow the user to >

Re: [PATCH] kbuild: merge module sections under CONFIG_LD_DEAD_CODE_DATA_ELIMINATION too

2021-04-07 Thread Masahiro Yamada
ve > an access to it (only a few does). This > should be relatively safe. > > > Sami > > Thanks, > Al -- Best Regards Masahiro Yamada

Re: [PATCH] init: add support for zstd compressed modules

2021-04-07 Thread Masahiro Yamada
gt;>> module-init-tools MAY support gzip, and kmod MAY support gzip and > >>>> xz. > >>>> > >>>> @@ -2273,7 +2273,7 @@ choice > >>>> This determines which sort of compression will be used during > >>>> 'make modules_install'. > >>>> > >>>> -GZIP (default) and XZ are supported. > >>>> +GZIP (default), XZ, and ZSTD are supported. > >>>> > >>>> config MODULE_COMPRESS_GZIP > >>>>bool "GZIP" > >>>> @@ -2281,6 +2281,9 @@ config MODULE_COMPRESS_GZIP > >>>> config MODULE_COMPRESS_XZ > >>>>bool "XZ" > >>>> > >>>> +config MODULE_COMPRESS_ZSTD > >>>> + bool "ZSTD" > >>>> + > >>>> endchoice > >>>> > >>>> config MODULE_ALLOW_MISSING_NAMESPACE_IMPORTS > >>>> -- > >>>> 2.31.0.97.g1424303384 > >>>> > >>> > >>> Great! > >>> > >>> Reviewed-by: Oleksandr Natalenko > >>> > >>> This works perfectly fine in Arch Linux if accompanied by the > >>> following mkinitcpio amendment: [1]. > >>> > >>> I'm also Cc'ing other people from get_maintainers output just > >>> to make this submission more visible. > >>> > >>> Thanks. > >>> > >>> [1] https://github.com/archlinux/mkinitcpio/pull/43 > >>> > >>> -- > >>> Oleksandr Natalenko (post-factum) > >> > > > > -- > > Oleksandr Natalenko (post-factum) > -- Best Regards Masahiro Yamada

Re: [PATCH 07/20] kbuild: scripts/install.sh: allow for the version number

2021-04-07 Thread Masahiro Yamada
On Wed, Apr 7, 2021 at 10:04 PM Greg Kroah-Hartman wrote: > > On Wed, Apr 07, 2021 at 08:05:23PM +0900, Masahiro Yamada wrote: > > On Wed, Apr 7, 2021 at 2:35 PM Greg Kroah-Hartman > > wrote: > > > > > > Some architectures put the version number by d

Re: [PATCH] kconfig: lxdialog: A spello fix and a punctuation added

2021-04-07 Thread Masahiro Yamada
gt; + * keypad(FALSE) turn off ncurses support for escape sequences - and that's > * needed to make notimeout() do as expected. > */ > int on_key_esc(WINDOW *win) > -- > 2.26.2 > -- Best Regards Masahiro Yamada

Re: [PATCH] kconfig: streamline_config.pl: Couple of typo fixes

2021-04-07 Thread Masahiro Yamada
the original config and use that. > sub parse_config_selects > { > my ($config, $p) = @_; > -- > 2.26.2 > -- Best Regards Masahiro Yamada

Re: [PATCH] scripts: modpost.c: Fix a few typos

2021-04-07 Thread Masahiro Yamada
andler: Specific handler to call when a match is found. If NULL, > * default_mismatch_handler() will be called. > -- > 2.26.2 > -- Best Regards Masahiro Yamada

Re: [PATCH 11/13] kconfig: do not use allnoconfig_y option

2021-04-07 Thread Masahiro Yamada
On Thu, Apr 1, 2021 at 3:25 AM Nick Desaulniers wrote: > > On Wed, Mar 31, 2021 at 10:12 AM Guenter Roeck wrote: > > > > On Sun, Mar 14, 2021 at 04:48:34AM +0900, Masahiro Yamada wrote: > > > allnoconfig_y is a bad hack that sets a symbol to 'y' by allnoconfig. &

Re: [PATCH 20/20] kbuild: scripts/install.sh: update documentation

2021-04-07 Thread Masahiro Yamada
lo/install > else > - echo "Cannot find LILO." > + echo "Cannot find LILO, ensure your bootloader knows > of the new kernel image." Since you soften the message, I guess this is not a warning message. I assume it is intentional to put it in stdout instead of stderr. > fi > ;; > esac > -- > 2.31.1 > -- Best Regards Masahiro Yamada

Re: [PATCH 16/20] kbuild: powerpc: use common install script

2021-04-07 Thread Masahiro Yamada
correct location Perhaps, we can remove this if the ppc maintainers approve it ? > + path=$4 > + shift 4 > + while [ $# -ne 0 ]; do > + image_name=$(basename "$1") > + install "$1" "$path"/"$image_name" > + shift > + done; > + sync > + ;; > x86) > if [ -x /sbin/lilo ]; then > /sbin/lilo > -- > 2.31.1 > -- Best Regards Masahiro Yamada

Re: [PATCH 15/20] kbuild: parisc: use common install script

2021-04-07 Thread Masahiro Yamada
fault install > - > -if [ "$(basename $2)" = "vmlinuz" ]; then > -# Compressed install > - echo "Installing compressed kernel" > - base=vmlinuz > -else > -# Normal install > - echo "Installing normal kernel" > - base=vmlinux > -fi > - > -if [ -f $4/$base-$1 ]; then > - mv $4/$base-$1 $4/$base-$1.old > -fi > -cat $2 > $4/$base-$1 > - > -# Install system map file > -if [ -f $4/System.map-$1 ]; then > - mv $4/System.map-$1 $4/System.map-$1.old > -fi > -cp $3 $4/System.map-$1 > - > diff --git a/scripts/install.sh b/scripts/install.sh > index 407ffa65062c..e0ffb95737d4 100644 > --- a/scripts/install.sh > +++ b/scripts/install.sh > @@ -53,6 +53,7 @@ base=$(basename "$2") > if [ "$base" = "bzImage" ] || > [ "$base" = "Image.gz" ] || > [ "$base" = "vmlinux.gz" ] || > + [ "$base" = "vmlinuz" ] || > [ "$base" = "zImage" ] ; then > # Compressed install > echo "Installing compressed kernel" > -- > 2.31.1 > -- Best Regards Masahiro Yamada

Re: [PATCH 13/20] kbuild: nds32: convert to use the common install scripts

2021-04-07 Thread Masahiro Yamada
$(build)=$(boot) $(boot)/$@ +PHONY += install zinstall +install zinstall: + $(Q)$(MAKE) $(build)=$(boot) $@ PHONY += vdso_install vdso_install: Anyway, I agree that nds32 installation targets are terribly broken. -- Best Regards Masahiro Yamada

Re: [PATCH 07/20] kbuild: scripts/install.sh: allow for the version number

2021-04-07 Thread Masahiro Yamada
esac > + > +install "$2" "$4"/"$base""$version" Too many quotes are eye sore. install "$2" "$4/$base$version" looks cleaner in my opinion. Shell correctly understands the end of each variable because a slash or a dollar cannot be a part of a variable name. > +install "$3" "$4"/System.map"$version" > sync > > # Some architectures like to call specific bootloader "helper" programs: > -- > 2.31.1 > -- Best Regards Masahiro Yamada

Re: [PATCH 06/20] kbuild: scripts/install.sh: handle compressed/uncompressed kernel images

2021-04-07 Thread Masahiro Yamada
; + echo "Installing normal kernel" Same here. This message tends to be wrong. For example, arch/arm/boot/uImage is gzip-compressed, but it says "Installing normal kernel". > + base=vmlinux > +fi > + > +install "$2" "$4"/"$base" > install "$3" "$4"/System.map > sync > > -- > 2.31.1 > -- Best Regards Masahiro Yamada

Re: [PATCH 04/20] kbuild: scripts/install.sh: call sync before calling the bootloader installer

2021-04-07 Thread Masahiro Yamada
ou want to ensure everything is flushed to a disk before this scripts exits, adding 'sync' at the end of the script makes more sense, in my opinion. if [ -x /sbin/lilo ]; then /sbin/lilo elif [ -x /etc/lilo/install ]; then /etc/lilo/install else echo "Cannot find LILO." fi sync This goes aligned with nios2 and m68k. -- Best Regards Masahiro Yamada

Re: [PATCH 03/20] kbuild: scripts/install.sh: provide a "install" function

2021-04-07 Thread Masahiro Yamada
STALLKERNEL}" ]; then exec /sbin/"${INSTALLKERNEL}" "$@"; > fi > > # Default install - same as make zlilo > - > -if [ -f "$4"/vmlinuz ]; then > - mv "$4"/vmlinuz "$4"/vmlinuz.old > -fi > - > -if [ -f "$4"/System.map ]; then > - mv "$4"/System.map "$4"/System.old > -fi > - > -cat "$2" > "$4"/vmlinuz > -cp "$3" "$4"/System.map > +install "$2" "$4"/vmlinuz > +install "$3" "$4"/System.map > > if [ -x /sbin/lilo ]; then > /sbin/lilo > -- > 2.31.1 > -- Best Regards Masahiro Yamada

Re: [PATCH 02/20] kbuild: scripts/install.sh: properly quote all variables

2021-04-07 Thread Masahiro Yamada
.map ]; then > - mv $4/System.map $4/System.old > +if [ -f "$4"/System.map ]; then > + mv "$4"/System.map "$4"/System.old > fi > > -cat $2 > $4/vmlinuz > -cp $3 $4/System.map > +cat "$2" > "$4"/vmlinuz > +cp "$3" "$4"/System.map > > if [ -x /sbin/lilo ]; then > /sbin/lilo > -- > 2.31.1 > -- Best Regards Masahiro Yamada

Re: [PATCH 00/20] kbuild: unify the install.sh script usage

2021-04-07 Thread Masahiro Yamada
l is being built; it has been used in the > > past (one will notice that the arm32 version is not a direct copy of > > the x86 version, and never was - it was modified from day 1.) It's > > placement and naming of the files in /boot is still used today, which > > is slightly different from the x86 version. > > The placement depends on the caller to the script, so that's not an > issue here. The name for the output does differ from x86, but the > "common" script handles all of that (or it should, if not I messed up.) > > Attached below is the common scripts/install.sh that this patch series > produces at the end of it, if you want to check to see if I missed > anything for your arch. > > thanks, > > greg k-h Thanks for nice cleanups! I will give some nit-picking comments to individual patches. Overall, this series looks nice. -- Best Regards Masahiro Yamada

Re: [PATCH] Kbuild: Update config_data.gz only if KCONFIG_CONFIG materially changed

2021-04-02 Thread Masahiro Yamada
= cat $(real-prereqs) | $(KGZIP) -n -f -9 > + > # DTC > # --- > DTC ?= $(objtree)/scripts/dtc/dtc > -- > The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, > a Linux Foundation Collaborative Project > -- Best Regards Masahiro Yamada

Re: allmodconfig not working with dummy-tools

2021-04-01 Thread Masahiro Yamada
on "$@"; then + echo "GNU assembler (scripts/dummy-tools) 2.50" + exit 0 +fi + if arg_contain -S "$@"; then # For scripts/gcc-x86-*-has-stack-protector.sh if arg_contain -fstack-protector "$@"; then -- Best Regards Masahiro Yamada

[PATCH 1/2] mips: replace deprecated EXTRA_CFLAGS with ccflags-y

2021-03-31 Thread Masahiro Yamada
As Documentation/kbuild/makefiles.rst says, EXTRA_CFLAGS is deprecated. Replace it with ccflags-y. Signed-off-by: Masahiro Yamada --- arch/mips/kvm/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/mips/kvm/Makefile b/arch/mips/kvm/Makefile index 506c4ac0ba1c

[PATCH 2/2] mips: clean up kvm Makefile

2021-03-31 Thread Masahiro Yamada
You can use kvm-y instead of kvm-objs to create the composite module. kvm-$(CONFIG_...) looks cleaner. Signed-off-by: Masahiro Yamada --- arch/mips/kvm/Makefile | 21 + 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/arch/mips/kvm/Makefile b/arch/mips/kvm

[PATCH 2/2] m68k: remove meaningless EXTRA_LDFLAGS

2021-03-31 Thread Masahiro Yamada
These two Makefiles contain only built-in objects (i.e. obj-y), which are collected by $(AR) into a thin-archive. EXTRA_LDFLAGS is meaningless because $(LD) is not used here. Signed-off-by: Masahiro Yamada --- arch/m68k/fpsp040/Makefile | 2 -- arch/m68k/ifpsp060/Makefile | 2 -- 2 files

[PATCH 1/2] m68k: remove meaningless $(OS_OBJS)

2021-03-31 Thread Masahiro Yamada
'git grep OS_OBJS' hits only this line. $(OS_OBJS) is just empty. Signed-off-by: Masahiro Yamada --- arch/m68k/fpsp040/Makefile | 2 -- 1 file changed, 2 deletions(-) diff --git a/arch/m68k/fpsp040/Makefile b/arch/m68k/fpsp040/Makefile index aab04d372ae7..5537807457fb 100644 --- a/arch/m68k

Re: [PATCH] docs: Remove make headers_check from checklist in translations

2021-03-31 Thread Masahiro Yamada
Hi Jon, On Tue, Mar 2, 2021 at 11:19 PM Masahiro Yamada wrote: > > Commit 1a63f9cce7b7 ("docs: Remove make headers_check from checklist") > fixed only the English version. > > Let's fix the translated variants too. > > Signed-off-by: Masahiro Yamada ping?

[PATCH 9/9] kbuild: remove CONFIG_MODULE_COMPRESS

2021-03-31 Thread Masahiro Yamada
mode" and "Built-in initramfs compression mode" choices. CONFIG_KERNEL_UNCOMPRESSED and CONFIG_INITRAMFS_COMPRESSION_NONE are available to choose to not compress the kernel, initrd, respectively. Signed-off-by: Masahiro Yamada --- init/Kconfig | 45 ++--

[PATCH 5/9] kbuild: rename extmod-prefix to extmod_prefix

2021-03-31 Thread Masahiro Yamada
This seems to be useful in sub-make as well. As a preparation of exporting it, rename extmod-prefix to extmod_prefix because exported variables cannot contain hyphens. Signed-off-by: Masahiro Yamada --- Makefile | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff

[PATCH 8/9] kbuild: merge scripts/Makefile.modsign to scripts/Makefile.modinst

2021-03-31 Thread Masahiro Yamada
Signed-off-by: Masahiro Yamada --- Makefile | 36 scripts/Makefile.modinst | 9 + scripts/Makefile.modsign | 29 - 3 files changed, 29 insertions(+), 45 deletions(-) delete mode 100644 scripts/Makefile.modsign

[PATCH 3/9] kbuild: show the target directory for depmod log

2021-03-31 Thread Masahiro Yamada
It is clearer to show the directory which depmod will work on. Signed-off-by: Masahiro Yamada --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 99a2bd51c02d..a6f73335757d 100644 --- a/Makefile +++ b/Makefile @@ -1778,7 +1778,7 @@ ifdef

[PATCH 6/9] kbuild: refactor scripts/Makefile.modinst

2021-03-31 Thread Masahiro Yamada
scripts/Makefile.modinst is ugly and weird in multiple ways; it specifies real files $(modules) as phony, makes directory manipulation needlessly too complicated. Clean up the Makefile code, and show the full path of installed modules in the log. Signed-off-by: Masahiro Yamada --- Makefile

[PATCH 4/9] kbuild: check module name conflict for external modules as well

2021-03-31 Thread Masahiro Yamada
If there are multiple modules with the same name in the same external module tree, there is ambiguity about which one will be loaded, and very likely something odd is happening. Signed-off-by: Masahiro Yamada --- Makefile | 10 +- scripts/modules-check.sh | 4 ++-- 2

[PATCH 2/9] kbuild: unify modules(_install) for in-tree and external modules

2021-03-31 Thread Masahiro Yamada
to build external modules with CONFIG_MODULES=n. Signed-off-by: Masahiro Yamada --- Makefile | 85 1 file changed, 36 insertions(+), 49 deletions(-) diff --git a/Makefile b/Makefile index 0e06db5ed9d8..99a2bd51c02d 100644 --- a/Makefile

[PATCH 7/9] kbuild: move module strip/compression code into scripts/Makefile.modinst

2021-03-31 Thread Masahiro Yamada
-by: Masahiro Yamada --- Makefile | 32 - scripts/Makefile.modinst | 76 +++- 2 files changed, 68 insertions(+), 40 deletions(-) diff --git a/Makefile b/Makefile index 88e5c15e1186..f96ae09d111b 100644 --- a/Makefile +++ b/Makefile

[PATCH 1/9] kbuild: remove unneeded mkdir for external modules_install

2021-03-31 Thread Masahiro Yamada
scripts/Makefile.modinst creates directories as needed. Signed-off-by: Masahiro Yamada --- Makefile | 2 -- 1 file changed, 2 deletions(-) diff --git a/Makefile b/Makefile index ed8bd815e8a3..0e06db5ed9d8 100644 --- a/Makefile +++ b/Makefile @@ -1779,10 +1779,8 @@ $(MODORDER): descend PHONY

Kbuild fix for today's linux-next

2021-03-28 Thread Masahiro Yamada
null) # Split the line on spaces. IFS=' ' -- Best Regards Masahiro Yamada

Re: [PATCH] arm64: move --fix-cortex-a53-843419 linker test to Kconfig

2021-03-28 Thread Masahiro Yamada
On Fri, Mar 26, 2021 at 11:36 PM Catalin Marinas wrote: > > Hi Masahiro, > > On Wed, Mar 24, 2021 at 04:11:28PM +0900, Masahiro Yamada wrote: > > $(call ld-option, --fix-cortex-a53-843419) in arch/arm64/Makefile is > > evaluated every time even for Make targets tha

[PATCH 1/3] kbuild: generate Module.symvers only when vmlinux exists

2021-03-25 Thread Masahiro Yamada
me it because some projects (e.g. kmod) parse it. Signed-off-by: Masahiro Yamada --- .gitignore | 1 + Documentation/dontdiff | 1 + Makefile | 2 +- scripts/Makefile.modpost | 15 ++- scripts/mod/modpost.c| 15 +-- 5 files changed, 18

[PATCH 2/3] kbuild: do not set -w for vmlinux.o modpost

2021-03-25 Thread Masahiro Yamada
from_dump) continue; Signed-off-by: Masahiro Yamada --- scripts/Makefile.modpost | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/scripts/Makefile.modpost b/scripts/Makefile.modpost index 3f5b09a09aef..b3e08fb1fd56 100644 --- a/scripts/Makefile.modpost +++

[PATCH 3/3] kbuild: fix false-positive modpost warning when all symbols are trimmed

2021-03-25 Thread Masahiro Yamada
e too many (10+) unresolved symbol warnings, show only the first 10, and also the number of suppressed warnings. [1]: https://git.kernel.org/pub/scm/linux/kernel/git/history/history.git/commit/?id=1cc0e0529569bf6a94f6d49770aa6d4b599d2c46 Reported-by: Nathan Chancellor Signed-off-by: Masah

Re: [PATCH v2] kbuild: enforce -Werror=unused-result

2021-03-25 Thread Masahiro Yamada
On Fri, Mar 26, 2021 at 2:07 AM Olaf Hering wrote: > > Am Fri, 26 Mar 2021 01:55:41 +0900 > schrieb Masahiro Yamada : > > > What about drivers/net/ethernet/lantiq_etop.c ? > > Nothing complained about it. I guess there is a build-bot for alpha, but none >

Re: [PATCH v2] kbuild: enforce -Werror=unused-result

2021-03-25 Thread Masahiro Yamada
his as a warning is OK. The same problem happens when you add a new __must_check annotation. You end up with fixing all the call-sites in advance. -- Best Regards Masahiro Yamada

[tip: x86/cleanups] x86/syscalls: Fix -Wmissing-prototypes warnings from COND_SYSCALL()

2021-03-25 Thread tip-bot2 for Masahiro Yamada
The following commit has been merged into the x86/cleanups branch of tip: Commit-ID: 7dfe553affd0d003c7535b7ba60d09193471ea9d Gitweb: https://git.kernel.org/tip/7dfe553affd0d003c7535b7ba60d09193471ea9d Author:Masahiro Yamada AuthorDate:Mon, 01 Mar 2021 22:15:26 +09:00

Re: [PATCH 1/7] x86/syscalls: fix -Wmissing-prototypes warnings from COND_SYSCALL()

2021-03-25 Thread Masahiro Yamada
ase? > Thanks, > Mickaël > > On 01/03/2021 14:15, Masahiro Yamada wrote: > > Building kernel/sys_ni.c with W=1 emits tons of -Wmissing-prototypes > > warnings. > > > > $ make W=1 kernel/sys_ni.o > > [ snip ] > > CC kernel/sys_ni.o > &

Re: [PATCH 2/2] streamline_config.pl: Add softtabstop=4 for vim users

2021-03-25 Thread Masahiro Yamada
On Thu, Mar 25, 2021 at 10:50 PM Steven Rostedt wrote: > > On Thu, 25 Mar 2021 15:20:13 +0900 > Masahiro Yamada wrote: > > > > > The root cause of inconsistency is that > > you mix up space-indentation and tab-indentation. > > I do not know if it is a standard

Re: [PATCH v2] editorconfig: Add automatic editor configuration file

2021-03-25 Thread Masahiro Yamada
python3' at the very top line. This is sensible for tools that interface to users. Users have no interest in which language is used internally. As far as I test this patch on Emacs, it follows the rule of [*] rather than [*.{pl,pm,py,tc,json,tc}]. This is the correct behavior but not what we want in general. I do not mean I am negative to this patch. Rather, I very much like this patch, but I just wondered how this case could be handled. I found this: https://github.com/editorconfig/editorconfig/issues/404 I did not read through it, though. -- Best Regards Masahiro Yamada

Re: [PATCH 2/2] streamline_config.pl: Add softtabstop=4 for vim users

2021-03-25 Thread Masahiro Yamada
On Wed, Mar 24, 2021 at 10:54 PM Steven Rostedt wrote: > > On Wed, 24 Mar 2021 15:01:13 +0900 > Masahiro Yamada wrote: > > > On Tue, Mar 23, 2021 at 6:40 AM Steven Rostedt wrote: > > > > > > From: "Steven Rostedt (VMware)" > > > &g

Re: [PATCH 01/13] kconfig: split randconfig setup code into set_randconfig_seed()

2021-03-24 Thread Masahiro Yamada
On Sun, Mar 14, 2021 at 4:48 AM Masahiro Yamada wrote: > > This code is too big to be placed in the switch statement. > > Move the code into a new helper function. I slightly refactor the code > without changing the behavior. > > Signed-off-by: Masahiro Yamada > --- All

Re: [PATCH] kconfig: use true and false for bool variable

2021-03-24 Thread Masahiro Yamada
3,7 +33,7 @@ static bool is_dir(const char *path) > struct stat st; > > if (stat(path, )) > - return 0; > + return false; > > return S_ISDIR(st.st_mode); > } > -- > 1.8.3.1 > -- Best Regards Masahiro Yamada

[PATCH] arm64: move --fix-cortex-a53-843419 linker test to Kconfig

2021-03-24 Thread Masahiro Yamada
over again. Reported-by: Nathan Chancellor Signed-off-by: Masahiro Yamada --- I was not sure what the preferred CONFIG option name is. Please suggest a one if you have a better idea. arch/arm64/Kconfig | 3 +++ arch/arm64/Makefile | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-)

Re: [PATCH] scripts: Fix incremental build header re-generation

2021-03-24 Thread Masahiro Yamada
On Thu, Mar 18, 2021 at 11:55 AM Jeevan Shriram wrote: > > > On 3/1/2021 7:36 PM, Masahiro Yamada wrote: > > On Mon, Mar 1, 2021 at 11:23 PM Jeevan Shriram > > wrote: > >> compile.h and autoconf.h are ignored when checking headers sha as they > >> a

Re: [PATCH 2/2] streamline_config.pl: Add softtabstop=4 for vim users

2021-03-24 Thread Masahiro Yamada
t;\n"; > } > } > + > +# vim: softtabstop=4 > -- > 2.30.1 > > -- Best Regards Masahiro Yamada

[PATCH] treewide: remove editor modelines and cruft

2021-03-23 Thread Masahiro Yamada
-1-da...@kdrag0n.dev/ Signed-off-by: Masahiro Yamada --- You might wonder if I worked on this huge patch manually or generated it by a tool. I wrote a Python script to generate this patch, but not from a scratch. I contributed a similar tool to U-Boot some years ago. (https://github.com/

Re: [PATCH 4/4] kbuild: include Makefile.compiler only when compiler is required

2021-03-18 Thread Masahiro Yamada
(CC: Will and ARM ML) On Fri, Mar 19, 2021 at 6:14 AM Nathan Chancellor wrote: > > On Sun, Feb 28, 2021 at 03:10:28PM +0900, Masahiro Yamada wrote: > > Since commit f2f02ebd8f38 ("kbuild: improve cc-option to clean up all > > temporary files"), running 'make kernelve

Re: [PATCH RESEND] gcc-plugins: avoid errors with -std=gnu++11 on old gcc

2021-03-18 Thread Masahiro Yamada
was: GCC_FLAVOR = $(call cc-ifversion, -ge, 1100, 11, 98) instead of GCC_FLAVOR = $(call cc-ifversion, -ge, 600, 11, 98) So, this patch is also requiring to cover two standards: GCC_VERSION >= 11 : -std=gnu++11 GCC_VERSION < 11 : -std=gnu++98 -- Best Regards Masahiro Yamada

Re: [PATCH v2 1/2] Makefile: Remove '--gcc-toolchain' flag

2021-03-16 Thread Masahiro Yamada
On Tue, Mar 16, 2021 at 1:42 AM Sedat Dilek wrote: > > On Mon, Mar 15, 2021 at 5:22 PM Masahiro Yamada wrote: > > > > On Wed, Mar 10, 2021 at 5:59 AM Nathan Chancellor wrote: > > > > > > This flag was originally added to allow clang to find the GNU cros

Re: [PATCH v2 2/3] kbuild: check the minimum assembler version in Kconfig

2021-03-16 Thread Masahiro Yamada
On Tue, Mar 16, 2021 at 1:14 AM Masahiro Yamada wrote: > > Documentation/process/changes.rst defines the minimum assembler version > (binutils version), but we have never checked it in the build time. > > Kbuild never invokes 'as' directly because all assembly files in the > k

Re: [PATCH V11 3/5] kbuild: Allow .dtso format for overlay source files

2021-03-15 Thread Masahiro Yamada
/overlay_gpio_01.dts drivers/of/unittest-data/overlay_10.dts drivers/of/unittest-data/overlay_7.dts drivers/of/unittest-data/overlay_bad_phandle.dts drivers/of/unittest-data/overlay_3.dts drivers/of/unittest-data/overlay_6.dts drivers/of/unittest-data/overlay_8.dts drivers/of/unittest-data/overlay_12.dts drivers/of/unittest-data/overlay_gpio_02a.dts drivers/of/unittest-data/overlay_gpio_02b.dts drivers/of/unittest-data/overlay_4.dts drivers/of/unittest-data/overlay.dts drivers/of/unittest-data/overlay_9.dts drivers/of/unittest-data/overlay_2.dts drivers/of/unittest-data/overlay_15.dts drivers/of/unittest-data/overlay_base.dts drivers/of/unittest-data/overlay_13.dts -- Best Regards Masahiro Yamada

Re: [PATCH] docs: kbuild: Fix a typo in the file Kconfig.recursion-issue-02

2021-03-15 Thread Masahiro Yamada
s, ie, some drivers use "depends on" while others > -- > 2.26.2 > -- Best Regards Masahiro Yamada

Re: [PATCH v2 1/2] Makefile: Remove '--gcc-toolchain' flag

2021-03-15 Thread Masahiro Yamada
..) > -endif > -ifneq ($(GCC_TOOLCHAIN),) > -CLANG_FLAGS+= --gcc-toolchain=$(GCC_TOOLCHAIN) > endif > ifneq ($(LLVM_IAS),1) > CLANG_FLAGS+= -no-integrated-as > > base-commit: a38fd8748464831584a19438cbb3082b5a2dab15 > -- > 2.31.0.rc1 > -- Best Regards Masahiro Yamada

[PATCH v2 2/3] kbuild: check the minimum assembler version in Kconfig

2021-03-15 Thread Masahiro Yamada
build/20210307044253.v3h47ucq6ng25iay@archlinux-ax161/ Signed-off-by: Masahiro Yamada --- Changes in v2: - Check -integrated-as option instead of error message. - Add LC_ALL=C just in case. The Italian locale did not tweak the message from 'as --version' but we never know what wo

[PATCH v2 3/3] kbuild: dwarf: use AS_VERSION instead of test_dwarf5_support.sh

2021-03-15 Thread Masahiro Yamada
for full support) - clang + gnu as-> requires binutils 2.35.2+ - clang + integrated as -> OK Signed-off-by: Masahiro Yamada Reviewed-by: Nathan Chancellor --- Changes in v2: - fix typos - simplify the dependency expression lib/Kconfig.debug |

[PATCH v2 1/3] kbuild: collect minimum tool versions into scripts/min-tool-version.sh

2021-03-15 Thread Masahiro Yamada
-off-by: Masahiro Yamada Reviewed-by: Nathan Chancellor Acked-by: Miguel Ojeda Tested-by: Sedat Dilek --- Changes in v2: - Use case ... esac scripts/cc-version.sh | 20 +-- scripts/ld-version.sh | 11 --- scripts/min-tool-version.sh | 39

Re: [PATCH 07/13] kconfig: move conf_set_all_new_symbols() to conf.c

2021-03-15 Thread Masahiro Yamada
On Mon, Mar 15, 2021 at 7:07 PM Boris Kolpackov wrote: > > Masahiro Yamada writes: > > > This function is only used in conf.c. Move it there together with the > > randomize_choice_values() helper. > > > > [...] > > > > diff --git a/scripts/kc

[PATCH] kbuild: replace sed with $(subst ) or $(patsubst )

2021-03-13 Thread Masahiro Yamada
-off-by: Masahiro Yamada --- Documentation/devicetree/bindings/Makefile | 2 +- Makefile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/Makefile b/Documentation/devicetree/bindings/Makefile index

Re: Why is the bit size different between a syscall and its wrapper?

2021-03-13 Thread Masahiro Yamada
Willy, Thanks for the explanation. On Fri, Mar 12, 2021 at 12:27 PM Willy Tarreau wrote: > > On Fri, Mar 12, 2021 at 11:48:11AM +0900, Masahiro Yamada wrote: > > Hi. > > > > I think I am missing something, but > > is there any particular reason to > &

[PATCH 13/13] kconfig: change "modules" from sub-option to first-level attribute

2021-03-13 Thread Masahiro Yamada
Now "modules" is the only member of the "option" property. Remove "option", and move "modules" to the top level property. Signed-off-by: Masahiro Yamada --- Documentation/kbuild/kconfig-language.rst | 14 -- init/Kconfig

[PATCH 11/13] kconfig: do not use allnoconfig_y option

2021-03-13 Thread Masahiro Yamada
-by: Masahiro Yamada --- init/Kconfig| 1 - kernel/configs/tiny-base.config | 1 + scripts/kconfig/Makefile| 3 ++- 3 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 kernel/configs/tiny-base.config diff --git a/init/Kconfig b/init/Kconfig index

[PATCH 09/13] kconfig: change defconfig_list option to environment variable

2021-03-13 Thread Masahiro Yamada
out the input files. They must be fixed values since these are searched for and loaded in the parse stage. It is an ugly hack, and should not exist in the first place. Providing this features as an environment variable is a saner approach. Signed-off-by: Masahiro Yamada --- Documentation/kb

[PATCH 08/13] kconfig: move JUMP_NB to mconf.c

2021-03-13 Thread Masahiro Yamada
This macro is only used in mconf.c. Signed-off-by: Masahiro Yamada --- scripts/kconfig/expr.h | 2 -- scripts/kconfig/mconf.c | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/kconfig/expr.h b/scripts/kconfig/expr.h index 5c3443692f34..bbca80a0dc24 100644

[PATCH 05/13] kconfig: remove assignment for Kconfig file

2021-03-13 Thread Masahiro Yamada
Pass av[optind] to conf_parse() directly. Signed-off-by: Masahiro Yamada --- scripts/kconfig/conf.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c index 9ebc1acaf1ae..42d35da86604 100644 --- a/scripts/kconfig/conf.c +++ b

[PATCH 07/13] kconfig: move conf_set_all_new_symbols() to conf.c

2021-03-13 Thread Masahiro Yamada
This function is only used in conf.c. Move it there together with the randomize_choice_values() helper. Signed-off-by: Masahiro Yamada --- scripts/kconfig/conf.c | 183 + scripts/kconfig/confdata.c | 176 --- scripts

[PATCH 03/13] kconfig: add long options --help and --silent

2021-03-13 Thread Masahiro Yamada
They are long options for -h and -s, respectively. Signed-off-by: Masahiro Yamada --- scripts/kconfig/conf.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c index dc1a67fd35a9..aac76acfd100 100644 --- a/scripts/kconfig/conf.c +++ b/scripts

[PATCH 12/13] kconfig: remove allnoconfig_y option

2021-03-13 Thread Masahiro Yamada
Now that the only user CONFIG_EMBEDDED has stopped using this option, remove it entirely. Signed-off-by: Masahiro Yamada --- Documentation/kbuild/kconfig-language.rst | 4 scripts/kconfig/conf.c| 5 + scripts/kconfig/expr.h| 3 --- scripts

[PATCH 04/13] kconfig: add help messages for --help (-h) and --silent (-s)

2021-03-13 Thread Masahiro Yamada
Add missing options and make the help message more readable. Signed-off-by: Masahiro Yamada --- scripts/kconfig/conf.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c index aac76acfd100..9ebc1acaf1ae 100644

[PATCH 06/13] kconfig: move conf_rewrite_mod_or_yes() to conf.c

2021-03-13 Thread Masahiro Yamada
This function is only used in conf.c. Signed-off-by: Masahiro Yamada --- scripts/kconfig/conf.c | 15 +++ scripts/kconfig/confdata.c | 15 --- scripts/kconfig/lkc.h | 1 - 3 files changed, 15 insertions(+), 16 deletions(-) diff --git a/scripts/kconfig/conf.c

[PATCH 01/13] kconfig: split randconfig setup code into set_randconfig_seed()

2021-03-13 Thread Masahiro Yamada
This code is too big to be placed in the switch statement. Move the code into a new helper function. I slightly refactor the code without changing the behavior. Signed-off-by: Masahiro Yamada --- scripts/kconfig/conf.c | 54 -- 1 file changed, 31

<    1   2   3   4   5   6   7   8   9   10   >