lkml.org 
[lkml]   [2021]   [Jun]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC v2-fix-v2 1/1] x86: Introduce generic protected guest abstractionn
On Mon, Jun 07, 2021 at 10:55:44PM +0300, Kirill A. Shutemov wrote:
> I think conversions like this are wrong: relocate_kernel(), which got
> called here, only knows how to deal with SME, not how to handle some
> generic case.

What do you mean wrong? Wrong for TDX?

If so, then that can be

protected_guest_has(SME)

or so, which would be false on Intel.

And this patch was only a mechanical conversion to see how it would look
like.

> If code is written to handle a specific technology we need to stick
> with a check that makes it clear. Trying to make sound generic only
> leads to confusion.

Sure, fine by me.

And I don't want a zoo of gazillion small checking functions per
technology. sev_<something>, tdx_<something>, yadda yadda.

So stuff better be unified. Even if you'd have vendor-specific defines
you hand into that function - and you will have such - it is still much
saner than what it turns into with the AMD side of things.

--
Regards/Gruss,
Boris.

https://people.kernel.org/tglx/notes-about-netiquette

\
 
 \ /
  Last update: 2021-06-07 22:15    [W:0.570 / U:0.172 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site