Commit 00d9e152 authored by Michael Ellerman's avatar Michael Ellerman Committed by Marcelo Henrique Cerri

UBUNTU: SAUCE: rfi-flush: Expand the RFI section to two nop slots

CVE-2017-5754

BugLink: http://bugs.launchpad.net/bugs/1742772Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Signed-off-by: default avatarMarcelo Henrique Cerri <marcelo.cerri@canonical.com>
parent e1f3564b
...@@ -58,10 +58,12 @@ ...@@ -58,10 +58,12 @@
*/ */
#define PREPARE_RFI_TO_USER \ #define PREPARE_RFI_TO_USER \
RFI_FLUSH_FIXUP_SECTION; \ RFI_FLUSH_FIXUP_SECTION; \
nop; \
nop nop
#define PREPARE_RFI_TO_GUEST \ #define PREPARE_RFI_TO_GUEST \
RFI_FLUSH_FIXUP_SECTION; \ RFI_FLUSH_FIXUP_SECTION; \
nop; \
nop nop
#ifdef CONFIG_PPC_DEBUG_RFI #ifdef CONFIG_PPC_DEBUG_RFI
......
...@@ -142,7 +142,8 @@ void do_rfi_flush_fixups(enum l1d_flush_type types) ...@@ -142,7 +142,8 @@ void do_rfi_flush_fixups(enum l1d_flush_type types)
dest = (void *)start + *start; dest = (void *)start + *start;
pr_devel("patching dest %lx\n", (unsigned long)dest); pr_devel("patching dest %lx\n", (unsigned long)dest);
patch_instruction(dest, instr); patch_instruction(dest, 0x60000000);
patch_instruction(dest + 1, instr);
} }
printk(KERN_DEBUG "rfi-fixups: patched %d locations\n", i); printk(KERN_DEBUG "rfi-fixups: patched %d locations\n", i);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment