diff options
author | Laura Abbott <labbott@fedoraproject.org> | 2017-03-02 07:26:26 -0800 |
---|---|---|
committer | Laura Abbott <labbott@fedoraproject.org> | 2017-03-02 07:26:26 -0800 |
commit | c1b581863c113172364a980dd65fd3e6bbb2f1aa (patch) | |
tree | 76e53fcc54f93ac864b29486b1c488448fc39cf1 | |
parent | e582bbd7279dcc29b7458459592db49095b931c3 (diff) | |
download | kernel-c1b581863c113172364a980dd65fd3e6bbb2f1aa.tar.gz kernel-c1b581863c113172364a980dd65fd3e6bbb2f1aa.tar.xz kernel-c1b581863c113172364a980dd65fd3e6bbb2f1aa.zip |
Linux v4.10-11073-g4977ab6
-rw-r--r-- | gitrev | 2 | ||||
-rw-r--r-- | kernel.spec | 8 | ||||
-rw-r--r-- | objtool-fix.patch | 153 | ||||
-rw-r--r-- | sources | 2 |
4 files changed, 6 insertions, 159 deletions
@@ -1 +1 @@ -2d6be4abf514fc26c83d239c7f31da1f95e4a31d +4977ab6e92e267afe9d8f78438c3db330ca8434c diff --git a/kernel.spec b/kernel.spec index 08b1b2cca..1d0d8cc66 100644 --- a/kernel.spec +++ b/kernel.spec @@ -69,7 +69,7 @@ Summary: The Linux kernel # The rc snapshot level %global rcrev 0 # The git snapshot level -%define gitrev 7 +%define gitrev 8 # Set rpm version accordingly %define rpmversion 4.%{upstream_sublevel}.0 %endif @@ -602,9 +602,6 @@ Patch666: ccm-stack.patch # grabbed from mailing list Patch667: v3-Revert-tty-serial-pl011-add-ttyAMA-for-matching-pl011-console.patch -# reported via IRC -Patch668: objtool-fix.patch - # END OF PATCH DEFINITIONS %endif @@ -2169,6 +2166,9 @@ fi # # %changelog +* Thu Mar 02 2017 Laura Abbott <labbott@fedoraproject.org> - 4.11.0-0.rc0.git8.1 +- Linux v4.10-11073-g4977ab6 + * Wed Mar 01 2017 Laura Abbott <labbott@fedoraproject.org> - 4.11.0-0.rc0.git7.1 - Linux v4.10-10770-g2d6be4a diff --git a/objtool-fix.patch b/objtool-fix.patch deleted file mode 100644 index fcf0c9956..000000000 --- a/objtool-fix.patch +++ /dev/null @@ -1,153 +0,0 @@ -From 898d20ca04d5a13dcca5483ed5213ad92fed88d3 Mon Sep 17 00:00:00 2001 -From: Josh Poimboeuf <jpoimboe@redhat.com> -Date: Wed, 1 Mar 2017 00:05:04 -0600 -Subject: [PATCH] objtool fixes - -On Tue, Feb 28, 2017 at 05:55:11PM -0800, Linus Torvalds wrote: -> Guys, -> the recent 'objtool' pull request broke things. -> -> I haven't bisected it, but I'm pretty sure that this part is pure garbage: -> -> On Mon, Feb 27, 2017 at 11:53 PM, Ingo Molnar <mingo@kernel.org> wrote: -> > -> > diff --git a/arch/x86/kernel/vmlinux.lds.S b/arch/x86/kernel/vmlinux.lds.S -> > index e79f15f108a8..ad0118fbce90 100644 -> > --- a/arch/x86/kernel/vmlinux.lds.S -> > +++ b/arch/x86/kernel/vmlinux.lds.S -> > @@ -346,6 +346,7 @@ SECTIONS -> > /DISCARD/ : { -> > *(.eh_frame) -> > *(__func_stack_frame_non_standard) -> > + *(__unreachable) -> > } -> > } -> > -> > diff --git a/include/linux/compiler-gcc.h b/include/linux/compiler-gcc.h -> > index 0444b1336268..f457b520ead6 100644 -> > --- a/include/linux/compiler-gcc.h -> > +++ b/include/linux/compiler-gcc.h -> > @@ -195,6 +195,17 @@ -> > #endif -> > #endif -> > -> > +#ifdef CONFIG_STACK_VALIDATION -> > +#define annotate_unreachable() ({ \ -> > + asm("%c0:\t\n" \ -> > + ".pushsection __unreachable, \"a\"\t\n" \ -> > + ".long %c0b\t\n" \ -> > + ".popsection\t\n" : : "i" (__LINE__)); \ -> > +}) -> > +#else -> > +#define annotate_unreachable() -> > +#endif -> -> and I think the above is what breaks module loading for me right now -> on my laptop. -> -> I get this during bootup: -> -> module: overflow in relocation type 10 val ffffffffc02afc81 -> module: 'nvme' likely not compiled with -mcmodel=kernel -> -> (and similar errors for other modules too), but those modules very -> much *are* compiled with all the normal kernel build flags, including -> -mcmodel=kernel. -> -> Now, relocation type 10 is R_X86_64_32, so the warning is very true: -> that address would fit in a _signed_ 32-bit value, but that's -> supposedly a 32-bit unsigned relocation. -> -> Trying to figure out what the hell is going on, I do: -> -> objdump -r nvme.ko | grep 64_32 -> -> and what do I find? I find -> -> RELOCATION RECORDS FOR [__unreachable]: -> OFFSET TYPE VALUE -> 0000000000000000 R_X86_64_32 .text+0x0000000000000c81 -> 0000000000000004 R_X86_64_32 .text+0x0000000000000cb5 -> 0000000000000008 R_X86_64_32 .text+0x0000000000001a18 -> 000000000000000c R_X86_64_32 .text+0x0000000000001a36 -> 0000000000000010 R_X86_64_32 .text+0x0000000000001e38 -> 0000000000000014 R_X86_64_32 .text+0x0000000000001ec2 -> 0000000000000018 R_X86_64_32 .text+0x00000000000034e2 -> 000000000000001c R_X86_64_32 .text+0x0000000000003536 -> -> and then when I look more closely (objdump --disassemble), I see that -> the offset 000c81 in the module refers to this: -> -> 0000000000000c60 <nvme_admin_init_request>: -> .... -> c7f: 0f 0b ud2 -> c81: 0f 1f 44 00 00 nopl 0x0(%rax,%rax,1) -> -> so it very much looks like those relocations are still around on -> modules, and so module loading fails. -> -> Anyway, those annotations are completely bogus anyway, it looks. You -> guys should use relative offsets in order to be able to specify a -> kernel address. So doing -> -> .long %c0 -> -> is garbage - either it needs to be a .quad, or it needs to be relative -> to the text section to fit in a .long. -> -> Hmm? Revert or fix, but please quickly... - -Yuck, sorry about that. Patch to fix it below. - -This also highlights another (minor) issue: the '__unreachable' section -is meant to be a compile-time-only thing. It's supposed to be discarded -at link time, but apparently that isn't happening for modules. - -I tried excluding it from linking with the .pushsection "e" flag, but no -luck. I'll try to figure out how to fix that shortly. - -In the meantime, here's the fix you need. It now uses X86_64_64 -relocations. - ----- - -From: Josh Poimboeuf <jpoimboe@redhat.com> -Subject: [PATCH] objtool: fix __unreachable section relocation size - -Linus reported the following commit broke module loading on his laptop: - - d1091c7fa3d5 ("objtool: Improve detection of BUG() and other dead ends") - -It showed errors like the following: - - module: overflow in relocation type 10 val ffffffffc02afc81 - module: 'nvme' likely not compiled with -mcmodel=kernel - -The problem is that the __unreachable section addresses are stored using -the '.long' asm directive, which isn't big enough for .text section -relative kernel addresses. Use '.quad' instead. - -Reported-by: Linus Torvalds <torvalds@linux-foundation.org> -Suggested-by: Linus Torvalds <torvalds@linux-foundation.org> -Fixes: d1091c7fa3d5 ("objtool: Improve detection of BUG() and other dead ends") -Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> ---- - include/linux/compiler-gcc.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/include/linux/compiler-gcc.h b/include/linux/compiler-gcc.h -index 76e28c2..91a77a5 100644 ---- a/include/linux/compiler-gcc.h -+++ b/include/linux/compiler-gcc.h -@@ -201,7 +201,7 @@ - #define annotate_unreachable() ({ \ - asm("%c0:\t\n" \ - ".pushsection __unreachable, \"a\"\t\n" \ -- ".long %c0b\t\n" \ -+ ".quad %c0b\t\n" \ - ".popsection\t\n" : : "i" (__LINE__)); \ - }) - #else --- -2.7.4 - @@ -1,3 +1,3 @@ SHA512 (linux-4.10.tar.xz) = c3690125a8402df638095bd98a613fcf1a257b81de7611c84711d315cd11e2634ab4636302b3742aedf1e3ba9ce0fea53fe8c7d48e37865d8ee5db3565220d90 SHA512 (perf-man-4.10.tar.gz) = 2c830e06f47211d70a8330961487af73a8bc01073019475e6b6131d3bb8c95658b77ca0ae5f1b44371accf103658bc5a3a4366b3e017a4088a8fd408dd6867e8 -SHA512 (patch-4.10-git7.xz) = a1b1a02964417fca4d131be78f5881a53b6c1b54aef0a847aff1cd8108cd8681ce2bac92e8ea6cc24e2a474b7f801f0021bfd15c4b8e940462dffa6dc9c35af7 +SHA512 (patch-4.10-git8.xz) = 30b9a9a06a4795cf208e16274bc4dd4731c1af758cb9510ab77a8347100712a56d20d9697f1dd1420c89d039110dadb8379b1dc3bbe0834207afba97291043a2 |