From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by mx.groups.io with SMTP id smtpd.web12.9343.1652187103690111753 for ; Tue, 10 May 2022 05:51:43 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=L/X8PIUi; spf=pass (domain: intel.com, ip: 134.134.136.126, mailfrom: sebastien.boeuf@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1652187103; x=1683723103; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=IL1LcYOgwjPIcO+xrjo5ZtG/XIhVG2npVB9U11MMgpQ=; b=L/X8PIUijtJiFlWRtwHwPd141NQfmNkvS9hmb1nS7Img/fZ8fhLKfNK/ CkUOxSOSQ/65UVGKoS1f3o6B5fa3j/mKuIhpPprxcmL6TCoubpXishCh9 d98l/7kul65mCQ9xY1R1ptojxuaURYx/wjqatrQZYpnbLqsKR83rdL/dj ++PLPKt0ii3AoT3bTJmSzO/Bsi1jeRfJiFeWulZeKIihPOOUWs5y67gn7 d9a6f3zRwMmgo9bR8Nvt8J/OH1VRZ6Hmo6BaH+1r7B4azXweaLjouhm4A S0r0m6DSCwUu6jpgmMn2LoEo1Lf8oEelzKMXpl2ARJcqnw/u3vO18zPSW Q==; X-IronPort-AV: E=McAfee;i="6400,9594,10342"; a="251411633" X-IronPort-AV: E=Sophos;i="5.91,214,1647327600"; d="scan'208";a="251411633" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 May 2022 05:51:41 -0700 X-IronPort-AV: E=Sophos;i="5.91,214,1647327600"; d="scan'208";a="593493593" Received: from amrutaya-mobl1.gar.corp.intel.com (HELO sboeuf-mobl.intel.com) ([10.251.220.13]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 May 2022 05:51:39 -0700 From: "Boeuf, Sebastien" To: devel@edk2.groups.io Cc: jiewen.yao@intel.com, jordan.l.justen@intel.com, kraxel@redhat.com, sebastien.boeuf@intel.com Subject: [PATCH 4/4] OvmfPkg: Don't access A20 gate register on Cloud Hypervisor Date: Tue, 10 May 2022 14:50:46 +0200 Message-Id: <4e4441639e49bfbca5bf9f36cf26f3933eadf8f0.1652186234.git.sebastien.boeuf@intel.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable From: Sebastien Boeuf Since Cloud Hypervisor doesn't emulate an A20 gate register on I/O port 0x92, it's better to avoid accessing it when the platform is identified as Cloud Hypervisor. Signed-off-by: Sebastien Boeuf --- OvmfPkg/Library/PlatformInitLib/Platform.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/OvmfPkg/Library/PlatformInitLib/Platform.c b/OvmfPkg/Library/P= latformInitLib/Platform.c index cb1a893aef..f2b07dc937 100644 --- a/OvmfPkg/Library/PlatformInitLib/Platform.c +++ b/OvmfPkg/Library/PlatformInitLib/Platform.c @@ -314,7 +314,9 @@ PlatformMiscInitialization ( // // Disable A20 Mask // - IoOr8 (0x92, BIT1); + if (PlatformInfoHob->HostBridgeDevId !=3D CLOUDHV_DEVICE_ID) { + IoOr8 (0x92, BIT1); + } = // // Build the CPU HOB with guest RAM size dependent address width and 16-= bits -- = 2.32.0 --------------------------------------------------------------------- Intel Corporation SAS (French simplified joint stock company) Registered headquarters: "Les Montalets"- 2, rue de Paris, = 92196 Meudon Cedex, France Registration Number: 302 456 199 R.C.S. NANTERRE Capital: 5 208 026.16 Euros This e-mail and any attachments may contain confidential material for the sole use of the intended recipient(s). Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies.