1. 05 Jun, 2021 4 commits
  2. 03 Jun, 2021 1 commit
  3. 22 May, 2021 4 commits
  4. 19 May, 2021 2 commits
    • Masahiro Yamada's avatar
      kbuild: generate Module.symvers only when vmlinux exists · d0736af8
      Masahiro Yamada authored
      [ Upstream commit 69bc8d38 ]
      
      The external module build shows the following warning if Module.symvers
      is missing in the kernel tree.
      
        WARNING: Symbol version dump "Module.symvers" is missing.
                 Modules may not have dependencies or modversions.
      
      I think this is an important heads-up because the resulting modules may
      not work as expected. This happens when you did not build the entire
      kernel tree, for example, you might have prepared the minimal setups
      for external modules by 'make defconfig && make modules_preapre'.
      
      A problem is that 'make modules' creates Module.symvers even without
      vmlinux. In this case, that warning is suppressed since Module.symvers
      already exists in spite of its incomplete content.
      
      The incomplete (i.e. invalid) Module.symvers should not be created.
      
      This commit changes the second pass of modpost to dump symbols into
      modules-only.symvers. The final Module.symvers is created by
      concaten...
      d0736af8
    • Mihai Moldovan's avatar
      kconfig: nconf: stop endless search loops · cc1956f8
      Mihai Moldovan authored
      [ Upstream commit 8c94b430 ]
      
      If the user selects the very first entry in a page and performs a
      search-up operation, or selects the very last entry in a page and
      performs a search-down operation that will not succeed (e.g., via
      [/]asdfzzz[Up Arrow]), nconf will never terminate searching the page.
      
      The reason is that in this case, the starting point will be set to -1
      or n, which is then translated into (n - 1) (i.e., the last entry of
      the page) or 0 (i.e., the first entry of the page) and finally the
      search begins. This continues to work fine until the index reaches 0 or
      (n - 1), at which point it will be decremented to -1 or incremented to
      n, but not checked against the starting point right away. Instead, it's
      wrapped around to the bottom or top again, after which the starting
      point check occurs... and naturally fails.
      
      My original implementation added another check for -1 before wrapping
      the running index variable around, but Masah...
      cc1956f8
  5. 28 Apr, 2021 1 commit
  6. 30 Mar, 2021 1 commit
  7. 09 Mar, 2021 1 commit
  8. 26 Feb, 2021 2 commits
  9. 17 Feb, 2021 2 commits
  10. 10 Feb, 2021 1 commit
  11. 23 Jan, 2021 1 commit
  12. 19 Jan, 2021 1 commit
  13. 12 Jan, 2021 1 commit
  14. 30 Dec, 2020 4 commits
  15. 06 Dec, 2020 1 commit
    • Masahiro Yamada's avatar
      kbuild: avoid split lines in .mod files · 7d32358b
      Masahiro Yamada authored
      "xargs echo" is not a safe way to remove line breaks because the input
      may exceed the command line limit and xargs may break it up into
      multiple invocations of echo. This should never happen because
      scripts/gen_autoksyms.sh expects all undefined symbols are placed in
      the second line of .mod files.
      
      One possible way is to replace "xargs echo" with
      "sed ':x;N;$!bx;s/\n/ /g'" or something, but I rewrote the code by
      using awk because it is more readable.
      
      This issue was reported by Sami Tolvanen; in his Clang LTO patch set,
      $(multi-used-m) is no longer an ELF object, but a thin archive that
      contains LLVM bitcode files. llvm-nm prints out symbols for each
      archive member separately, which results a lot of dupications, in some
      places, beyond the system-defined limit.
      
      This problem must be fixed irrespective of LTO, and we must ensure
      zero possibility of having this issue.
      
      Link: https://lkml.org/lkml/2020/12/1/1658
      
      Reported-by: default avatarSami Tolvanen <samitolvanen@google.com>
      Signed-off-by: Masahiro Yamada's avatarMasahiro Yamada <masahiroy@kernel.org>
      Reviewed-by: default avatarSami Tolvanen <samitolvanen@google.com>
      7d32358b
  16. 01 Dec, 2020 1 commit
  17. 24 Nov, 2020 1 commit
    • Arnd Bergmann's avatar
      Makefile.extrawarn: move -Wcast-align to W=3 · 095fbca0
      Arnd Bergmann authored and Masahiro Yamada's avatar Masahiro Yamada committed
      
      
      This warning behaves differently depending on the architecture
      and compiler. Using x86 gcc, we get no output at all because
      gcc knows the architecture can handle unaligned accesses.
      
      Using x86 clang, or gcc on an architecture that needs to
      manually deal with unaligned accesses, the build log is
      completely flooded with these warnings, as they are commonly
      invoked by inline functions of networking headers, e.g.
      
      include/linux/skbuff.h:1426:26: warning: cast increases required alignment of target type [-Wcast-align]
      
      The compiler is correct to point this out, as we are dealing
      with undefined behavior that does cause problems in practice,
      but there is also no good way to rewrite the code in commonly
      included headers to a safer method.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Reviewed-by: default avatarNathan Chancellor <natechancellor@gmail.com>
      Signed-off-by: Masahiro Yamada's avatarMasahiro Yamada <masahiroy@kernel.org>
      095fbca0
  18. 02 Nov, 2020 3 commits
  19. 30 Oct, 2020 8 commits