1. 24 Oct, 2021 2 commits
  2. 13 Oct, 2021 1 commit
  3. 12 Oct, 2021 2 commits
  4. 11 Oct, 2021 9 commits
  5. 01 Oct, 2021 1 commit
  6. 29 Sep, 2021 2 commits
  7. 25 Sep, 2021 1 commit
    • Ariel Marcovitch's avatar
      kconfig: Create links to main menu items in search · d05377e1
      Ariel Marcovitch authored
      When one searches for a main menu item, links aren't created for it like
      with the rest of the symbols.
      
      This happens because we trace the item until we get to the rootmenu, but
      we don't include it in the path of the item. The rationale was probably
      that we don't want to show the main menu in the path of all items,
      because it is redundant.
      
      However, when an item has only the rootmenu in its path it should be
      included, because this way the user can jump to its location.
      
      Add a 'Main menu' entry in the 'Location:' section for the kconfig
      items.
      
      This makes the 'if (i > 0)' superfluous because each item with prompt
      will have at least one menu in its path.
      Signed-off-by: default avatarAriel Marcovitch <arielmarcovitch@gmail.com>
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      d05377e1
  8. 22 Sep, 2021 8 commits
    • Masahiro Yamada's avatar
      kbuild: reuse $(cmd_objtool) for cmd_cc_lto_link_modules · 90a35349
      Masahiro Yamada authored
      For CONFIG_LTO_CLANG=y, the objtool processing is not possible at the
      compilation, hence postponed by the link time.
      
      Reuse $(cmd_objtool) for CONFIG_LTO_CLANG=y by defining objtool-enabled
      properly.
      
      For CONFIG_LTO_CLANG=y:
      
        objtool-enabled is off for %.o compilation
        objtool-enabled is on  for %.lto link
      
      For CONFIG_LTO_CLANG=n:
      
        objtool-enabled is on for %.o compilation
            (but, it depends on OBJECT_FILE_NON_STANDARD)
      
      Set part-of-module := y for %.lto.o to avoid repeating --module.
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      Reviewed-by: default avatarKees Cook <keescook@chromium.org>
      Acked-by: default avatarJosh Poimboeuf <jpoimboe@redhat.com>
      90a35349
    • Masahiro Yamada's avatar
      kbuild: detect objtool update without using .SECONDEXPANSION · ef62588c
      Masahiro Yamada authored
      Redo commit 8852c552 ("kbuild: Fix objtool dependency for
      'OBJECT_FILES_NON_STANDARD_<obj> := n'") to add the objtool
      dependency in a cleaner way.
      
      Using .SECONDEXPANSION ends up with unreadable code due to escaped
      dollars. Also, it is not efficient because the second half of
      Makefile.build is parsed twice every time.
      
      Append the objtool dependency to the *.cmd files at the build time.
      
      This is what fixdep and gen_ksymdeps.sh already do. So, following the
      same pattern seems a natural solution.
      
      This allows us to drop $$(objtool_dep) entirely.
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      Reviewed-by: default avatarKees Cook <keescook@chromium.org>
      Reviewed-by: default avatarNick Desaulniers <ndesaulniers@google.com>
      Acked-by: default avatarJosh Poimboeuf <jpoimboe@redhat.com>
      ef62588c
    • Masahiro Yamada's avatar
      kbuild: factor out OBJECT_FILES_NON_STANDARD check into a macro · 918a6b7f
      Masahiro Yamada authored
      The OBJECT_FILES_NON_STANDARD check is quite long.
      
      Factor it out into a new macro, objtool-enabled, to not repeat it.
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      Reviewed-by: default avatarNick Desaulniers <ndesaulniers@google.com>
      Reviewed-by: default avatarKees Cook <keescook@chromium.org>
      Acked-by: default avatarJosh Poimboeuf <jpoimboe@redhat.com>
      918a6b7f
    • Masahiro Yamada's avatar
      kbuild: store the objtool command in *.cmd files · 92594d56
      Masahiro Yamada authored
      objtool_dep includes include/config/{ORC_UNWINDER,STACK_VALIDATION}
      so that all the objects are rebuilt when CONFIG_ORC_UNWINDER or
      CONFIG_STACK_VALIDATION is toggled.
      
      BTW, the correct option name is not CONFIG_ORC_UNWINDER, but
      CONFIG_UNWINDER_ORC. Commit 11af8474 ("x86/unwind: Rename
      unwinder config options to 'CONFIG_UNWINDER_*'") missed to
      adjust this part. So, this dependency has been broken for a
      long time.
      
      As you can see in 'objtool_args', there are more CONFIG options
      that affect the objtool command line.
      
      Adding more and more include/config/* is ugly and unmaintainable.
      
      Another issue is that non-standard objects are needlessly rebuilt.
      Objects specified as OBJECT_FILES_NON_STANDARD is not processed by
      objtool, but they are rebuilt anyway when CONFIG_STACK_VALIDATION
      is toggled. This is not a big deal, but better to fix.
      
      A cleaner and more precise fix is to include the objtool command in
      *.cmd files so any command change is naturally detected by if_change.
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      Reviewed-by: default avatarNick Desaulniers <ndesaulniers@google.com>
      Reviewed-by: default avatarKees Cook <keescook@chromium.org>
      Acked-by: default avatarJosh Poimboeuf <jpoimboe@redhat.com>
      92594d56
    • Masahiro Yamada's avatar
      kbuild: rename __objtool_obj and reuse it for cmd_cc_lto_link_modules · 5c4859e7
      Masahiro Yamada authored
      Rename __objtool_obj to objtool, and move it out of the
      'ifndef CONFIG_LTO_CLANG' conditional, so it can be used for
      cmd_cc_lto_link_modules as well.
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      Reviewed-by: default avatarNick Desaulniers <ndesaulniers@google.com>
      Reviewed-by: default avatarKees Cook <keescook@chromium.org>
      Acked-by: default avatarJosh Poimboeuf <jpoimboe@redhat.com>
      5c4859e7
    • Masahiro Yamada's avatar
      kbuild: move objtool_args back to scripts/Makefile.build · 8f0c32c7
      Masahiro Yamada authored
      Commit b1a1a1a0 ("kbuild: lto: postpone objtool") moved objtool_args
      to Makefile.lib, so the arguments can be used in Makefile.modfinal as
      well as Makefile.build.
      
      With commit 850ded46 ("kbuild: Fix TRIM_UNUSED_KSYMS with
      LTO_CLANG"), module LTO linking came back to scripts/Makefile.build
      again.
      
      So, there is no more reason to keep objtool_args in a separate file.
      
      Get it back to the original place, close to the objtool command.
      
      Remove the stale comment too.
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      Reviewed-by: default avatarKees Cook <keescook@chromium.org>
      Acked-by: default avatarJosh Poimboeuf <jpoimboe@redhat.com>
      8f0c32c7
    • Alexey Dobriyan's avatar
      isystem: delete global -isystem compile option · 04e85bbf
      Alexey Dobriyan authored
      Further isolate kernel from userspace, prevent accidental inclusion of
      undesireable headers, mainly float.h and stdatomic.h.
      
      nds32 keeps -isystem globally due to intrinsics used in entrenched header.
      
      -isystem is selectively reenabled for some files, again, for intrinsics.
      
      Compile tested on:
      
      hexagon-defconfig hexagon-allmodconfig
      alpha-allmodconfig alpha-allnoconfig alpha-defconfig arm64-allmodconfig
      arm64-allnoconfig arm64-defconfig arm-am200epdkit arm-aspeed_g4
      arm-aspeed_g5 arm-assabet arm-at91_dt arm-axm55xx arm-badge4 arm-bcm2835
      arm-cerfcube arm-clps711x arm-cm_x300 arm-cns3420vb arm-colibri_pxa270
      arm-colibri_pxa300 arm-collie arm-corgi arm-davinci_all arm-dove
      arm-ep93xx arm-eseries_pxa arm-exynos arm-ezx arm-footbridge arm-gemini
      arm-h3600 arm-h5000 arm-hackkit arm-hisi arm-imote2 arm-imx_v4_v5
      arm-imx_v6_v7 arm-integrator arm-iop32x arm-ixp4xx arm-jornada720
      arm-keystone arm-lart arm-lpc18xx arm-lpc32xx arm-lpd270 arm-lubbock
      arm-magician arm-mainstone arm-milbeaut_m10v arm-mini2440 arm-mmp2
      arm-moxart arm-mps2 arm-multi_v4t arm-multi_v5 arm-multi_v7 arm-mv78xx0
      arm-mvebu_v5 arm-mvebu_v7 arm-mxs arm-neponset arm-netwinder arm-nhk8815
      arm-omap1 arm-omap2plus arm-orion5x arm-oxnas_v6 arm-palmz72 arm-pcm027
      arm-pleb arm-pxa arm-pxa168 arm-pxa255-idp arm-pxa3xx arm-pxa910
      arm-qcom arm-realview arm-rpc arm-s3c2410 arm-s3c6400 arm-s5pv210
      arm-sama5 arm-shannon arm-shmobile arm-simpad arm-socfpga arm-spear13xx
      arm-spear3xx arm-spear6xx arm-spitz arm-stm32 arm-sunxi arm-tct_hammer
      arm-tegra arm-trizeps4 arm-u8500 arm-versatile arm-vexpress arm-vf610m4
      arm-viper arm-vt8500_v6_v7 arm-xcep arm-zeus csky-allmodconfig
      csky-allnoconfig csky-defconfig h8300-edosk2674 h8300-h8300h-sim
      h8300-h8s-sim i386-allmodconfig i386-allnoconfig i386-defconfig
      ia64-allmodconfig ia64-allnoconfig ia64-bigsur ia64-generic ia64-gensparse
      ia64-tiger ia64-zx1 m68k-amcore m68k-amiga m68k-apollo m68k-atari
      m68k-bvme6000 m68k-hp300 m68k-m5208evb m68k-m5249evb m68k-m5272c3
      m68k-m5275evb m68k-m5307c3 m68k-m5407c3 m68k-m5475evb m68k-mac
      m68k-multi m68k-mvme147 m68k-mvme16x m68k-q40 m68k-stmark2 m68k-sun3
      m68k-sun3x microblaze-allmodconfig microblaze-allnoconfig microblaze-mmu
      mips-ar7 mips-ath25 mips-ath79 mips-bcm47xx mips-bcm63xx mips-bigsur
      mips-bmips_be mips-bmips_stb mips-capcella mips-cavium_octeon mips-ci20
      mips-cobalt mips-cu1000-neo mips-cu1830-neo mips-db1xxx mips-decstation
      mips-decstation_64 mips-decstation_r4k mips-e55 mips-fuloong2e
      mips-gcw0 mips-generic mips-gpr mips-ip22 mips-ip27 mips-ip28 mips-ip32
      mips-jazz mips-jmr3927 mips-lemote2f mips-loongson1b mips-loongson1c
      mips-loongson2k mips-loongson3 mips-malta mips-maltaaprp mips-malta_kvm
      mips-malta_qemu_32r6 mips-maltasmvp mips-maltasmvp_eva mips-maltaup
      mips-maltaup_xpa mips-mpc30x mips-mtx1 mips-nlm_xlp mips-nlm_xlr
      mips-omega2p mips-pic32mzda mips-pistachio mips-qi_lb60 mips-rb532
      mips-rbtx49xx mips-rm200 mips-rs90 mips-rt305x mips-sb1250_swarm
      mips-tb0219 mips-tb0226 mips-tb0287 mips-vocore2 mips-workpad mips-xway
      nds32-allmodconfig nds32-allnoconfig nds32-defconfig nios2-10m50
      nios2-3c120 nios2-allmodconfig nios2-allnoconfig openrisc-allmodconfig
      openrisc-allnoconfig openrisc-or1klitex openrisc-or1ksim
      openrisc-simple_smp parisc-allnoconfig parisc-generic-32bit
      parisc-generic-64bit powerpc-acadia powerpc-adder875 powerpc-akebono
      powerpc-amigaone powerpc-arches powerpc-asp8347 powerpc-bamboo
      powerpc-bluestone powerpc-canyonlands powerpc-cell powerpc-chrp32
      powerpc-cm5200 powerpc-currituck powerpc-ebony powerpc-eiger
      powerpc-ep8248e powerpc-ep88xc powerpc-fsp2 powerpc-g5 powerpc-gamecube
      powerpc-ge_imp3a powerpc-holly powerpc-icon powerpc-iss476-smp
      powerpc-katmai powerpc-kilauea powerpc-klondike powerpc-kmeter1
      powerpc-ksi8560 powerpc-linkstation powerpc-lite5200b powerpc-makalu
      powerpc-maple powerpc-mgcoge powerpc-microwatt powerpc-motionpro
      powerpc-mpc512x powerpc-mpc5200 powerpc-mpc7448_hpc2 powerpc-mpc8272_ads
      powerpc-mpc8313_rdb powerpc-mpc8315_rdb powerpc-mpc832x_mds
      powerpc-mpc832x_rdb powerpc-mpc834x_itx powerpc-mpc834x_itxgp
      powerpc-mpc834x_mds powerpc-mpc836x_mds powerpc-mpc836x_rdk
      powerpc-mpc837x_mds powerpc-mpc837x_rdb powerpc-mpc83xx
      powerpc-mpc8540_ads powerpc-mpc8560_ads powerpc-mpc85xx_cds
      powerpc-mpc866_ads powerpc-mpc885_ads powerpc-mvme5100 powerpc-obs600
      powerpc-pasemi powerpc-pcm030 powerpc-pmac32 powerpc-powernv
      powerpc-ppa8548 powerpc-ppc40x powerpc-ppc44x powerpc-ppc64
      powerpc-ppc64e powerpc-ppc6xx powerpc-pq2fads powerpc-ps3
      powerpc-pseries powerpc-rainier powerpc-redwood powerpc-sam440ep
      powerpc-sbc8548 powerpc-sequoia powerpc-skiroot powerpc-socrates
      powerpc-storcenter powerpc-stx_gp3 powerpc-taishan powerpc-tqm5200
      powerpc-tqm8540 powerpc-tqm8541 powerpc-tqm8548 powerpc-tqm8555
      powerpc-tqm8560 powerpc-tqm8xx powerpc-walnut powerpc-warp powerpc-wii
      powerpc-xes_mpc85xx riscv-allmodconfig riscv-allnoconfig riscv-nommu_k210
      riscv-nommu_k210_sdcard riscv-nommu_virt riscv-rv32 s390-allmodconfig
      s390-allnoconfig s390-debug s390-zfcpdump sh-ap325rxa sh-apsh4a3a
      sh-apsh4ad0a sh-dreamcast sh-ecovec24 sh-ecovec24-romimage sh-edosk7705
      sh-edosk7760 sh-espt sh-hp6xx sh-j2 sh-kfr2r09 sh-kfr2r09-romimage
      sh-landisk sh-lboxre2 sh-magicpanelr2 sh-microdev sh-migor sh-polaris
      sh-r7780mp sh-r7785rp sh-rsk7201 sh-rsk7203 sh-rsk7264 sh-rsk7269
      sh-rts7751r2d1 sh-rts7751r2dplus sh-sdk7780 sh-sdk7786 sh-se7206 sh-se7343
      sh-se7619 sh-se7705 sh-se7712 sh-se7721 sh-se7722 sh-se7724 sh-se7750
      sh-se7751 sh-se7780 sh-secureedge5410 sh-sh03 sh-sh2007 sh-sh7710voipgw
      sh-sh7724_generic sh-sh7757lcr sh-sh7763rdp sh-sh7770_generic sh-sh7785lcr
      sh-sh7785lcr_32bit sh-shmin sh-shx3 sh-titan sh-ul2 sh-urquell
      sparc-allmodconfig sparc-allnoconfig sparc-sparc32 sparc-sparc64
      um-i386-allmodconfig um-i386-allnoconfig um-i386-defconfig
      um-x86_64-allmodconfig um-x86_64-allnoconfig x86_64-allmodconfig
      x86_64-allnoconfig x86_64-defconfig xtensa-allmodconfig xtensa-allnoconfig
      xtensa-audio_kc705 xtensa-cadence_csp xtensa-common xtensa-generic_kc705
      xtensa-iss xtensa-nommu_kc705 xtensa-smp_lx200 xtensa-virt
      xtensa-xip_kc705
      
      Tested-by: Nathan Chancellor <nathan@kernel.org> # build (hexagon)
      Signed-off-by: default avatarAlexey Dobriyan <adobriyan@gmail.com>
      Acked-by: default avatarArd Biesheuvel <ardb@kernel.org>
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      04e85bbf
    • Masahiro Yamada's avatar
      nios2: move the install rule to arch/nios2/Makefile · 89b4db61
      Masahiro Yamada authored
      Currently, the install target in arch/nios2/Makefile descends into
      arch/nios2/boot/Makefile to invoke the shell script, but it is no
      good reason to do so.
      
      arch/nios2/Makefile can run the shell script directly.
      Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
      89b4db61
  9. 20 Sep, 2021 2 commits
    • Linus Torvalds's avatar
      Linux 5.15-rc2 · e4e737bb
      Linus Torvalds authored
      e4e737bb
    • Linus Torvalds's avatar
      pci_iounmap'2: Electric Boogaloo: try to make sense of it all · 316e8d79
      Linus Torvalds authored
      Nathan Chancellor reports that the recent change to pci_iounmap in
      commit 9caea000 ("parisc: Declare pci_iounmap() parisc version only
      when CONFIG_PCI enabled") causes build errors on arm64.
      
      It took me about two hours to convince myself that I think I know what
      the logic of that mess of #ifdef's in the <asm-generic/io.h> header file
      really aim to do, and rewrite it to be easier to follow.
      
      Famous last words.
      
      Anyway, the code has now been lifted from that grotty header file into
      lib/pci_iomap.c, and has fairly extensive comments about what the logic
      is.  It also avoids indirecting through another confusing (and badly
      named) helper function that has other preprocessor config conditionals.
      
      Let's see what odd architecture did something else strange in this area
      to break things.  But my arm64 cross build is clean.
      
      Fixes: 9caea000 ("parisc: Declare pci_iounmap() parisc version only when CONFIG_PCI enabled")
      Reported-by: default avatarNathan Chancellor <nathan@kernel.org>
      Cc: Helge Deller <deller@gmx.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Guenter Roeck <linux@roeck-us.net>
      Cc: Ulrich Teichert <krypton@ulrich-teichert.org>
      Cc: James Bottomley <James.Bottomley@hansenpartnership.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      316e8d79
  10. 19 Sep, 2021 12 commits