diff options
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/Makefile.extrawarn | 3 | ||||
-rw-r--r-- | scripts/Makefile.lib | 4 | ||||
-rwxr-xr-x | scripts/checkpatch.pl | 10 | ||||
-rwxr-xr-x | scripts/event_dump.py | 2 |
4 files changed, 14 insertions, 5 deletions
diff --git a/scripts/Makefile.extrawarn b/scripts/Makefile.extrawarn index 7d39b27d24a..f687515fc79 100644 --- a/scripts/Makefile.extrawarn +++ b/scripts/Makefile.extrawarn @@ -13,6 +13,9 @@ KBUILD_CFLAGS += $(call cc-disable-warning, packed-not-aligned) +KBUILD_CPPFLAGS-$(CONFIG_WERROR) += -Werror +KBUILD_CPPFLAGS += $(KBUILD_CPPFLAGS-y) + ifeq ("$(origin W)", "command line") export KBUILD_ENABLE_EXTRA_GCC_CHECKS := $(W) endif diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index 18993435eae..275c308154b 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib @@ -513,8 +513,8 @@ $(obj)/%_efi.S: $(obj)/%.efi $(call cmd,S_efi) quiet_cmd_efi_objcopy = OBJCOPY $@ -cmd_efi_objcopy = $(OBJCOPY) -j .header -j .text -j .sdata -j .data -j \ - .dynamic -j .dynsym -j .rel* -j .rela* -j .reloc \ +cmd_efi_objcopy = $(OBJCOPY) -j .header -j .text -j .sdata -j .data \ + -j .dynamic -j .dynstr -j .dynsym -j .rel* -j .reloc \ $(if $(EFI_TARGET),$(EFI_TARGET),-O binary) $^ $@ $(obj)/%.efi: $(obj)/%_efi.so diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index b8eb57f38c7..414019c5b89 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -2692,6 +2692,12 @@ sub u_boot_line { ERROR("PRE_SCHEMA", "Driver model schema uses 'bootph-...' tags now\n" . $herecurr); } + + # Do not allow CONFIG_xPL_BUILD in device trees + if ($realfile =~ /\.dtsi?$/ && $line =~ /^\+.*CONFIG_(X|S|T|V)PL_BUILD.*/) { + ERROR("CONFIG_xPL_BUILD", + "Do not use CONFIG_xPL_BUILD in device trees\n" . $herecurr); + } } sub exclude_global_initialisers { @@ -7205,8 +7211,8 @@ sub process { # check for IS_ENABLED() without CONFIG_<FOO> ($rawline for comments too) if ($rawline =~ /\bIS_ENABLED\s*\(\s*(\w+)\s*\)/ && $1 !~ /^${CONFIG_}/) { - WARN("IS_ENABLED_CONFIG", - "IS_ENABLED($1) is normally used as IS_ENABLED(${CONFIG_}$1)\n" . $herecurr); + ERROR("IS_ENABLED_CONFIG", + "IS_ENABLED($1) must be used as IS_ENABLED(${CONFIG_}$1)\n" . $herecurr); } # check for #if defined CONFIG_<FOO> || defined CONFIG_<FOO>_MODULE diff --git a/scripts/event_dump.py b/scripts/event_dump.py index 24dfe2bda91..61bb3a8eb92 100755 --- a/scripts/event_dump.py +++ b/scripts/event_dump.py @@ -107,7 +107,7 @@ def main(argv): Args: argv (list of str): List of program arguments, excluding arvg[0] """ - epilog = 'Show a list of even spies in a U-Boot EFL file' + epilog = 'Show a list of event spies in a U-Boot ELF file' parser = ArgumentParser(epilog=epilog) parser.add_argument('elf', type=str, help='ELF file to decode') parser.add_argument('-e', '--endian', type=str, default='auto', |