From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.groups.io with SMTP id smtpd.web10.43523.1674648612166146568 for ; Wed, 25 Jan 2023 04:10:12 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=CZgl5+uI; spf=pass (domain: redhat.com, ip: 170.10.129.124, mailfrom: kraxel@redhat.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1674648610; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=pF9YdUuMs9cdRgXx46UFNypOFLLIAw4dA1j7ZWX2A+c=; b=CZgl5+uIS2srcuMVG34qPJAbvaC/d/8MwOZCxrZHBcJ0KWgPC93NgGn2VuXjrquhRMotOL 2sAaCvHBpzOvL02aNrvb/kwqhrkqo+F6RZMIU68s00uFm46DGbd5twhusNAXRQQl6KugnK V31oHhk5Q9zu/I/7tQia3+od7+adygk= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-441-zdbfDd4TPOebz2wOUC0LaA-1; Wed, 25 Jan 2023 07:10:03 -0500 X-MC-Unique: zdbfDd4TPOebz2wOUC0LaA-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id EFE211C07550; Wed, 25 Jan 2023 12:10:02 +0000 (UTC) Received: from sirius.home.kraxel.org (unknown [10.39.192.186]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A55ED422F2; Wed, 25 Jan 2023 12:10:02 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 355D71800623; Wed, 25 Jan 2023 13:10:01 +0100 (CET) Date: Wed, 25 Jan 2023 13:10:01 +0100 From: "Gerd Hoffmann" To: Ard Biesheuvel Cc: devel@edk2.groups.io, thomas.lendacky@amd.com, dave.hansen@intel.com, dionnaglaze@google.com, dave.hansen@linux.intel.com, Jiewen , "Shutemov, Kirill" Subject: Re: [edk2-devel] [PATCH v9 0/4] Add safe unaccepted memory behavior Message-ID: <20230125121001.jnmlfkqheeqzygcw@sirius.home.kraxel.org> References: <16581.1673625639418051810@groups.io> <0918b9db-c949-75ce-a24e-f12f03865938@intel.com> <20230116102801.y3l6xn3gdgregn4k@sirius.home.kraxel.org> <20230125091802.yya2a3cqlcmxzv2x@sirius.home.kraxel.org> MIME-Version: 1.0 In-Reply-To: X-Scanned-By: MIMEDefang 3.1 on 10.11.54.5 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Jan 25, 2023 at 12:44:13PM +0100, Ard Biesheuvel wrote: > On Wed, 25 Jan 2023 at 10:18, Gerd Hoffmann wrote: > > > > On Wed, Jan 25, 2023 at 10:01:47AM +0100, Ard Biesheuvel wrote: > > > > > Exactly. And my Fedora kernel has those bits enabled by default. > > > > > > So I suppose the way forward here is to expose this protocol only on > > > OVMF builds that target SEV-SNP, instead of introducing it as a > > > generic CoCo feature. > > > > OVMF builds already adapt at runtime, so this needs to be a runtime > > check too. But IIRC the module already checks whenever SNP-SEV or TDX > > is active before installing, so we only need to tweak that check to drop > > the TDX check. > > > > Sure. But Dionna's series introduces a new CocoDxe driver that is > intended to carry shared logic, but we should probably add this stuff > to AmdSevDxe instead. OvmfPkgX64.dsc can run in SEV/TDX modes too, so it is needed there as well. We can probably leave it out from IntelTdx (assuming Intel's upstream merge plans work out as expected and tdx-guest + unaccepted memory actually land in the same kernel release). take care, Gerd