15 Oct, 2016

1 commit

  • Pull kbuild updates from Michal Marek:

    - EXPORT_SYMBOL for asm source by Al Viro.

    This does bring a regression, because genksyms no longer generates
    checksums for these symbols (CONFIG_MODVERSIONS). Nick Piggin is
    working on a patch to fix this.

    Plus, we are talking about functions like strcpy(), which rarely
    change prototypes.

    - Fixes for PPC fallout of the above by Stephen Rothwell and Nick
    Piggin

    - fixdep speedup by Alexey Dobriyan.

    - preparatory work by Nick Piggin to allow architectures to build with
    -ffunction-sections, -fdata-sections and --gc-sections

    - CONFIG_THIN_ARCHIVES support by Stephen Rothwell

    - fix for filenames with colons in the initramfs source by me.

    * 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild: (22 commits)
    initramfs: Escape colons in depfile
    ppc: there is no clear_pages to export
    powerpc/64: whitelist unresolved modversions CRCs
    kbuild: -ffunction-sections fix for archs with conflicting sections
    kbuild: add arch specific post-link Makefile
    kbuild: allow archs to select link dead code/data elimination
    kbuild: allow architectures to use thin archives instead of ld -r
    kbuild: Regenerate genksyms lexer
    kbuild: genksyms fix for typeof handling
    fixdep: faster CONFIG_ search
    ia64: move exports to definitions
    sparc32: debride memcpy.S a bit
    [sparc] unify 32bit and 64bit string.h
    sparc: move exports to definitions
    ppc: move exports to definitions
    arm: move exports to definitions
    s390: move exports to definitions
    m68k: move exports to definitions
    alpha: move exports to actual definitions
    x86: move exports to actual definitions
    ...

    Linus Torvalds
     

09 Sep, 2016

1 commit

  • Allow architectures to create arch/xxx/Makefile.postlink with targets
    for vmlinux, modules.ko, and clean, which will be invoked after final
    linking of vmlinux and modules.

    powerpc will use this to check vmlinux linker relocations for sanity,
    and may use it to fix up alternate instruction patch branch addresses.

    Signed-off-by: Nicholas Piggin
    Signed-off-by: Michal Marek

    Nicholas Piggin
     

19 Aug, 2016

1 commit

  • Improper menuconfig usage leads to empty menu entries.
    zconfdump() is able to reveal some real-life examples:
    - menuconfig VFIO_NOIOMMU
    - menuconfig RESET_CONTROLLER
    - menuconfig SND_ARM

    To avoid future occurrences of those, improve the menuconfig syntax
    description.

    Signed-off-by: Eugeniu Rosca
    Signed-off-by: Jonathan Corbet

    Eugeniu Rosca
     

07 Jul, 2016

1 commit

  • Track generated header files which aren't already in genhdr-y, alongside
    generic-y wrappers in the */include/generated/[uapi/]asm/ directories.
    Currently only x86 generates extra headers in these directories, for the
    purposes of enumerating system calls for different ABIs, and xen
    hypercalls.

    This will allow the asm-generic wrapper handling code to remove stale
    wrappers when files are removed from generic-y, without also removing
    these headers which are generated separately.

    Reported-by: kbuild test robot
    Signed-off-by: James Hogan
    Acked-by: Arnd Bergmann
    Cc: Jonathan Corbet
    Cc: linux-kbuild@vger.kernel.org
    Cc: linux-doc@vger.kernel.org
    Cc: Michal Marek
    Link: http://lkml.kernel.org/r/1466808144-23209-2-git-send-email-james.hogan@imgtec.com
    Signed-off-by: Thomas Gleixner

    James Hogan
     

10 May, 2016

2 commits


08 Oct, 2015

1 commit

  • Recursive dependency issues with kconfig are unavoidable due to
    some limitations with kconfig, since these issues are recurring
    provide a hint to the user how they can resolve these dependency
    issues and also document why such limitation exists.

    While at it also document a bit of future prospects of ways to
    enhance Kconfig, including providing formal semantics and evaluation
    of use of a SAT solver. If you're interested in this work or prospects
    of it check out the kconfig-sat project wiki [0] and mailing list [1].

    [0] http://kernelnewbies.org/KernelProjects/kconfig-sat
    [1] https://groups.google.com/d/forum/kconfig-sat

    Cc: Geert Uytterhoeven
    Cc: James Bottomley
    Cc: Josh Triplett
    Cc: Paul Bolle
    Cc: Herbert Xu
    Cc: Takashi Iwai
    Cc: "Yann E. MORIN"
    Cc: Jonathan Corbet
    Cc: Mate Soos
    Signed-off-by: Luis R. Rodriguez
    Signed-off-by: Michal Marek

    Luis R. Rodriguez
     

