lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Fri, 15 Oct 2021 00:45:15 +0000
From:   Sean Christopherson <>
To:     Tom Lendacky <>
Cc:     "Kuppuswamy, Sathyanarayanan" 
        Thomas Gleixner <>,
        Ingo Molnar <>, Borislav Petkov <>,, "H . Peter Anvin" <>,
        Dave Hansen <>,
        Tony Luck <>,
        Dan Williams <>,
        Andi Kleen <>,
        Kirill Shutemov <>,
        Kuppuswamy Sathyanarayanan <>,
Subject: Re: [PATCH v6 05/10] x86/tdx: Handle port I/O

On Thu, Sep 23, 2021, Tom Lendacky wrote:
> On 9/23/21 12:24 PM, Kuppuswamy, Sathyanarayanan wrote:
> > Any reason for using sev_enable_key over CC attribute? IMO, CC attribute
> > exist to generalize the common feature code. My impression is SEV is
> > specific to AMD code.

Unless CC attributes have static_<whatever> support, that would add a CMP+Jcc to
every I/O instruction in the kernel.

> When the SEV series was initially submitted, it originally did an
> sev_active() check. For various reasons a static key and the
> sev_key_active() call was requested.
> My suggestion was to change the name to something that doesn't have SEV/sev
> in it that can be used by both SEV and TDX. The sev_enable_key can be moved
> to a common file (maybe cc_platform.c) and renamed. Then
> arch/x86/include/asm/io.h can change the #ifdef from CONFIG_AMD_MEM_ENCRYPT
> Not sure if anyone else feels the same, though, so just my suggestion.

+1 to a static key to gate high volume and/or performance critical things that
are common to SEV and TDX.

Powered by blists - more mailing lists