[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMBK9=ZY7UapTq3YxbjD5vhynBou_s9m4tK=oL-wfv-BoAXQ+g@mail.gmail.com>
Date: Thu, 7 Sep 2023 15:30:26 -0700
From: Adam Dunlap <acdunlap@...gle.com>
To: Dave Hansen <dave.hansen@...el.com>
Cc: linux-kernel@...r.kernel.org, x86@...nel.org,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
Dave Hansen <dave.hansen@...ux.intel.com>,
"H. Peter Anvin" <hpa@...or.com>,
Tom Lendacky <thomas.lendacky@....com>,
David Hildenbrand <david@...hat.com>,
Mike Rapoport <rppt@...nel.org>,
"Kirill A. Shutemov" <kirill.shutemov@...ux.intel.com>,
Nikunj A Dadhania <nikunj@....com>,
Dionna Glaze <dionnaglaze@...gle.com>,
"Peter Zijlstra (Intel)" <peterz@...radead.org>,
Joerg Roedel <jroedel@...e.de>, Jacob Xu <jacobhxu@...gle.com>
Subject: Re: [PATCH] x86/sev-es: Do not use copy_from_kernel_nofault in early
#VC handler
On Thu, Sep 7, 2023 at 12:12 PM Dave Hansen <dave.hansen@...el.com> wrote:
> What happens before this? This isn't the first CPUID
> invocation. Does this one just happen to #VC and all the others before
> don't?
I hadn't noticed this before, but there is an even earlier interrupt
handler vc_no_ghcb
which only supports cpuid. Potentially this version could work until
boot_cpu_data is
set up, but wasn't able to get it working myself.
> 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(), and that fixes
the problems
that we can see. Do you want me to send out a new patch with these changes
together?
Powered by blists - more mailing lists