[PATCH] UefiPayloadPkg: Add Macro to enable or diable some drivers.


Ma, Maurice
 

Reviewed-by: Maurice Ma <maurice.ma@intel.com>

-----Original Message-----
From: Liu, Zhiguang <zhiguang.liu@intel.com>
Sent: Saturday, September 18, 2021 0:49
To: devel@edk2.groups.io
Cc: Dong, Guo <guo.dong@intel.com>; Ni, Ray <ray.ni@intel.com>; Ma,
Maurice <maurice.ma@intel.com>; You, Benjamin
<benjamin.you@intel.com>
Subject: [PATCH] UefiPayloadPkg: Add Macro to enable or diable some
drivers.

Add Macro to enable or diable RamDiskDxe and SioBusDxe drivers.

Cc: Guo Dong <guo.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Maurice Ma <maurice.ma@intel.com>
Cc: Benjamin You <benjamin.you@intel.com>

Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com>
---
UefiPayloadPkg/UefiPayloadPkg.dsc | 10 ++++++++--
UefiPayloadPkg/UefiPayloadPkg.fdf | 7 +++++--
2 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/UefiPayloadPkg/UefiPayloadPkg.dsc
b/UefiPayloadPkg/UefiPayloadPkg.dsc
index 9d7f311343..fb805dc772 100644
--- a/UefiPayloadPkg/UefiPayloadPkg.dsc
+++ b/UefiPayloadPkg/UefiPayloadPkg.dsc
@@ -28,6 +28,8 @@
DEFINE SOURCE_DEBUG_ENABLE = FALSE DEFINE
PS2_KEYBOARD_ENABLE = FALSE+ DEFINE RAM_DISK_ENABLE =
FALSE+ DEFINE SIO_BUS_ENABLE = FALSE DEFINE
UNIVERSAL_PAYLOAD = FALSE #@@ -536,8 +538,10 @@
MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf
MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf
MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpressDxe.inf-
MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf +!if
$(RAM_DISK_ENABLE) == TRUE+
MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf+!endif # #
SD/eMMC Support #@@ -562,8 +566,10 @@
!if $(SERIAL_DRIVER_ENABLE) == TRUE
MdeModulePkg/Universal/SerialDxe/SerialDxe.inf !endif-!if
$(PS2_KEYBOARD_ENABLE) == TRUE+!if $(SIO_BUS_ENABLE) == TRUE
OvmfPkg/SioBusDxe/SioBusDxe.inf+!endif+!if $(PS2_KEYBOARD_ENABLE)
== TRUE
MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf !endif
MdeModulePkg/Bus/Isa/Ps2MouseDxe/Ps2MouseDxe.infdiff --git
a/UefiPayloadPkg/UefiPayloadPkg.fdf b/UefiPayloadPkg/UefiPayloadPkg.fdf
index 6caa134081..6b48bfc869 100644
--- a/UefiPayloadPkg/UefiPayloadPkg.fdf
+++ b/UefiPayloadPkg/UefiPayloadPkg.fdf
@@ -142,8 +142,10 @@ INF
MdeModulePkg/Bus/Pci/PciHostBridgeDxe/PciHostBridgeDxe.inf
!if $(SERIAL_DRIVER_ENABLE) == TRUE INF
MdeModulePkg/Universal/SerialDxe/SerialDxe.inf !endif-!if
$(PS2_KEYBOARD_ENABLE) == TRUE+!if $(SIO_BUS_ENABLE) == TRUE INF
OvmfPkg/SioBusDxe/SioBusDxe.inf+!endif+!if $(PS2_KEYBOARD_ENABLE)
== TRUE INF
MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf !endif INF
MdeModulePkg/Bus/Isa/Ps2MouseDxe/Ps2MouseDxe.inf@@ -171,8 +173,9
@@ INF MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.inf
INF MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf INF
MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf INF
MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpressDxe.inf+!if
$(RAM_DISK_ENABLE) == TRUE INF
MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf-+!endif INF
FatPkg/EnhancedFatDxe/Fat.inf #--
2.32.0.windows.2


