]>
Commit | Line | Data |
---|---|---|
321d628a FG |
1 | From b90136e442c889a7344992acc34764729936ab92 Mon Sep 17 00:00:00 2001 |
2 | From: Josh Poimboeuf <jpoimboe@redhat.com> | |
3 | Date: Mon, 18 Sep 2017 21:43:36 -0500 | |
e4cdf2a5 | 4 | Subject: [PATCH 058/241] x86/xen: Add unwind hint annotations |
321d628a FG |
5 | MIME-Version: 1.0 |
6 | Content-Type: text/plain; charset=UTF-8 | |
7 | Content-Transfer-Encoding: 8bit | |
8 | ||
9 | CVE-2017-5754 | |
10 | ||
11 | Add unwind hint annotations to the xen head code so the ORC unwinder can | |
12 | read head_64.o. | |
13 | ||
14 | hypercall_page needs empty annotations at 32-byte intervals to match the | |
15 | 'xen_hypercall_*' ELF functions at those locations. | |
16 | ||
17 | Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> | |
18 | Cc: Andy Lutomirski <luto@kernel.org> | |
19 | Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com> | |
20 | Cc: Jiri Slaby <jslaby@suse.cz> | |
21 | Cc: Juergen Gross <jgross@suse.com> | |
22 | Cc: Linus Torvalds <torvalds@linux-foundation.org> | |
23 | Cc: Peter Zijlstra <peterz@infradead.org> | |
24 | Cc: Thomas Gleixner <tglx@linutronix.de> | |
25 | Link: http://lkml.kernel.org/r/70ed2eb516fe9266be766d953f93c2571bca88cc.1505764066.git.jpoimboe@redhat.com | |
26 | Signed-off-by: Ingo Molnar <mingo@kernel.org> | |
27 | (cherry picked from commit abbe1cac6214d81d2f4e149aba64a8760703144e) | |
28 | Signed-off-by: Andy Whitcroft <apw@canonical.com> | |
29 | Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com> | |
30 | (cherry picked from commit 9f099a90cb39eaff9b3187e8a6d8151c8af53db1) | |
31 | Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com> | |
32 | --- | |
33 | arch/x86/xen/xen-head.S | 7 ++++++- | |
34 | 1 file changed, 6 insertions(+), 1 deletion(-) | |
35 | ||
36 | diff --git a/arch/x86/xen/xen-head.S b/arch/x86/xen/xen-head.S | |
37 | index 2f0cff2cc265..ad189ab2c329 100644 | |
38 | --- a/arch/x86/xen/xen-head.S | |
39 | +++ b/arch/x86/xen/xen-head.S | |
40 | @@ -9,6 +9,7 @@ | |
41 | #include <asm/boot.h> | |
42 | #include <asm/asm.h> | |
43 | #include <asm/page_types.h> | |
44 | +#include <asm/unwind_hints.h> | |
45 | ||
46 | #include <xen/interface/elfnote.h> | |
47 | #include <xen/interface/features.h> | |
48 | @@ -19,6 +20,7 @@ | |
49 | #ifdef CONFIG_XEN_PV | |
50 | __INIT | |
51 | ENTRY(startup_xen) | |
52 | + UNWIND_HINT_EMPTY | |
53 | cld | |
54 | ||
55 | /* Clear .bss */ | |
56 | @@ -40,7 +42,10 @@ END(startup_xen) | |
57 | .pushsection .text | |
58 | .balign PAGE_SIZE | |
59 | ENTRY(hypercall_page) | |
60 | - .skip PAGE_SIZE | |
61 | + .rept (PAGE_SIZE / 32) | |
62 | + UNWIND_HINT_EMPTY | |
63 | + .skip 32 | |
64 | + .endr | |
65 | ||
66 | #define HYPERCALL(n) \ | |
67 | .equ xen_hypercall_##n, hypercall_page + __HYPERVISOR_##n * 32; \ | |
68 | -- | |
69 | 2.14.2 | |
70 |