07 Aug, 2015

1 commit

  • We don't want this in the Kconfig since it might then get exposed in
    /proc/config.gz. So make it a parameter to Kbuild instead. This also
    means we don't have to jump through hoops to strip quotes from it, as
    we would if it was a config option.

    Signed-off-by: David Woodhouse
    Signed-off-by: David Howells
    Reviewed-by: Mimi Zohar

    David Woodhouse
     

06 Jul, 2015

1 commit

  • Since commit a1c48bb1 (Makefile: Fix unrecognized cross-compiler command
    line options), the arch Makefile is included earlier by the main
    Makefile, preventing the arc architecture to set its -O3 compiler
    option. Since there might be more use cases for an arch Makefile to
    fine-tune the options, add support for ARCH_CPPFLAGS, ARCH_AFLAGS and
    ARCH_CFLAGS variables that are appended to the respective kbuild
    variables. The user still has the final say via the KCPPFLAGS, KAFLAGS
    and KCFLAGS variables.

    Reported-by: Vineet Gupta
    Cc: stable@vger.kernel.org # 3.16+
    Signed-off-by: Michal Marek

    Michal Marek
     

22 Jun, 2015

1 commit

  • The header install makefile creates an 'include' directory inside
    INSTALL_HDR_PATH and appending include to the path results in headers
    being installed to include/include.

    Don't recommend appending include to the path as makefile already does
    this.

    Signed-off-by: Anish Bhatt
    Signed-off-by: Jonathan Corbet

    Anish Bhatt
     

09 Jun, 2015

1 commit


20 Feb, 2015

1 commit

  • Pull misc kbuild changes from Michal Marek:
    "Just a few non-critical kbuild changes:

    - builddeb adds the actual distribution name in the changelog
    - documentation fixes"

    * 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
    kbuild: trivial - fix the help doc of CONFIG_CC_OPTIMIZE_FOR_SIZE
    kbuild: Update documentation of clean-files and clean-dirs
    builddeb: Try to determine distribution
    builddeb: Update year and git repository URL in debian/copyright

    Linus Torvalds
     

10 Jan, 2015

2 commits


08 Jan, 2015

1 commit


19 Aug, 2014

4 commits


15 Aug, 2014

2 commits

  • Pull misc kbuild updates from Michal Marek:
    "This is the non-critical part of kbuild for 3.17-rc1:

    - make help hint to use make -s with make kernelrelease et al.
    - moved a kbuild document to Documentation/kbuild where it belongs
    - four new Coccinelle scripts, one dropped and one fixed
    - new make kselftest target to run various tests on the kernel"

    * 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
    kbuild: kselftest - new make target to build and run kernel selftests
    Coccinelle: Script to replace if and BUG with BUG_ON
    Coccinelle: Script to detect incorrect argument to sizeof
    Coccinelle: Script to use ARRAY_SIZE instead of division of two sizeofs
    Coccinelle: Script to detect cast after memory allocation
    coccinelle/null: solve parse error
    Documentation: headers_install.txt is part of kbuild
    kbuild: make -s should be used with kernelrelease/kernelversion/image_name

    Linus Torvalds
     
  • Pull kbuild updates from Michal Marek:
    - make clean also considers $(extra-m) and $(extra-) to be consistent
    - cleanup and fixes in scripts/Makefile.host
    - allow to override the name of the Python 2 executable with make
    PYTHON=... (only needed for ia64 in practice)
    - option to split debugingo into *.dwo files to save disk space if the
    compiler supports it (CONFIG_DEBUG_INFO_SPLIT)
    - option to use dwarf4 debuginfo if the compiler supports it
    (CONFIG_DEBUG_INFO_DWARF4)
    - fix for disabling certain warnings with clang
    - fix for unneeded rebuild with dash when a command contains
    backslashes

    * 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
    kbuild: Fix handling of backslashes in *.cmd files
    kbuild, LLVMLinux: Supress warnings unless W=1-3
    Kbuild: Add a option to enable dwarf4 v2
    kbuild: Support split debug info v4
    kbuild: allow to override Python command name
    kbuild: clean-up and bug fix of scripts/Makefile.host
    kbuild: clean up scripts/Makefile.host
    kbuild: drop shared library support from Makefile.host
    kbuild: fix a bug of C++ host program handling
    kbuild: fix a typo in scripts/Makefile.host
    scripts/Makefile.clean: clean also $(extra-m) and $(extra-)

    Linus Torvalds
     