Ni, Ray
 

Reviewed-by: Ray Ni <ray.ni@intel.com>

-----Original Message-----
From: Liu, Zhiguang <zhiguang.liu@intel.com>
Sent: Saturday, September 18, 2021 3:49 PM
To: devel@edk2.groups.io
Cc: Dong, Guo <guo.dong@intel.com>; Ni, Ray <ray.ni@intel.com>; Ma, Maurice <maurice.ma@intel.com>; You, Benjamin <benjamin.you@intel.com>
Subject: [PATCH] UefiPayloadPkg: Add Macro to enable or diable some drivers.

Add Macro to enable or diable RamDiskDxe and SioBusDxe drivers.

Cc: Guo Dong <guo.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Maurice Ma <maurice.ma@intel.com>
Cc: Benjamin You <benjamin.you@intel.com>

Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com>
---
UefiPayloadPkg/UefiPayloadPkg.dsc | 10 ++++++++--
UefiPayloadPkg/UefiPayloadPkg.fdf | 7 +++++--
2 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/UefiPayloadPkg/UefiPayloadPkg.dsc b/UefiPayloadPkg/UefiPayloadPkg.dsc
index 9d7f311343..fb805dc772 100644
--- a/UefiPayloadPkg/UefiPayloadPkg.dsc
+++ b/UefiPayloadPkg/UefiPayloadPkg.dsc
@@ -28,6 +28,8 @@


DEFINE SOURCE_DEBUG_ENABLE = FALSE

DEFINE PS2_KEYBOARD_ENABLE = FALSE

+ DEFINE RAM_DISK_ENABLE = FALSE

+ DEFINE SIO_BUS_ENABLE = FALSE

DEFINE UNIVERSAL_PAYLOAD = FALSE



#

@@ -536,8 +538,10 @@
MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf

MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf

MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpressDxe.inf

- MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf



+!if $(RAM_DISK_ENABLE) == TRUE

+ MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf

+!endif

#

# SD/eMMC Support

#

@@ -562,8 +566,10 @@
!if $(SERIAL_DRIVER_ENABLE) == TRUE

MdeModulePkg/Universal/SerialDxe/SerialDxe.inf

!endif

-!if $(PS2_KEYBOARD_ENABLE) == TRUE

+!if $(SIO_BUS_ENABLE) == TRUE

OvmfPkg/SioBusDxe/SioBusDxe.inf

+!endif

+!if $(PS2_KEYBOARD_ENABLE) == TRUE

MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf

!endif

MdeModulePkg/Bus/Isa/Ps2MouseDxe/Ps2MouseDxe.inf

diff --git a/UefiPayloadPkg/UefiPayloadPkg.fdf b/UefiPayloadPkg/UefiPayloadPkg.fdf
index 6caa134081..6b48bfc869 100644
--- a/UefiPayloadPkg/UefiPayloadPkg.fdf
+++ b/UefiPayloadPkg/UefiPayloadPkg.fdf
@@ -142,8 +142,10 @@ INF MdeModulePkg/Bus/Pci/PciHostBridgeDxe/PciHostBridgeDxe.inf
!if $(SERIAL_DRIVER_ENABLE) == TRUE

INF MdeModulePkg/Universal/SerialDxe/SerialDxe.inf

!endif

-!if $(PS2_KEYBOARD_ENABLE) == TRUE

+!if $(SIO_BUS_ENABLE) == TRUE

INF OvmfPkg/SioBusDxe/SioBusDxe.inf

+!endif

+!if $(PS2_KEYBOARD_ENABLE) == TRUE

INF MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf

!endif

INF MdeModulePkg/Bus/Isa/Ps2MouseDxe/Ps2MouseDxe.inf

@@ -171,8 +173,9 @@ INF MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.inf
INF MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf

INF MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf

INF MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpressDxe.inf

+!if $(RAM_DISK_ENABLE) == TRUE

INF MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf

-

+!endif

INF FatPkg/EnhancedFatDxe/Fat.inf



#

--
2.32.0.windows.2


