Re: [PATCH 35/62] x86/sev-es: Setup per-cpu GHCBs for the runtime handler

2020-02-12 Thread Joerg Roedel
On Tue, Feb 11, 2020 at 02:46:11PM -0800, Andy Lutomirski wrote: > On Tue, Feb 11, 2020 at 5:53 AM Joerg Roedel wrote: > > +/* Runtime GHCBs */ > > +static DEFINE_PER_CPU_DECRYPTED(struct ghcb, ghcb_page) > > __aligned(PAGE_SIZE); > > Hmm. This is a largeish amount of memory on large non-SEV-ES

Re: [PATCH 35/62] x86/sev-es: Setup per-cpu GHCBs for the runtime handler

2020-02-11 Thread Andy Lutomirski
On Tue, Feb 11, 2020 at 5:53 AM Joerg Roedel wrote: > > From: Tom Lendacky > > The runtime handler needs a GHCB per CPU. Set them up and map them > unencrypted. > > Signed-off-by: Tom Lendacky > Signed-off-by: Joerg Roedel > --- > arch/x86/include/asm/mem_encrypt.h | 2 ++ > arch/x86/kernel/s

[PATCH 35/62] x86/sev-es: Setup per-cpu GHCBs for the runtime handler

2020-02-11 Thread Joerg Roedel
From: Tom Lendacky The runtime handler needs a GHCB per CPU. Set them up and map them unencrypted. Signed-off-by: Tom Lendacky Signed-off-by: Joerg Roedel --- arch/x86/include/asm/mem_encrypt.h | 2 ++ arch/x86/kernel/sev-es.c | 25 - arch/x86/kernel/traps.c