From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f67.google.com (mail-wr1-f67.google.com [209.85.221.67]) by mx.groups.io with SMTP id smtpd.web12.588.1582743920671785961 for ; Wed, 26 Feb 2020 11:05:21 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=v/vmQJZi; spf=pass (domain: linaro.org, ip: 209.85.221.67, mailfrom: ard.biesheuvel@linaro.org) Received: by mail-wr1-f67.google.com with SMTP id v4so61730wrs.8 for ; Wed, 26 Feb 2020 11:05:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=Omf08FnHclUU7EPvbRVyhwY2bgizB7ghWs4z1iWI6yI=; b=v/vmQJZimjU4IaZrcf4NY4RKiuGTviYQUv3uWmbpxFmEz1pPb3tycIQV0SPn6cDhpM GEZHDcz3vmGrjmN7AzVHGXr+lFrtvzf7VoyaniRC0L9AlQ7YLP/hWUGtZq4qYNB14lWX gOrzcMN26cqyG/x717QYhPAAK4PyMngVDQwC/rWM70DZQVSkTgIz7BqtqSOI9/CUNE+M YcK2Al2o2hYur6UQ6NoAh09hIx6fYqItxRgAxieQRdhPdz3Cp0pEhmwXgNVqy9Vj3Eej g3v2P4MjrcWjSezGoaZHgzb8/QtBBbODyWxMjM17GytgOXVuPTI0JF/0oeJFrmtST3Kc Wubw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=Omf08FnHclUU7EPvbRVyhwY2bgizB7ghWs4z1iWI6yI=; b=unwVcPDixyKYaqoTGORmX4FBk8WGaMv5wOPXn6aTaR/gd5GCdTIh0UOWeH4FgIN0Cp n7B2fszbInQSxEYvqwAIbp450T/f6zqfw8zALPitA1wezooKPWANgMNxGaRYe4w1YM+H BY74wDOwVKlBQaECYEWzKDLn5SAnh4PQC1SU90f9StynJhriXDqTIJg+YflL5oJ0C5FO um2XAy9u0vq6jX/7KLTiFKbGyReJeoPcu/qAkl0Kn9cI7JhW10mwLB6OLrvbcB28HQH3 D/5Q4/fH7e24KEEWn1xTHnFvo371K4miMuhs+x4XHxQ3wdwpeB4GWpVtV8IJoC0xgeWV z9rA== X-Gm-Message-State: APjAAAUzQf/lWaLD49VUlC/mhaKG/p4v5Vr4S5CIxQhL4vSNHn71liKm GZ816vmiH31f0MFBeqb0IEhqbYCrxNeOiA== X-Google-Smtp-Source: APXvYqwSKxCF/0+PNdfKrd9FMwK9cditiyfLj1nT6YHyB/rykuGpFhIPUHlNs7Llc+9LZ63ZFGQzAQ== X-Received: by 2002:adf:f7c6:: with SMTP id a6mr122697wrq.164.1582743918995; Wed, 26 Feb 2020 11:05:18 -0800 (PST) Return-Path: Received: from e123331-lin.home ([2a01:cb1d:112:6f00:816e:ff0d:fb69:f613]) by smtp.gmail.com with ESMTPSA id z1sm3932823wmf.42.2020.02.26.11.05.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Feb 2020 11:05:18 -0800 (PST) From: "Ard Biesheuvel" To: devel@edk2.groups.io Cc: Ard Biesheuvel , lersek@redhat.com, eric.auger@redhat.com, philmd@redhat.com, marcandre.lureau@redhat.com, stefanb@linux.ibm.com, leif@nuviainc.com Subject: [PATCH v3 1/9] OvmfPkg/Tcg2ConfigPei: introduce a signalling PPI to depex on Date: Wed, 26 Feb 2020 20:05:06 +0100 Message-Id: <20200226190514.31395-2-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200226190514.31395-1-ard.biesheuvel@linaro.org> References: <20200226190514.31395-1-ard.biesheuvel@linaro.org> On ARM systems, the TPM does not live at a fixed address, and so we need the platform to discover it first. So introduce a PPI that signals that the TPM address has been discovered and recorded in the appropriate PCD, and make Tcg2ConfigPei depex on it when built for ARM or AARCH64. Reviewed-by: Laszlo Ersek Signed-off-by: Ard Biesheuvel --- OvmfPkg/OvmfPkg.dec | 5 +++++ OvmfPkg/Tcg/Tcg2Config/Tcg2ConfigPei.inf | 6 +++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/OvmfPkg/OvmfPkg.dec b/OvmfPkg/OvmfPkg.dec index 4c5b6511cb97..30faecb7a5c8 100644 --- a/OvmfPkg/OvmfPkg.dec +++ b/OvmfPkg/OvmfPkg.dec @@ -87,6 +87,11 @@ [Guids] gEfiLegacyBiosGuid = {0x2E3044AC, 0x879F, 0x490F, {0x97, 0x60, 0xBB, 0xDF, 0xAF, 0x69, 0x5F, 0x50}} gEfiLegacyDevOrderVariableGuid = {0xa56074db, 0x65fe, 0x45f7, {0xbd, 0x21, 0x2d, 0x2b, 0xdd, 0x8e, 0x96, 0x52}} +[Ppis] + # PPI whose presence in the PPI database signals that the TPM base address + # has been discovered and recorded + gOvmfTpmDiscoveredPpiGuid = {0xb9a61ad0, 0x2802, 0x41f3, {0xb5, 0x13, 0x96, 0x51, 0xce, 0x6b, 0xd5, 0x75}} + [Protocols] gVirtioDeviceProtocolGuid = {0xfa920010, 0x6785, 0x4941, {0xb6, 0xec, 0x49, 0x8c, 0x57, 0x9f, 0x16, 0x0a}} gXenBusProtocolGuid = {0x3d3ca290, 0xb9a5, 0x11e3, {0xb7, 0x5d, 0xb8, 0xac, 0x6f, 0x7d, 0x65, 0xe6}} diff --git a/OvmfPkg/Tcg/Tcg2Config/Tcg2ConfigPei.inf b/OvmfPkg/Tcg/Tcg2Config/Tcg2ConfigPei.inf index e34cd6210611..55684ba045b3 100644 --- a/OvmfPkg/Tcg/Tcg2Config/Tcg2ConfigPei.inf +++ b/OvmfPkg/Tcg/Tcg2Config/Tcg2ConfigPei.inf @@ -25,6 +25,7 @@ [Sources] [Packages] MdePkg/MdePkg.dec MdeModulePkg/MdeModulePkg.dec + OvmfPkg/OvmfPkg.dec SecurityPkg/SecurityPkg.dec [LibraryClasses] @@ -43,5 +44,8 @@ [Ppis] [Pcd] gEfiSecurityPkgTokenSpaceGuid.PcdTpmInstanceGuid ## PRODUCES -[Depex] +[Depex.IA32, Depex.X64] TRUE + +[Depex.ARM, Depex.AARCH64] + gOvmfTpmDiscoveredPpiGuid -- 2.17.1