summaryrefslogtreecommitdiff
path: root/scripts
AgeCommit message (Collapse)Author
2015-10-26coccinelle: ifnullfree: handle various destroy functionsJulia Lawall
Extend ifnullfree to the various destroy functions that were recently extended to tolerate NULL arguments. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.cz>
2015-10-26coccinelle: ifnullfree: various cleanupsJulia Lawall
Adjust tests to compare against NULL, to match cases that explicitly make that comparison. Remove removal and re-addition of freeing functions. Add position variable on usb_free_urb in the non-patch case. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.cz>
2015-10-26cocinelle: iterators: semantic patch to delete unneeded of_node_putJulia Lawall
Device node iterators perform an of_node_put on each iteration, so putting an of_node_put before a continue results in a double put. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.cz>
2015-10-26deb-pkg: Add automatic support for armhf architectureBen Hutchings
The Debian armhf architecture uses the ARM EABI hard-float variant, whereas armel uses the soft-float variant. Although the kernel doesn't use FP itself, CONFIG_VFP must be enabled to support hard-float userland and will probably be disabled when supporting a soft-float userland. So set the architecture to armhf by default when CONFIG_AEABI and CONFIG_VFP are both enabled. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Acked-by: Ian Campbell <ijc@hellion.org.uk> Acked-by: Fathi Boudra <fathi.boudra@linaro.org> Reviewed-by: Riku Voipio <riku.voipio@linaro.org> Signed-off-by: Michal Marek <mmarek@suse.cz>
2015-10-26scripts/coccinelle: fix typosJulia Lawall
Fix a couple spelling mistakes. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.cz>
2015-10-26coccinelle: misc: remove "complex return code" warningsJohan Hovold
This effectively reverts 932058a5d5f9 ("coccinelle: misc: semantic patch to delete overly complex return code processing"). There can be both symmetry and readability reasons for not wanting to do the final function call as part of the return statement and to maintain a clear separation of success and error paths. Since this is in no way mandated by the coding standard, let's just remove this semantic patch to avoid having "clean up" patches being posted over and over in response to these Coccinelle warnings. Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.cz>
2015-10-26Coccinelle: fix incorrect -include option transformationAndrzej Hajda
kbuild/gcc uses -include option to include files and -I to provide paths for #include <> directive. In case of spatch latter option should be prefixed with two -. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.cz>
2015-10-26coccinelle: tests: improve odd_ptr_err.cocciJulia Lawall
The original version only considered the case where the then branch contains only one call to PTR_ERR. Reimplement the whole thing to allow multiple calls, with potentially different arguments. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.cz>
2015-10-26coccinelle: misc: move constants to the rightJulia Lawall
Move constants to the right in binary operators. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-26scripts: [modpost] add new sections to white listNoam Camus
In our ARC toolchain the default linker script includes special sections used for code and data located in special fast memory. To avoid warnings we add these sections i.e. .cmem* and .fmt_slot* to white list. Signed-off-by: Noam Camus <noamc@ezchip.com> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Quentin Casasnovas <quentin.casasnovas@oracle.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2015-10-23Merge branch 'topic/hw-constraint-single' into for-nextTakashi Iwai
2015-10-21KEYS: Provide a script to extract a module signatureDavid Howells
The supplied script takes a signed module file and extracts the tailmost signature (there could theoretically be more than one) and dumps all or part of it or the unsigned file to stdout. Call as: scripts/extract-module-sig.pl -[0adnks] module-file >out where the initial flag indicates which bit of the signed file you want dumping to stdout: (*) "-0". Dumps the unsigned data with the signature stripped. (*) "-a". Dumps all of the signature data, including the magic number. (*) "-d". Dumps the signature information block as a sequence of decimal numbers in text form with spaces between (crypto algorithm type, hash type, identifier type, signer's name length, key identifier length and signature length). (*) "-n". Dumps the signer's name contents. (*) "-k". Dumps the key identifier contents. (*) "-s". Dumps the cryptographic signature contents. In the case that the signature is a PKCS#7 (or CMS) message, -n and -k will print a warning to stderr and dump nothing to stdout, but will otherwise complete okay; the entire PKCS#7/CMS message will be dumped by "-s"; and "-d" will show "0 0 2 0 0 <pkcs#7-msg-len>". Signed-off-by: David Howells <dhowells@redhat.com>
2015-10-21KEYS: Provide a script to extract the sys cert list from a vmlinux fileDavid Howells
The supplied script takes a vmlinux file - and if necessary a System.map file - locates the system certificates list and extracts it to the named file. Call as: ./scripts/extract-sys-certs vmlinux certs if vmlinux contains symbols and: ./scripts/extract-sys-certs -s System.map vmlinux certs if it does not. It prints something like the following to stdout: Have 27 sections No symbols in vmlinux, trying System.map Have 80088 symbols Have 1346 bytes of certs at VMA 0xffffffff8201c540 Certificate list in section .init.data Certificate list at file offset 0x141c540 If vmlinux contains symbols then that is used rather than System.map - even if one is given. Signed-off-by: David Howells <dhowells@redhat.com>
2015-10-20kconfig: Fix copy&paste errorMichal Sojka
Fixes: 31847b67bec0 ("kconfig: allow use of relations other than (in)equality") Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz> Reviewed-by: Jan Beulich <jbeulich@suse.com> Signed-off-by: Michal Marek <mmarek@suse.cz>
2015-10-20ALSA: hda - Add hduadio support to DEVTABLESubhransu S. Prusty
For generating modalias entries automatically, move the definition of struct hda_device_id to linux/mod_devicetable.h and add the handling of this record in file2alias helper. The new modalias is represented with combination of vendor id, device id, and api version as "hdaudio:vNrNaN". This patch itself doesn't convert the existing modaliases. Since they were added manually, this patch won't give any regression by itself at this point. [Modified the modalias format to adapt the api_version field, and drop invalid ANY_ID definition by tiwai] Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com> Reviewed-by: Vinod Koul <vinod.koul@intel.com> Tested-by: Subhransu S Prusty <subhransu.s.prusty@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2015-10-17ver_linux: proc/modules, limit text processing to 'sed'Alexander Kapshuk
This patch is more of a personal preference, rather than a fix for a problem. The current implementation used a combination of both 'cat' and 'sed' to generate an unsorted list of kernel modules separated by while space. The proposed implementation uses 'sort' and 'sed' to generate a sort list of kernel modules separated by while space. Tested on: Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Arch Linux openSuSE 13.2 Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: wireless-tools, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Tested on: Gentoo Linux Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: use 'udevadm', instead of 'udevinfo'Alexander Kapshuk
'udevinfo' no longer seems to be available across various distros. 'udevadm' seems to be the currently valid way to look up the 'udev' version. Tested on: Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'awk'. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: sh-utils, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Tested on: Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: loadkeys, look for numerical input, not field numberAlexander Kapshuk
'loadkeys -h' no longer prints the version number across all distros, despite the claim to do so in the manpage, which I found to be the case on a Debian Linux system. The proposed implementation utilises the output of 'loadkeys -V' to acquire the version of both 'Kbd' and 'Console-tools'. Tested on: Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: net-tools, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'awk'. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: procps, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'awk'. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: libcpp, fix missing outputAlexander Kapshuk
Neither 'libg++.so', nor 'libstdc++.so' were found where the current implementation expects them to be found in the distros below. Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Which results in zero ouput generated. The proposed implementation relies on 'ldconfig' to locate the libraries in question. 'Sed' is used to do the text processing. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: ldd, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'head' + 'awk'. The '-v' flag either seems to have been deprecated in some distros, e.g. Gentoo, or is an alias for '--version' in others. The proposed implementation uses the latter flag only. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: libc, input redirection to sed fails in some distrosAlexander Kapshuk
The current implementation has been found not to work across all distros. The proposed implementation relies on 'sed' to both output the string 'Linux C Library' as well as to open '/proc/self/maps' without having to use output redirection. Tested on: Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Arch Linux openSuSE 13.2 Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: ppp, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'awk'. Tested on: Oracle Linux Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: quota-tools, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'awk'. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: pcmciautils, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'awk'. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: xfsprogs, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'awk'. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: reiserfsprogs, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'awk'. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: jfsutils, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'sed' + 'awk'. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: e2fsprogs, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Proposed implementation also eliminates the necessity to invoke 'grep' + 'sed' + 'awk'. Tested on: Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: module-init-tools, look for numerical input, not field numberAlexander Kapshuk
Rely on regex to find the version number, rather than rely on numerical input to be found in a particular input field. Tested on: Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: util-linux, 'fdformat' not ubiquitous any longerAlexander Kapshuk
The current implementation relies on 'fdformat' to output the version of 'util-linux'. This does not seem to be reliable any longer, as 'fdformat' does not seem to come preinstalled in all ditros these days. The proposed implementation uses 'mount' to output both the version of 'util-linux' and 'mount' proper, as 'mount' is also a part of the 'util-linux' package. Tested on: Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Rely on regex to find the version number, rather than a field number. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: binutils, fix inaccurate outputAlexander Kapshuk
Current implementation output on Gentoo Linux: binutils 2.25.1 1.1 2.25.1 Proposed implementation: Binutils 2.25.1 Tested on: Gentoo Linux Debian 6.0.10 Oracle Linux Server release 7.1 Rely on regex to find the version number. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: make --version, use regex to find version numberAlexander Kapshuk
Rely on regex to find the version number, rather than a field number. Reduce the number of 'awk' invocations from two to one. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-17ver_linux: gcc -dumpversion, use regex to find version numberAlexander Kapshuk
Rely on regex to find the version number, rather than a field number. Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16builddeb: remove debian/files before buildRiku Voipio
Commit 3716001bcb7f ("deb-pkg: add source package") added the ability to create a debian changelog file. This exposed that previously the builddeb script hasn't cleared debian/files between builds. As debian/files keeps accumulating entries, the changes file will end up growing indefinelty. With outdated entries in debian/files, builddeb script will exit with failure. This regression impacts those who use "make deb-pkg" target to build kernel into a .deb package and never use "make mrproper" or other means to clean kernel tree from generated directories. To fix the regression, remove debian/files before starting build and in the generated clean rule. Fixes: 3716001bcb7f ("deb-pkg: add source package") Signed-off-by: Riku Voipio <riku.voipio@linaro.org> Reported-by: Doug Smythies <dsmythies@telus.net> Tested-by: Doug Smythies <dsmythies@telus.net> Tested-by: Kalle Valo <kvalo@codeaurora.org> Acked-by: Ben Hutchings <ben@decadent.org.uk> Cc: Michal Marek <mmarek@suse.cz> Cc: maximilian attems <maks@stro.at> Cc: Chris J Arges <chris.j.arges@canonical.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-10-15scripts/kconfig/Makefile: Fix KBUILD_DEFCONFIG check when building with O=Michael Ellerman
My recent commit d2036f30cfe1 ("scripts/kconfig/Makefile: Allow KBUILD_DEFCONFIG to be a target"), contained a bug in that when it checks if KBUILD_DEFCONFIG is a file it forgets to prepend $(srctree) to the path. This causes the build to fail when building out of tree (with O=), and when the value of KBUILD_DEFCONFIG is 'defconfig'. In that case we will fail to find the 'defconfig' file, because we look in the build directory not $(srctree), and so we will call Make again with 'defconfig' as the target. From there we loop infinitely calling 'make defconfig' again and again. The fix is simple, we need to look for the file under $(srctree). Fixes: d2036f30cfe1 ("scripts/kconfig/Makefile: Allow KBUILD_DEFCONFIG to be a target") Reported-by: Olof Johansson <olof@lixom.net> Acked-by: Michal Marek <mmarek@suse.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2015-10-14kconfig/merge_config.sh: Accept a single fileGabriel de Perthuis
merge_config.sh can usefully be applied to a single file. It implicitly merges with the default configuration. Signed-off-by: Gabriel de Perthuis <g2p.code@gmail.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14kconfig/merge_config.sh: Support KCONFIG_CONFIGGabriel de Perthuis
All make targets support $KCONFIG_CONFIG because they run scripts/kconf. Make sure merge_config.sh accesses the correct file in all cases. Previously this script broke in two different code paths, one for targets like kvmconfig (which use merge_config.sh -m then call a target that respects KCONFIG_CONFIG) and one for direct use of the script without -m, which called make rules that edit KCONFIG_CONFIG but verified a different file. Signed-off-by: Gabriel de Perthuis <g2p.code@gmail.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14Update the buildsystem for KConfig finding QtThiago Macieira
The buildsystem will now only search for Qt 4 and Qt 5. Support for Qt 2 and 3 was dropped in the previous commits (Qt 3 was EOL'ed in 2010 or so...). For Qt 5, to be future-proof with the future direction notice appearing in the 5.5 release, C++11 support is automatically enabled. Signed-off-by: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14Port xconfig to Qt5 - Update copyright.Boris Barbulovski
Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com> Signed-off-by: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14Port xconfig to Qt5 - Fix goParent issue.Boris Barbulovski
Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com> Signed-off-by: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14Port xconfig to Qt5 - on Back clicked, deselect old item.Boris Barbulovski
Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com> Signed-off-by: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14Port xconfig to Qt5 - Add(back) one click checkbox toggle.Boris Barbulovski
Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com> Signed-off-by: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14Port xconfig to Qt5 - Add(back) lineedit editing.Boris Barbulovski
Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com> Signed-off-by: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14Port xconfig to Qt5 - Remove some commented code.Boris Barbulovski
Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com> Signed-off-by: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14Port xconfig to Qt5 - Source format.Boris Barbulovski
Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com> Signed-off-by: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Michal Marek <mmarek@suse.com>
2015-10-14Port xconfig to Qt5 - Add horizontal scrollbar, and scroll per pixel.Boris Barbulovski
Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com> Signed-off-by: Thiago Macieira <thiago.macieira@intel.com> Signed-off-by: Michal Marek <mmarek@suse.com>