- Aug 28, 2014
-
-
Kyle McMartin authored
AArch64 stores the frame pointer and return pointer, and decrements the stack. Also remove my (no longer valid) email address. Signed-off-by:
Kyle McMartin <kyle@redhat.com> Signed-off-by:
Jiri Kosina <jkosina@suse.cz>
-
- Jul 12, 2014
-
-
Horia Geanta authored
Object-like macros are different than function-like macros: https://gcc.gnu.org/onlinedocs/cpp/Object-like-Macros.html https://gcc.gnu.org/onlinedocs/cpp/Function-like-Macros.html They are not parsed correctly, generating invalid intermediate files (xmls) for cases like: #define BIT_MASK (0xFF << BIT_SHIFT) where "OxFF <<" is considered to be parameter type. When parsing, we can differentiate beween these two types of macros by checking whether there is at least one whitespace b/w "#define" and first opening parenthesis. Signed-off-by:
Horia Geanta <horia.geanta@freescale.com> Signed-off-by:
Randy Dunlap <rdunlap@infradead.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Jul 08, 2014
-
-
Joe Perches authored
We can now designate reviewers in the MAINTAINERS file with the new "R:" tag, so this commit teaches get_maintainers.pl to add their email addresses. Signed-off-by:
Joe Perches <joe@perches.com> Signed-off-by:
Paul E. McKenney <paulmck@linux.vnet.ibm.com>
-
- Jun 26, 2014
-
-
Alex Smith authored
On MIPS calls to _mcount in modules generate 2 instructions to load the _mcount address (and therefore 2 relocations). The mcount_loc table should only reference the first of these, so the second is filtered out by checking the relocation offset and ignoring ones that immediately follow the previous one seen. However if a module has an _mcount call at offset 0, the second relocation would not be filtered out due to old_r_offset == 0 being taken to mean that the current relocation is the first one seen, and both would end up in the mcount_loc table. This results in ftrace_make_nop() patching both (adjacent) instructions to branches over the _mcount call sequence like so: 0xffffffffc08a8000: 04 00 00 10 b 0xffffffffc08a8014 0xffffffffc08a8004: 04 00 00 10 b 0xffffffffc08a8018 0xffffffffc08a8008: 2d 08 e0 03 move at,ra ... The second branch is in the delay slot of the first, which is defined to be unpredictable - on the platform on which this bug was encountered, it triggers a reserved instruction exception. Fix by initializing old_r_offset to ~0 and using that instead of 0 to determine whether the current relocation is the first seen. Signed-off-by:
Alex Smith <alex.smith@imgtec.com> Cc: linux-kernel@vger.kernel.org Cc: stable@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/7098/ Signed-off-by:
Ralf Baechle <ralf@linux-mips.org>
-
- Jun 23, 2014
-
-
Joe Perches authored
The previous patch had a few too many false positives on styles that should be acceptable. Signed-off-by:
Joe Perches <joe@perches.com> Tested-by:
Anish Bhatt <anish@chelsio.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Jun 20, 2014
-
-
Jingoo Han authored
devm_request_and_ioremap() was obsoleted by the commit 75096579 ("lib: devres: Introduce devm_ioremap_resource()") and has been deprecated for a long time. So, let's remove this function. In addition, all usages of devm_request_and_ioremap() are also removed. Signed-off-by:
Jingoo Han <jg1.han@samsung.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- Jun 19, 2014
-
-
Olaf Hering authored
Signed-off-by:
Olaf Hering <olaf@aepfle.de> Signed-off-by:
Jiri Kosina <jkosina@suse.cz>
-
- Jun 18, 2014
-
-
Fathi Boudra authored
The kernel headers package (linux-headers) doesn't include several header files required to build out-of-tree modules. It makes the package unusable on e.g. ARM architecture: /usr/src/linux-headers-3.14.0/arch/arm/include/asm/memory.h:24:25: fatal error: mach/memory.h: No such file or directory #include <mach/memory.h> ^ compilation terminated. Signed-off-by:
Fathi Boudra <fathi.boudra@linaro.org> Reviewed-by:
Ben Hutchings <ben@decadent.org.uk> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Michal Marek authored
Commit 7e1c0477 (kbuild: Use relative path for $(objtree)) assumes that the build process does not change its working directory. make tar-pkg was a couterexample, fix this by changing directory only for the tar command and not for the whole script, which at one point references the now relative $(objtree). Reported-and-tested-by:
"J. Bruce Fields" <bfields@fieldses.org> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Michal Marek authored
When $srctree or $objtree are relative paths, we cannot change directory and refer to them in the same subshell. Do the redirection outside of the subshell to fix this. Reported-and-tested-by:
Ilya Dryomov <idryomov@gmail.com> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
- Jun 17, 2014
-
-
Masahiro Yamada authored
Files added to hostprogs-y are cleaned. (See scripts/Makefile.clean) Adding them to clean-files is redundant. Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by:
Paul Moore <paul@paul-moore.com> Signed-off-by:
Paul Moore <pmoore@redhat.com>
-
- Jun 10, 2014
-
-
Sasha Levin authored
Right now when people try to report issues in the kernel they send stack dumps to eachother, which looks something like this: [ 6.906437] [<ffffffff811f0e90>] ? backtrace_test_irq_callback+0x20/0x20 [ 6.907121] [<ffffffff84388ce8>] dump_stack+0x52/0x7f [ 6.907640] [<ffffffff811f0ec8>] backtrace_regression_test+0x38/0x110 [ 6.908281] [<ffffffff813596a0>] ? proc_create_data+0xa0/0xd0 [ 6.908870] [<ffffffff870a8040>] ? proc_modules_init+0x22/0x22 [ 6.909480] [<ffffffff810020c2>] do_one_initcall+0xc2/0x1e0 [...] However, most of the text you get is pure garbage. The only useful thing above is the function name. Due to the amount of different kernel code versions and various configurations being used, the kernel address and the offset into the function are not really helpful in determining where the problem actually occured. Too often the result of someone looking at a stack dump is asking the person who sent it for a translation for one or more 'addr2line' translations. Which slows down the entire process of debugging the issue (and really annoying). The decode_stacktrace script is an attempt to make the output more useful and easy to work with by translating all kernel addresses in the stack dump into line numbers. Which means that the stack dump would look like this: [ 635.148361] dump_stack (lib/dump_stack.c:52) [ 635.149127] warn_slowpath_common (kernel/panic.c:418) [ 635.150214] warn_slowpath_null (kernel/panic.c:453) [ 635.151031] _oalloc_pages_slowpath+0x6a/0x7d0 [ 635.152171] ? zone_watermark_ok (mm/page_alloc.c:1728) [ 635.152988] ? get_page_from_freelist (mm/page_alloc.c:1939) [ 635.154766] __alloc_pages_nodemask (mm/page_alloc.c:2766) It's pretty obvious why this is better than the previous stack dump before. Usage is pretty simple: ./decode_stacktrace.sh [vmlinux] [base path] Where vmlinux is the vmlinux to extract line numbers from and base path is the path that points to the root of the build tree, for example: ./decode_stacktrace.sh vmlinux /home/sasha/linux/ < input.log > output.log The stack trace should be piped through it (I, for example, just pipe the output of the serial console of my KVM test box through it). Signed-off-by:
Sasha Levin <sasha.levin@oracle.com> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Masahiro Yamada authored
For example, $ scripts/objdiff record init drivers/usb disassembles all the objects under init and drivers/usb directories. This feature would be useful when we change various files under the specific directory. Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by:
Jason Cooper <jason@lakedaemon.net> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Masahiro Yamada authored
Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by:
Jason Cooper <jason@lakedaemon.net> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Masahiro Yamada authored
Prior to this commit, the command "scripts/objdiff record path/to/*.o" disassembled the given object into ".tmp_objdiff/path/to/*.o" file. The problem here is that recorded disassemblies are lost if we run "make clean" because it removes all the *.o files. Disassembled code should be dumped into *.dis instead of *.o files. Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by:
Jason Cooper <jason@lakedaemon.net> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Masahiro Yamada authored
Prior to this commit, scripts/objdiff expected to be run at the top directory and only the relative path of objects. This commit provides more flexibility in terms of object path: [1] scripts/objdiff can be run in any directory For example, $ scripts/objdiff record init/main.o and $ cd init; ../scripts/objdiff record main.o produce the same result. [2] Support absolute path for objects $ scripts/objdiff record /home/foo/bar/linux/init/main.o work as well. Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by:
Jason Cooper <jason@lakedaemon.net> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Masahiro Yamada authored
The directories for objdump is created by the code a few lines below: [ ! -d "$OBJDIFFD/$dn" ] && mkdir -p "$OBJDIFFD/$dn" Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by:
Jason Cooper <jason@lakedaemon.net> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Masahiro Yamada authored
Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by:
Jason Cooper <jason@lakedaemon.net> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Masahiro Yamada authored
This commit is a minor refactoring. Temporary files for objdiff are stored in .tmp_objdiff directory which is located at the top directory. To get the path to this directory, SRCTREE=`git rev-parse --show-toplevel` TMPD=$SRCTREE/.tmp_objdiff seems easier to understand than GIT_DIR=`git rev-parse --git-dir` TMPD=${GIT_DIR%git}tmp_objdiff Besides, it is not always necessary to create .tmp_objdiff dicrectory. It should be created only for "record" command. Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by:
Jason Cooper <jason@lakedaemon.net> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Ben Hutchings authored
The Debian s390x architecture has 64-bit userland whereas s390 has 32-bit userland. A 64-bit kernel can be used with either. Now that Debian supports multiarch and officially supports s390x, it makes more sense to assign a 64-bit kernel package to s390x. Reported-by:
Stephen Powell <zlinuxman@wowway.com> References: https://bugs.debian.org/750925 Signed-off-by:
Ben Hutchings <ben@decadent.org.uk> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Peter Senna Tschudin authored
This semantic patch looks for variables that are initialized with a constant, are never updated, and are only used as parameter of return. Return the constant instead of using a variable. Signed-off-by:
Peter Senna Tschudin <peter.senna@gmail.com> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Masahiro Yamada authored
Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
- Jun 09, 2014
-
-
Masahiro Yamada authored
The directory include/config is used only for silentoldconfig, localmodconfig, localyesconfig. Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Masahiro Yamada authored
Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com>
-
Stephen Boyd authored
Failure to terminate an of_device_id table can lead to confusing failures depending on where the compiler places the array. Add a check to make sure these tables are terminated. Thanks to Mitchel Humpherys for coming up with the pattern initially. Cc: Mitchel Humpherys <mitchelh@codeaurora.org> Cc: Gilles Muller <Gilles.Muller@lip6.fr> Cc: Nicolas Palix <nicolas.palix@imag.fr> Cc: Rob Herring <robh+dt@kernel.org> Cc: devicetree@vger.kernel.org Signed-off-by:
Stephen Boyd <sboyd@codeaurora.org> Acked-by:
Grant Likely <grant.likely@linaro.org> Signed-off-by:
Julia Lawall <julia.lawall@lip6.fr> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Masahiro Yamada authored
scripts/Makefile adds "selinux" to subdir-y or subdir- twice. subdir-$(CONFIG_MODVERSIONS) += genksyms subdir-y += mod subdir-$(CONFIG_SECURITY_SELINUX) += selinux <--- here subdir-$(CONFIG_DTC) += dtc # Let clean descend into subdirs subdir- += basic kconfig package selinux <--- again The latter is redundant. Signed-off-by:
Masahiro Yamada <yamada.m@jp.panasonic.com> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Yann Droneaud authored
Since commit 22d651dc ('selftests/powerpc: Import Anton's memcpy / copy_tofrom_user tests'), some source files in the tree appear as symlink. Until commit 8c38a532 ('scripts/tags.sh: ignore code of user space tools'), those symlinks made cscope report some warnings: $ make ALLSOURCE_ARCHS=all O=./obj-cscope/ cscope GEN cscope cscope: cannot find file .../tools/testing/selftests/powerpc/copyloops/copyuser_power7.S cscope: cannot find file .../tools/testing/selftests/powerpc/copyloops/memcpy_64.S cscope: cannot find file .../tools/testing/selftests/powerpc/copyloops/memcpy_power7.S cscope: cannot find file .../tools/testing/selftests/powerpc/copyloops/copyuser_64.S In order to prevent the same kind of warnings to be triggered by future addition of symlinks, the best option is to ignore all symlinks when building the file list to be processed by cscope (and other tools supported by scripts/tags.sh). Ignoring symlinks won't hide source files from cscope (and others) as the target of these symlinks already appear somewhere else in the tree, and, as such, should be processed by cscope (or others). Note that, cscope, when used with -R option to make it find the files to process by itself, already skip symlinks: it's not expected that cscope access source files through symlink. On top of commit 8c38a532 ('scripts/tags.sh: ignore code of user space tools'), scripts/tags.sh output from "make cscope tags TAGS" is the same with and without this patch: it doesn't seems to introduce any regression (on Fedora 20). Link: http://lkml.kernel.org/r/1396530975.4361.28.camel@localhost.localdomain Link: http://mid.gmane.org/534312F8.5090609@t-online.de Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Anton Blanchard <anton@samba.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Hans-Bernhard Bröker <broeker@users.sourceforge.net>, Cc: Hans-Bernhard Broeker <broeker@physik.rwth-aachen.de>, Cc: Neil Horman <nhorman@users.sourceforge.net> Cc: Neil Horman <nhorman@tuxdriver.com> Cc: Gerhard Sittig <gsi@denx.de> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Signed-off-by:
Yann Droneaud <ydroneaud@opteya.com> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
- Jun 04, 2014
-
-
Fabian Frederick authored
This patch adds a link to init.h to find appropriate initcall function to replace obsolete __initcall Signed-off-by:
Fabian Frederick <fabf@skynet.be> Cc: Andy Whitcroft <apw@canonical.com> Cc: Joe Perches <joe@perches.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Joe Perches authored
It should be stable@vger.kernel.org, not stable@kernel.org. Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Joe Perches authored
void function lines that use a single tab then "return;" are generally unnecessary. Signed-off-by:
Joe Perches <joe@perches.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Joe Perches authored
Use the kstrto<foo> functions in preference to sscanf. Signed-off-by:
Joe Perches <joe@perches.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Joe Perches authored
Protect against sizeof overflows by preferring kmalloc_array/kcalloc over kmalloc/kzalloc with a sizeof multiply. Signed-off-by:
Joe Perches <joe@perches.com> Cc: Andy Whitcroft <apw@canonical.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Joe Perches authored
Using a #define ending in a semicolon is poor style and can lead to unexpected code paths being executed. Warn on uses of these #define types: #define foo[(...)] bar; #define foo[(...)] \ bar; Based on a patch from Borislav Petkov. Signed-off-by:
Joe Perches <joe@perches.com> Cc: Borislav Petkov <bp@suse.de> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Joe Perches authored
Networking files are generally more strictly conformant to linux-kernel style so make checkpatch more verbose by default for patches to files or when checking files in these directories. Signed-off-by:
Joe Perches <joe@perches.com> Cc: Andy Whitcroft <apw@canonical.com> Cc: David Miller <davem@davemloft.net> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Joe Perches authored
Make the test system wide, modify the message too. Signed-off-by:
Joe Perches <joe@perches.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Rob Herring authored
We attempt to search for compatible strings which use a variable token in the documented name such as <chip> or <soc>. While this was attempted to be handled, it's utterly broken. The desired forms of matching are: vendor,<chip>-* vendor,name<part#>-* For <chip>, lower case characters and numbers are permitted. For <part#>, only numeric values are allowed. With this change, the number of missing compatible strings reported in arch/arm/boot/dts is reduced from 1071 to 960. Reported-by:
Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by:
Rob Herring <robh@kernel.org> Tested-by:
Geert Uytterhoeven <geert@linux-m68k.org> Cc: Florian Vaussard <florian.vaussard@epfl.ch> Cc: Joe Perches <joe@perches.com> Cc: Andy Whitcroft <apw@canonical.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- May 29, 2014
-
-
AKASHI Takahiro authored
Recordmcount utility under scripts is run, after compiling each object, to find out all the locations of calling _mcount() and put them into specific seciton named __mcount_loc. Then linker collects all such information into a table in the kernel image (between __start_mcount_loc and __stop_mcount_loc) for later use by ftrace. This patch adds arm64 specific definitions to identify such locations. There are two types of implementation, C and Perl. On arm64, only C version is used to build the kernel now that CONFIG_HAVE_C_RECORDMCOUNT is on. But Perl version is also maintained. This patch also contains a workaround just in case where a header file, elf.h, on host machine doesn't have definitions of EM_AARCH64 nor R_AARCH64_ABS64. Without them, compiling C version of recordmcount will fail. Acked-by:
Will Deacon <will.deacon@arm.com> Signed-off-by:
AKASHI Takahiro <takahiro.akashi@linaro.org> Signed-off-by:
Will Deacon <will.deacon@arm.com>
-
- May 20, 2014
-
-
James Hogan authored
The new renameat2 syscall provides all the functionality of renameat with an additional flags argument, so make renameat optional so that future architectures can omit it without getting a warning. This patch doesn't affect existing architectures. Signed-off-by:
James Hogan <james.hogan@imgtec.com> Acked-by:
Arnd Bergmann <arnd@arndb.de> Signed-off-by:
Miklos Szeredi <mszeredi@suse.cz> Cc: linux-arch@vger.kernel.org
-
- May 14, 2014
-
-
Michal Marek authored
When building the firmware blobs, use a simple loop to create directories in $(objtree), like in Makefile.build. This simplifies the rules and also makes it possible to set $(objtree) to '.' later. Before this change, a dependency on $(objtree)/<dir> would be satisfied by <dir> in $(srctree). When installing the firmware blobs, call mkdir like in Makefile.modinst. Cc: David Woodhouse <dwmw2@infradead.org> Acked-by:
Sam Ravnborg <sam@ravnborg.org> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-
Jianyu Zhan authored
Currently, while using ctags to read code, we would get stumbled on PageCgroup* symbols: no definition found. And it is quite dull to manually dig it out. This patch adds regular expression replacement pattern for such symbols, like what have done for the PageXXX flag. It will teach ctags to find out the definition for us. Signed-off-by:
Jianyu Zhan <nasa4836@gmail.com> Signed-off-by:
Michal Marek <mmarek@suse.cz>
-