[lkml]   [2017]   [Oct]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 12/27] x86/msr: Restrict MSR access when the kernel is locked down
On Fri, Oct 20, 2017 at 09:48:16PM +0100, David Howells wrote:
> Alan Cox <> wrote:
> > There are a load of standard tools that use this so I think you are going
> > to need a whitelist. Can you at least log *which* MSR in the failing case
> > so a whitelist can be built over time ?
> And do you know where wrmsr_safe_regs() might be found? I can see things
> using it and exporting it, but no implementation, so I'm guessing it's
> macroised somewhere.

Looks the definition is in


#ifdef CONFIG_X86_64
* int {rdmsr,wrmsr}_safe_regs(u32 gprs[8]);
* reg layout: u32 gprs[eax, ecx, edx, ebx, esp, ebp, esi, edi]
.macro op_safe_regs op
pushq %rbx
pushq %r12

Joey Lee

 \ /
  Last update: 2017-10-22 17:49    [W:0.163 / U:5.848 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site