Re: [PATCH] x86/sev-es: Do not use copy_from_kernel_nofault in early #VC handler

From: Dave Hansen
Date: Thu Sep 07 2023 - 18:45:23 EST


On 9/7/23 15:30, Adam Dunlap wrote:
>> In any case, the most straightforward way out of this mess is to
>> just move boot_cpu_data out of .bss and explicitly initialize it
>> along with some documentation explaining the situation.
> That seems totally reasonable. I tried applying the two patches that
> you sent plus boot_cpu_data.x86_virt_bits = 0; in early_setup_idt(),

Let's just initialize boot_cpu_data to zero and get it out of .bss entirely.

> and that fixes the problems that we can see. Do you want me to send
> out a new patch with these changes together?
Well, ideally broken out in a couple of patches, but yeah, please resend
also with some revised changelogs based on what you've learned.