05 Aug, 2014

1 commit

  • 'headers_install.txt' from Documentation/make/ is related to Kbuild
    so it must be moved in Documentation/kbuild/ directory.

    As Documentation/make/ directory has only one file, it will be removed
    as a consequence of moving 'headers_install.txt'.

    Cc: Kirill A. Shutemov
    Cc: David Woodhouse
    Cc: Rob Landley
    Signed-off-by: Yann Droneaud
    Acked-by: Sam Ravnborg
    Signed-off-by: Michal Marek

    Yann Droneaud
     

16 Jul, 2014

1 commit

  • The shared library feature in Makefile.host is no longer used.
    Rip it off to keep the build infrastucture simple.

    Update Documentation/kbuild/makefiles.txt too.
    The section "4.3 Definition shared libraries" should be removed
    and the following sections should be re-numbered.

    Signed-off-by: Masahiro Yamada
    Suggested-by: Sam Ravnborg
    Signed-off-by: Michal Marek

    Masahiro Yamada
     

19 Jun, 2014

1 commit


10 Jun, 2014

1 commit


08 Apr, 2014

1 commit

  • "make allnoconfig" exists to ease testing of minimal configurations.
    Documentation/SubmitChecklist includes a note to test with allnoconfig.
    This helps catch missing dependencies on common-but-not-required
    functionality, which might otherwise go unnoticed.

    However, allnoconfig still leaves many symbols enabled, because they're
    hidden behind CONFIG_EMBEDDED or CONFIG_EXPERT. For instance, allnoconfig
    still has CONFIG_PRINTK and CONFIG_BLOCK enabled, so drivers don't
    typically get build-tested with those disabled.

    To address this, introduce a new Kconfig option "allnoconfig_y", used on
    symbols which only exist to hide other symbols. Set it on CONFIG_EMBEDDED
    (which then selects CONFIG_EXPERT). allnoconfig will then disable all the
    symbols hidden behind those.

    Signed-off-by: Josh Triplett
    Tested-by: Paul E. McKenney
    Cc: Michal Marek
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Josh Triplett
     

09 Oct, 2013

1 commit


05 Sep, 2013

1 commit

  • Previously, it was possible to have more than one symbol with the
    'option modules' attached to them, although only the last one would
    in fact control tristates.

    Since this does not make much sense, only allow at most one symbol to
    control tristates.

    Note: it is still possible to have more than one symbol that control
    tristates, but indirectly:

    config MOD1
    bool "mod1"
    select MODULES
    config MOD2
    bool "mod2"
    select MODULES
    config MODULES
    bool
    option modules

    Signed-off-by: "Yann E. MORIN"
    Cc: Sam Ravnborg
    Signed-off-by: Michal Marek

    Yann E. MORIN
     

23 Jul, 2013

1 commit


17 Jul, 2013

1 commit


11 Jul, 2013

1 commit

  • Pull kconfig updates from Michal Marek:
    - dependency solver fix for make defconfig
    - randconfig fixes, one of which had to be reverted again
    - more user-friendly sorting of search results
    - hex and range keywords support longs
    - fix for [mn]conf not to rely on particular behavior of the LINES and
    COLS variables
    - cleanup of magic constants in kconfig/lxdialog
    - [mn]conf formatting fixes
    - fix for scripts/config's help text in out-of-tree usage (under a
    different name)

    * 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
    kconfig: allow "hex" and "range" to support longs
    Revert "kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG"
    kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
    kconfig: loop as long as we changed some symbols in randconfig
    kconfig/[mn]conf: make it explicit in the search box that a regexp is possible
    kconfig: sort found symbols by relevance
    kconfig/conf: print the seed used to initialise the RNG for randconfig
    kconfig/conf: accept a base-16 seed for randconfig
    kconfig/conf: fix randconfig setting multiple symbols in a choice
    scripts/config: replace hard-coded script name by a dynamic value
    mconf/nconf: mark empty menus/menuconfigs different from non-empty ones
    nconf: use function calls instead of ncurses' variables LINES and COLS
    mconf: use function calls instead of ncurses' variables LINES and COLS
    kconfig/lxdialog: handle newline characters in print_autowrap()
    kconfig/lxdialog: Use new mininimum resize definitions in conf_choice()
    kconfig/lxdialog: Add definitions for mininimum (re)size values
    kconfig: Fix defconfig when one choice menu selects options that another choice menu depends on

    Linus Torvalds
     

