From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=209.132.183.28; helo=mx1.redhat.com; envelope-from=lersek@redhat.com; receiver=edk2-devel@lists.01.org Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 841F1211EABAA for ; Mon, 25 Mar 2019 04:20:58 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 994BE8B967; Mon, 25 Mar 2019 11:20:55 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-120-188.rdu2.redhat.com [10.10.120.188]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1BFC160F90; Mon, 25 Mar 2019 11:20:53 +0000 (UTC) To: Hao Wu , edk2-devel@lists.01.org Cc: Jordan Justen , Ard Biesheuvel , Ray Ni References: <20190325052853.11220-1-hao.a.wu@intel.com> <20190325052853.11220-4-hao.a.wu@intel.com> From: Laszlo Ersek Message-ID: <20139f7a-1d72-0f20-7ff4-8d5a8330011a@redhat.com> Date: Mon, 25 Mar 2019 12:20:53 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20190325052853.11220-4-hao.a.wu@intel.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Mon, 25 Mar 2019 11:20:55 +0000 (UTC) Subject: Re: [PATCH v2 3/3] OvmfPkg: Add a build flag to select ISA driver stack X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Mar 2019 11:21:06 -0000 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit On 03/25/19 06:28, Hao Wu wrote: > REF:https://bugzilla.tianocore.org/show_bug.cgi?id=1495 > > This commit will add a static build flag 'USE_LEGACY_ISA_STACK' to select > the ISA driver stack. > > If the flag is set to TRUE, the below driver stack will be used: > PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > > If the flag is set to FALSE, the below driver stack will be used: > OvmfPkg/SioBusDxe/SioBusDxe.inf > MdeModulePkg/Bus/Pci/PciSioSerialDxe/PciSioSerialDxe.inf > MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf > > The default value is set to FALSE in OVMF DSC files. > > Cc: Jordan Justen > Cc: Laszlo Ersek > Cc: Ard Biesheuvel > Cc: Ray Ni > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Hao Wu > --- > OvmfPkg/OvmfPkgIa32.dsc | 6 ++++++ > OvmfPkg/OvmfPkgIa32X64.dsc | 6 ++++++ > OvmfPkg/OvmfPkgX64.dsc | 6 ++++++ > OvmfPkg/OvmfPkgIa32.fdf | 18 ++++++++++++------ > OvmfPkg/OvmfPkgIa32X64.fdf | 18 ++++++++++++------ > OvmfPkg/OvmfPkgX64.fdf | 18 ++++++++++++------ > 6 files changed, 54 insertions(+), 18 deletions(-) > > diff --git a/OvmfPkg/OvmfPkgIa32.dsc b/OvmfPkg/OvmfPkgIa32.dsc > index 3be0314146..f55ab5a3d2 100644 > --- a/OvmfPkg/OvmfPkgIa32.dsc > +++ b/OvmfPkg/OvmfPkgIa32.dsc > @@ -41,6 +41,7 @@ > DEFINE TLS_ENABLE = FALSE > DEFINE TPM2_ENABLE = FALSE > DEFINE TPM2_CONFIG_ENABLE = FALSE > + DEFINE USE_LEGACY_ISA_STACK = FALSE > > # > # Flash size selection. Setting FD_SIZE_IN_KB on the command line directly to > @@ -752,11 +753,16 @@ > # > # ISA Support > # > +!if $(USE_LEGACY_ISA_STACK) == FALSE > OvmfPkg/SioBusDxe/SioBusDxe.inf > + MdeModulePkg/Bus/Pci/PciSioSerialDxe/PciSioSerialDxe.inf > + MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf > +!else > PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > +!endif > > # > # SMBIOS Support > diff --git a/OvmfPkg/OvmfPkgIa32X64.dsc b/OvmfPkg/OvmfPkgIa32X64.dsc > index 3b85c2e6af..5c9bdf034e 100644 > --- a/OvmfPkg/OvmfPkgIa32X64.dsc > +++ b/OvmfPkg/OvmfPkgIa32X64.dsc > @@ -41,6 +41,7 @@ > DEFINE TLS_ENABLE = FALSE > DEFINE TPM2_ENABLE = FALSE > DEFINE TPM2_CONFIG_ENABLE = FALSE > + DEFINE USE_LEGACY_ISA_STACK = FALSE > > # > # Flash size selection. Setting FD_SIZE_IN_KB on the command line directly to > @@ -761,11 +762,16 @@ > # > # ISA Support > # > +!if $(USE_LEGACY_ISA_STACK) == FALSE > OvmfPkg/SioBusDxe/SioBusDxe.inf > + MdeModulePkg/Bus/Pci/PciSioSerialDxe/PciSioSerialDxe.inf > + MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf > +!else > PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > +!endif > > # > # SMBIOS Support > diff --git a/OvmfPkg/OvmfPkgX64.dsc b/OvmfPkg/OvmfPkgX64.dsc > index 104b2e79a5..2943e9e8af 100644 > --- a/OvmfPkg/OvmfPkgX64.dsc > +++ b/OvmfPkg/OvmfPkgX64.dsc > @@ -41,6 +41,7 @@ > DEFINE TLS_ENABLE = FALSE > DEFINE TPM2_ENABLE = FALSE > DEFINE TPM2_CONFIG_ENABLE = FALSE > + DEFINE USE_LEGACY_ISA_STACK = FALSE > > # > # Flash size selection. Setting FD_SIZE_IN_KB on the command line directly to > @@ -759,11 +760,16 @@ > # > # ISA Support > # > +!if $(USE_LEGACY_ISA_STACK) == FALSE > OvmfPkg/SioBusDxe/SioBusDxe.inf > + MdeModulePkg/Bus/Pci/PciSioSerialDxe/PciSioSerialDxe.inf > + MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf > +!else > PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > +!endif > > # > # SMBIOS Support > diff --git a/OvmfPkg/OvmfPkgIa32.fdf b/OvmfPkg/OvmfPkgIa32.fdf > index 54d7f06a70..006ea9a415 100644 > --- a/OvmfPkg/OvmfPkgIa32.fdf > +++ b/OvmfPkg/OvmfPkgIa32.fdf > @@ -265,14 +265,20 @@ INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf > INF MdeModulePkg/Universal/DisplayEngineDxe/DisplayEngineDxe.inf > INF MdeModulePkg/Universal/MemoryTest/NullMemoryTestDxe/NullMemoryTestDxe.inf > > -INF PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > -INF IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > - > +!if $(USE_LEGACY_ISA_STACK) == FALSE > + INF OvmfPkg/SioBusDxe/SioBusDxe.inf > !ifndef $(SOURCE_DEBUG_ENABLE) > -INF IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > + INF MdeModulePkg/Bus/Pci/PciSioSerialDxe/PciSioSerialDxe.inf > +!endif > + INF MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf > +!else > + INF PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > + INF IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > +!ifndef $(SOURCE_DEBUG_ENABLE) > + INF IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > +!endif > + INF IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > !endif > - > -INF IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > > INF MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf > INF OvmfPkg/SmbiosPlatformDxe/SmbiosPlatformDxe.inf > diff --git a/OvmfPkg/OvmfPkgIa32X64.fdf b/OvmfPkg/OvmfPkgIa32X64.fdf > index 7519b53a9b..6c40540202 100644 > --- a/OvmfPkg/OvmfPkgIa32X64.fdf > +++ b/OvmfPkg/OvmfPkgIa32X64.fdf > @@ -266,14 +266,20 @@ INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf > INF MdeModulePkg/Universal/DisplayEngineDxe/DisplayEngineDxe.inf > INF MdeModulePkg/Universal/MemoryTest/NullMemoryTestDxe/NullMemoryTestDxe.inf > > -INF PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > -INF IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > - > +!if $(USE_LEGACY_ISA_STACK) == FALSE > + INF OvmfPkg/SioBusDxe/SioBusDxe.inf > !ifndef $(SOURCE_DEBUG_ENABLE) > -INF IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > + INF MdeModulePkg/Bus/Pci/PciSioSerialDxe/PciSioSerialDxe.inf > +!endif > + INF MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf > +!else > + INF PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > + INF IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > +!ifndef $(SOURCE_DEBUG_ENABLE) > + INF IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > +!endif > + INF IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > !endif > - > -INF IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > > INF MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf > INF OvmfPkg/SmbiosPlatformDxe/SmbiosPlatformDxe.inf > diff --git a/OvmfPkg/OvmfPkgX64.fdf b/OvmfPkg/OvmfPkgX64.fdf > index 7519b53a9b..6c40540202 100644 > --- a/OvmfPkg/OvmfPkgX64.fdf > +++ b/OvmfPkg/OvmfPkgX64.fdf > @@ -266,14 +266,20 @@ INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf > INF MdeModulePkg/Universal/DisplayEngineDxe/DisplayEngineDxe.inf > INF MdeModulePkg/Universal/MemoryTest/NullMemoryTestDxe/NullMemoryTestDxe.inf > > -INF PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > -INF IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > - > +!if $(USE_LEGACY_ISA_STACK) == FALSE > + INF OvmfPkg/SioBusDxe/SioBusDxe.inf > !ifndef $(SOURCE_DEBUG_ENABLE) > -INF IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > + INF MdeModulePkg/Bus/Pci/PciSioSerialDxe/PciSioSerialDxe.inf > +!endif > + INF MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf > +!else > + INF PcAtChipsetPkg/IsaAcpiDxe/IsaAcpi.inf > + INF IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBusDxe.inf > +!ifndef $(SOURCE_DEBUG_ENABLE) > + INF IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf > +!endif > + INF IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > !endif > - > -INF IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf > > INF MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf > INF OvmfPkg/SmbiosPlatformDxe/SmbiosPlatformDxe.inf > Reviewed-by: Laszlo Ersek