Zhiguang Liu
 

Add Macro to enable or diable RamDiskDxe and SioBusDxe drivers.

Cc: Guo Dong <guo.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Maurice Ma <maurice.ma@intel.com>
Cc: Benjamin You <benjamin.you@intel.com>

Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com>
---
UefiPayloadPkg/UefiPayloadPkg.dsc | 10 ++++++++--
UefiPayloadPkg/UefiPayloadPkg.fdf | 7 +++++--
2 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/UefiPayloadPkg/UefiPayloadPkg.dsc b/UefiPayloadPkg/UefiPayload=
Pkg.dsc
index 9d7f311343..fb805dc772 100644
--- a/UefiPayloadPkg/UefiPayloadPkg.dsc
+++ b/UefiPayloadPkg/UefiPayloadPkg.dsc
@@ -28,6 +28,8 @@
=0D
DEFINE SOURCE_DEBUG_ENABLE =3D FALSE=0D
DEFINE PS2_KEYBOARD_ENABLE =3D FALSE=0D
+ DEFINE RAM_DISK_ENABLE =3D FALSE=0D
+ DEFINE SIO_BUS_ENABLE =3D FALSE=0D
DEFINE UNIVERSAL_PAYLOAD =3D FALSE=0D
=0D
#=0D
@@ -536,8 +538,10 @@
MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf=0D
MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf=0D
MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpressDxe.inf=0D
- MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf=0D
=0D
+!if $(RAM_DISK_ENABLE) =3D=3D TRUE=0D
+ MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf=0D
+!endif=0D
#=0D
# SD/eMMC Support=0D
#=0D
@@ -562,8 +566,10 @@
!if $(SERIAL_DRIVER_ENABLE) =3D=3D TRUE=0D
MdeModulePkg/Universal/SerialDxe/SerialDxe.inf=0D
!endif=0D
-!if $(PS2_KEYBOARD_ENABLE) =3D=3D TRUE=0D
+!if $(SIO_BUS_ENABLE) =3D=3D TRUE=0D
OvmfPkg/SioBusDxe/SioBusDxe.inf=0D
+!endif=0D
+!if $(PS2_KEYBOARD_ENABLE) =3D=3D TRUE=0D
MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf=0D
!endif=0D
MdeModulePkg/Bus/Isa/Ps2MouseDxe/Ps2MouseDxe.inf=0D
diff --git a/UefiPayloadPkg/UefiPayloadPkg.fdf b/UefiPayloadPkg/UefiPayload=
Pkg.fdf
index 6caa134081..6b48bfc869 100644
--- a/UefiPayloadPkg/UefiPayloadPkg.fdf
+++ b/UefiPayloadPkg/UefiPayloadPkg.fdf
@@ -142,8 +142,10 @@ INF MdeModulePkg/Bus/Pci/PciHostBridgeDxe/PciHostBridg=
eDxe.inf
!if $(SERIAL_DRIVER_ENABLE) =3D=3D TRUE=0D
INF MdeModulePkg/Universal/SerialDxe/SerialDxe.inf=0D
!endif=0D
-!if $(PS2_KEYBOARD_ENABLE) =3D=3D TRUE=0D
+!if $(SIO_BUS_ENABLE) =3D=3D TRUE=0D
INF OvmfPkg/SioBusDxe/SioBusDxe.inf=0D
+!endif=0D
+!if $(PS2_KEYBOARD_ENABLE) =3D=3D TRUE=0D
INF MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf=0D
!endif=0D
INF MdeModulePkg/Bus/Isa/Ps2MouseDxe/Ps2MouseDxe.inf=0D
@@ -171,8 +173,9 @@ INF MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassT=
hru.inf
INF MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf=0D
INF MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf=0D
INF MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpressDxe.inf=0D
+!if $(RAM_DISK_ENABLE) =3D=3D TRUE=0D
INF MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf=0D
-=0D
+!endif=0D
INF FatPkg/EnhancedFatDxe/Fat.inf=0D
=0D
#=0D
--=20
2.32.0.windows.2