25 Jun, 2013

1 commit

  • When searching for symbols, return the symbols sorted by relevance.

    Sorting is done as thus:
    - first, symbols that match exactly
    - then, alphabetical sort

    Since the search can be a regexp, it is possible that more than one symbol
    matches exactly. In this case, we can't decide which to sort first, so we
    fallback to alphabeticall sort.

    Explain this (new!) sorting heuristic in the documentation.

    Reported-by: Jean Delvare
    Signed-off-by: "Yann E. MORIN"
    Cc: Jean Delvare
    Cc: Michal Marek
    Cc: Roland Eggner
    Cc: Wang YanQing

    --
    Changes v1->v2:
    - drop the previous, complex heuristic in favour of a simpler heuristic
    that is both easier to understand, *and* to maintain (Jean)
    - explain sorting heuristic in the doc (Jean)

    Yann E. MORIN
     

04 Jun, 2013

1 commit

  • Ever since commit 45f035ab9b8f ("CONFIG_HOTPLUG should be always on"),
    it has been basically impossible to build a kernel with CONFIG_HOTPLUG
    turned off. Remove all the remaining references to it.

    Cc: Russell King
    Cc: Doug Thompson
    Cc: Bjorn Helgaas
    Cc: Steven Whitehouse
    Cc: Arnd Bergmann
    Cc: Pavel Machek
    Cc: "Rafael J. Wysocki"
    Cc: Andrew Morton
    Signed-off-by: Stephen Rothwell
    Acked-by: Mauro Carvalho Chehab
    Acked-by: Hans Verkuil
    Signed-off-by: Greg Kroah-Hartman

    Stephen Rothwell
     

07 May, 2013

2 commits

  • Pull misc kbuild updates from Michal Marek:
    "Non-critical kbuild changes:

    - make coccicheck improvements, but no new semantic patches this time

    - make rpm improvements

    - make tar-pkg change to include the architecture in the filename.

    This is a deliberate incompatibility, but nobody has complained so
    far and it is useful if you build for different architectures. It
    also matches what the deb-pkg and rpm-pkg targets produce.

    - kbuild documentation fix"

    * 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
    rpm-pkg: Remove pointless set -e statements
    rpm-pkg: Always regenerate the specfile
    rpm-pkg: Do not write to the parent directory
    rpm-pkg: Do not package the whole source directory
    buildtar: Add ARCH to the archive name
    Coccinelle: Fix patch output when coccicheck is used with M= and C=
    Coccinelle: Add support to the SPFLAGS variable
    Coccinelle: Cleanup the setting of the FLAGS and OPTIONS variables
    Coccinelle: Restore coccicheck verbosity in ONLINE mode (C=1 or C=2)
    scripts/package/Makefile: compare objtree with srctree instead of test KBUILD_OUTPUT
    doc: change example to existing Makefile fragment
    scripts/tags.sh: Add magic for OFFSET and DEFINE

    Linus Torvalds
     
  • Pull kconfig updates from Michal Marek:
    - use pkg-config to detect curses libraries
    - clean up the way curses headers are searched
    - Some randconfig fixes, of which one had to be reverted
    - KCONFIG_SEED for randconfig debugging
    - memuconfig memory leak plugged
    - menuconfig > breadcrumbs > navigation
    - xconfig compilation fix
    - Other minor fixes

    * 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
    kconfig: fix lists definition for C++
    Revert "kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG"
    kconfig: implement KCONFIG_PROBABILITY for randconfig
    kconfig: allow specifying the seed for randconfig
    kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
    kconfig: do not override symbols already set
    kconfig: fix randconfig tristate detection
    kconfig/lxdialog: rationalise the include paths where to find {.n}curses{,w}.h
    menuconfig: Add "breadcrumbs" navigation aid
    menuconfig: Fix memory leak introduced by jump keys feature
    merge_config.sh: Avoid creating unnessary source softlinks
    kconfig: optionally use pkg-config to detect ncurses libs
    menuconfig: optionally use pkg-config to detect ncurses libs

    Linus Torvalds
     

25 Apr, 2013

