[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160816134928.GC11106@nazgul.tnic>
Date: Tue, 16 Aug 2016 15:49:28 +0200
From: Borislav Petkov <bp@...en8.de>
To: Brian Gerst <brgerst@...il.com>
Cc: Baoquan He <bhe@...hat.com>, Yinghai Lu <yinghai@...nel.org>,
Juergen Gross <jgross@...e.com>,
Thomas Garnier <thgarnie@...gle.com>,
Andy Lutomirski <luto@...nel.org>,
"H. Peter Anvin" <hpa@...or.com>,
Alexander Kuleshov <kuleshovmail@...il.com>,
Josh Poimboeuf <jpoimboe@...hat.com>, borntraeger@...ibm.com,
sds@...ho.nsa.gov, kirill.shutemov@...ux.intel.com,
jroedel@...e.de, Kees Cook <keescook@...omium.org>,
"Williams, Dan J" <dan.j.williams@...el.com>,
Mark Salter <msalter@...hat.com>, Borislav Petkov <bp@...e.de>,
Jonathan Corbet <corbet@....net>, matt@...eblueprint.co.uk,
guangrong.xiao@...ux.intel.com, aneesh.kumar@...ux.vnet.ibm.com,
Ingo Molnar <mingo@...nel.org>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Dave Hansen <dave.hansen@...ux.intel.com>, toshi.kani@....com,
alpopov@...ecurity.com,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Jan Beulich <JBeulich@...e.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Boris Ostrovsky <boris.ostrovsky@...cle.com>,
Denys Vlasenko <dvlasenk@...hat.com>,
Peter Zijlstra <peterz@...radead.org>, dyoung@...hat.com,
Thomas Gleixner <tglx@...utronix.de>,
Dmitry Vyukov <dvyukov@...gle.com>, lv.zheng@...el.com,
schwidefsky@...ibm.com, linux-tip-commits@...r.kernel.org
Subject: Re: [tip:x86/boot] x86/mm: Enable KASLR for physical mapping memory
regions
On Tue, Aug 16, 2016 at 03:42:05PM +0200, Borislav Petkov wrote:
> I'll try to reproduce and fix this at some point but am away currently
> so don't hold your breath. Does "dis_ucode_ldr" on the kernel cmdline
> get you any further?
Just a stab in the dark: does something like that help?
---
diff --git a/arch/x86/kernel/cpu/microcode/amd.c b/arch/x86/kernel/cpu/microcode/amd.c
index 27a0228c9cae..2debaf119baf 100644
--- a/arch/x86/kernel/cpu/microcode/amd.c
+++ b/arch/x86/kernel/cpu/microcode/amd.c
@@ -434,6 +434,10 @@ int __init save_microcode_in_initrd_amd(void)
else
container = cont_va;
+#ifdef CONFIG_RANDOMIZE_MEMORY
+ container += PAGE_OFFSET - __PAGE_OFFSET_BASE;
+#endif
+
eax = cpuid_eax(0x00000001);
eax = ((eax >> 8) & 0xf) + ((eax >> 20) & 0xff);
---
Thanks.
--
Regards/Gruss,
Boris.
ECO tip #101: Trim your mails when you reply.
--
Powered by blists - more mailing lists