2 commits

  • Currently the odds to set each symbol is (rounded):
    booleans: y: 50% n: 50%
    tristates: y: 33% m: 33% n: 33%

    Introduce a KCONFIG_PROBABILITY environment variable to tweak the
    probabilities (in percentage), as such:
    KCONFIG_PROBABILITY y:n split y:m:n split
    -----------------------------------------------------------------
    [1] unset or empty 50 : 50 33 : 33 : 34
    [2] N N : 100-N N/2 : N/2 : 100-N
    N:M N+M : 100-(N+M) N : M : 100-(N+M)
    N:M:L N : 100-N M : L : 100-(M+L)

    [1] The current behaviour is kept as default, for backward compatibility
    [2] The solution initially implemented by Peter for Buildroot, see:
    http://git.buildroot.org/buildroot/commit/?id=3435c1afb5

    Signed-off-by: Peter Korsgaard
    [yann.morin.1998@free.fr: add to Documentation/]
    Signed-off-by: "Yann E. MORIN"

    Yann E. MORIN
     
  • For reproducibility, it can be useful to be able to specify the
    seed to use to seed the RNG.

    Add a new KCONFIG_SEED environment variable which can be set to
    the seed to use:
    $ make KCONFIG_SEED=42 randconfig
    $ sha1sum .config
    70a128c8dcc61303069e1be352cce64114dfcbca .config
    $ make KCONFIG_SEED=42 randconfig
    $ sha1sum .config
    70a128c8dcc61303069e1be352cce64114dfcbca .config

    It's very usefull for eg. debugging the kconfig parser.

    Signed-off-by: "Yann E. MORIN"

    Yann E. MORIN
     

08 Apr, 2013

2 commits

  • Signed-off-by: Paul Bolle
    Acked-by: Rob Landley
    Signed-off-by: Michal Marek

    Paul Bolle
     
  • The kbuild's ld-option function is broken because
    the command
    $(CC) /dev/null -c -o "$$TMPO"
    does not create object file!

    I have used a relatively old mips gcc 3.4.6 cross-compiler
    and a relatively new gcc 4.7.2 to check this fact
    but the results are the same.

    EXAMPLE:
    $ rm /tmp/1.o
    $ mips-linux-gcc /dev/null -c -o /tmp/1.o
    mips-linux-gcc: /dev/null: linker input file unused because linking not done
    $ ls -la /tmp/1.o
    ls: cannot access /tmp/1.o: No such file or directory

    We can easily fix the problem by adding
    the '-x c' compiler option.

    EXAMPLE:
    $ rm /tmp/1.o
    $ mips-linux-gcc -x c /dev/null -c -o /tmp/1.o
    $ ls -la /tmp/1.o
    -rw-r--r-- 1 antony antony 778 Apr 2 20:40 /tmp/1.o

    Also fix wrong ld-option example.

    Signed-off-by: Antony Pavlov
    Signed-off-by: Michal Marek

    Antony Pavlov
     

28 Feb, 2013

1 commit

  • Pull kconfig changes from Michal Marek:
    "I forgot to send a pull request in time for the v3.8-rc1 merge window,
    so the list is a bit longer this time:

    - menuconfig enables extended colors in ncurses if the wide-character
    version is used.

    - CONFIG_ prefix can be specified in the environment to make life
    easier for people using kconfig multiple times in a single tree (no
    functional change in the kernel kconfig usage).

    - kconfig aborts on OOM.

    - inputboxes in menuconfig allow to move the cursor.

    - menuconfig has Save/Load buttons now.

    - xconfig build fix with new g++ and Qt3.

    - nconfig color scheme fix and help text update.

    - make oldconfig prints newlines when output is redirected.

    - some other minor fixes."

    * 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
    kbuild: Fix missing '\n' for NEW symbols in yes "" | make oldconfig >conf.new
    kconfig: nconf: rewrite labels of function keys line
    kconfig: nconf: rewrite help texts
    kconfig: fix a compiliation error when using make xconfig
    nconf: function keys line, change background color for better readability
    menuconfig: Get rid of the top-level entries for "Load an Alternate/Save an Alternate"
    menuconfig: Add Save/Load buttons
    kconfig:lxdialog: remove duplicate code
    menuconfig:inputbox: support navigate input position
    kconfig: document use of CONFIG_ environment variable
    scripts/kconfig: ensure we use proper CONFIG_ prefix
    merge_config.sh: Add option to specify output dir
    Revert "kconfig-language: add to hints"
    kconfig: Regenerate lexer
    kconfig: Fix malloc handling in conf tools
    kconfig: get CONFIG_ prefix from the environment
    kconfig: add a function to get the CONFIG_ prefix
    kconfig: remove CONFIG_ from string constants
    menuconfig: fix extended colors ncurses support

    Linus Torvalds