* [Patch v2 1/4] Vlv2TbltDevicePkg: Make !if statement usage consistent
2016-12-01 22:07 [Patch v2 0/4] Fix SOURCE_DEBUG_ENABLE Michael Kinney
@ 2016-12-01 22:07 ` Michael Kinney
2016-12-01 22:07 ` [Patch v2 2/4] Vlv2TbltDevicePkg: Fix SOURCE_DEBUG_ENABLE feature Michael Kinney
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Michael Kinney @ 2016-12-01 22:07 UTC (permalink / raw)
To: edk2-devel; +Cc: Jiewen Yao, David Wei, Mang Guo
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: David Wei <david.wei@intel.com>
Cc: Mang Guo <mang.guo@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
---
Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc | 2 +-
Vlv2TbltDevicePkg/PlatformPkgX64.dsc | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc b/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
index 6da2a8a..5215c56 100644
--- a/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
+++ b/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
@@ -457,7 +457,7 @@
DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/DxeDebugAgentLib.inf
!endif
-!if $(CAPSULE_ENABLE)
+!if $(CAPSULE_ENABLE) == TRUE
CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibFmp/DxeRuntimeCapsuleLib.inf
!endif
diff --git a/Vlv2TbltDevicePkg/PlatformPkgX64.dsc b/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
index 54d2b81..cd9dee0 100644
--- a/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
+++ b/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
@@ -457,7 +457,7 @@
DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/DxeDebugAgentLib.inf
!endif
-!if $(CAPSULE_ENABLE)
+!if $(CAPSULE_ENABLE) == TRUE
CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibFmp/DxeRuntimeCapsuleLib.inf
!endif
--
2.6.3.windows.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [Patch v2 2/4] Vlv2TbltDevicePkg: Fix SOURCE_DEBUG_ENABLE feature
2016-12-01 22:07 [Patch v2 0/4] Fix SOURCE_DEBUG_ENABLE Michael Kinney
2016-12-01 22:07 ` [Patch v2 1/4] Vlv2TbltDevicePkg: Make !if statement usage consistent Michael Kinney
@ 2016-12-01 22:07 ` Michael Kinney
2016-12-01 22:07 ` [Patch v2 3/4] Vlv2TbltDevicePkg/PlatformBdsLib: Add DebugAgent Console Michael Kinney
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Michael Kinney @ 2016-12-01 22:07 UTC (permalink / raw)
To: edk2-devel; +Cc: Jiewen Yao, David Wei, Mang Guo
https://bugzilla.tianocore.org/show_bug.cgi?id=276
Fix library mapping and PCD settings required to use
the SOURCE_DEBUG_ENABLE feature in PEI, DXE, and SMM.
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: David Wei <david.wei@intel.com>
Cc: Mang Guo <mang.guo@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
---
Vlv2TbltDevicePkg/PlatformPkgIA32.dsc | 15 ++++++++-------
Vlv2TbltDevicePkg/PlatformPkgX64.dsc | 24 ++++++++++++++----------
2 files changed, 22 insertions(+), 17 deletions(-)
diff --git a/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc b/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc
index 5b5523f..9ec3f3b 100644
--- a/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc
+++ b/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc
@@ -338,8 +338,9 @@
LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxPeiLib.inf
HashLib|SecurityPkg/Library/HashLibBaseCryptoRouter/HashLibBaseCryptoRouterPei.inf
- PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
- DebugAgentLib|MdeModulePkg/Library/DebugAgentLibNull/DebugAgentLibNull.inf
+!if $(SOURCE_DEBUG_ENABLE) == TRUE
+ DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgentLib.inf
+!endif
!if $(MINNOW2_FSP_BUILD) == TRUE
PlatformFspLib|Vlv2TbltDevicePkg/Library/PlatformFspLib/PlatformFspLib.inf
@@ -439,11 +440,6 @@
DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
!endif
-!if $(SOURCE_DEBUG_ENABLE) == TRUE
- DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/DxeDebugAgentLib.inf
- TimerLib|$(PLATFORM_PACKAGE)/Library/IntelPchAcpiTimerLib/IntelPchAcpiTimerLib.inf
-!endif
-
[LibraryClasses.IA32.DXE_RUNTIME_DRIVER]
ReportStatusCodeLib|MdeModulePkg/Library/RuntimeDxeReportStatusCodeLib/RuntimeDxeReportStatusCodeLib.inf
!if $(SECURE_BOOT_ENABLE) == TRUE
@@ -616,6 +612,10 @@
gEfiCpuTokenSpaceGuid.PcdCpuSmmBlockStartupThisAp|TRUE
+!if $(SOURCE_DEBUG_ENABLE)
+ gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmDebug|TRUE
+!endif
+
[PcdsFixedAtBuild.common]
!if $(MINNOW2_FSP_BUILD) == TRUE
# $(FLASH_REGION_VLVMICROCODE_BASE)
@@ -694,6 +694,7 @@
gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x17
gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|0x07
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialUseHardwareFlowControl|FALSE
+ gEfiSourceLevelDebugPkgTokenSpaceGuid.PcdDebugLoadImageMethod|2
!endif
[PcdsFixedAtBuild.IA32.PEIM, PcdsFixedAtBuild.IA32.PEI_CORE, PcdsFixedAtBuild.IA32.SEC]
diff --git a/Vlv2TbltDevicePkg/PlatformPkgX64.dsc b/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
index cd9dee0..807860f 100644
--- a/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
+++ b/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
@@ -338,8 +338,9 @@
LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxPeiLib.inf
HashLib|SecurityPkg/Library/HashLibBaseCryptoRouter/HashLibBaseCryptoRouterPei.inf
- PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
- DebugAgentLib|MdeModulePkg/Library/DebugAgentLibNull/DebugAgentLibNull.inf
+!if $(SOURCE_DEBUG_ENABLE) == TRUE
+ DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgentLib.inf
+!endif
!if $(MINNOW2_FSP_BUILD) == TRUE
PlatformFspLib|Vlv2TbltDevicePkg/Library/PlatformFspLib/PlatformFspLib.inf
@@ -439,11 +440,6 @@
DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
!endif
-!if $(SOURCE_DEBUG_ENABLE) == TRUE
- DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/DxeDebugAgentLib.inf
- TimerLib|$(PLATFORM_PACKAGE)/Library/IntelPchAcpiTimerLib/IntelPchAcpiTimerLib.inf
-!endif
-
[LibraryClasses.X64.DXE_RUNTIME_DRIVER]
ReportStatusCodeLib|MdeModulePkg/Library/RuntimeDxeReportStatusCodeLib/RuntimeDxeReportStatusCodeLib.inf
!if $(SECURE_BOOT_ENABLE) == TRUE
@@ -616,6 +612,10 @@
gEfiCpuTokenSpaceGuid.PcdCpuSmmBlockStartupThisAp|TRUE
+!if $(SOURCE_DEBUG_ENABLE)
+ gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmDebug|TRUE
+!endif
+
[PcdsFixedAtBuild.common]
!if $(MINNOW2_FSP_BUILD) == TRUE
# $(FLASH_REGION_VLVMICROCODE_BASE)
@@ -694,6 +694,7 @@
gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x17
gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|0x07
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialUseHardwareFlowControl|FALSE
+ gEfiSourceLevelDebugPkgTokenSpaceGuid.PcdDebugLoadImageMethod|2
!endif
[PcdsFixedAtBuild.IA32.PEIM, PcdsFixedAtBuild.IA32.PEI_CORE, PcdsFixedAtBuild.IA32.SEC]
@@ -1152,9 +1153,12 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
!if $(CAPSULE_ENABLE) == TRUE
MdeModulePkg/Universal/CapsulePei/CapsuleX64.inf {
<LibraryClasses>
- PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf
- MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf
- HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
+ PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf
+ MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf
+ HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
+!if $(SOURCE_DEBUG_ENABLE) == TRUE
+ DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgentLib.inf
+!endif
}
!endif
--
2.6.3.windows.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [Patch v2 3/4] Vlv2TbltDevicePkg/PlatformBdsLib: Add DebugAgent Console
2016-12-01 22:07 [Patch v2 0/4] Fix SOURCE_DEBUG_ENABLE Michael Kinney
2016-12-01 22:07 ` [Patch v2 1/4] Vlv2TbltDevicePkg: Make !if statement usage consistent Michael Kinney
2016-12-01 22:07 ` [Patch v2 2/4] Vlv2TbltDevicePkg: Fix SOURCE_DEBUG_ENABLE feature Michael Kinney
@ 2016-12-01 22:07 ` Michael Kinney
2016-12-01 22:07 ` [Patch v2 4/4] Vlv2TbltDevicePkg: Update PlatformPkgGccX64.dsc Michael Kinney
2016-12-02 14:42 ` [Patch v2 0/4] Fix SOURCE_DEBUG_ENABLE Yao, Jiewen
4 siblings, 0 replies; 6+ messages in thread
From: Michael Kinney @ 2016-12-01 22:07 UTC (permalink / raw)
To: edk2-devel; +Cc: Jiewen Yao, David Wei, Mang Guo
https://bugzilla.tianocore.org/show_bug.cgi?id=276
Add the UART console produced by the DebugAgent when
SOURCE_DEBUG_ENABLE is TRUE. Without this change, the
debugger connects but the Boot Manager and the UEFI
Shell do not have an active console because the Boot
Manager does not know about the DebugAgent UART
Console device path and the Debug Agent is using the
UART device.
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: David Wei <david.wei@intel.com>
Cc: Mang Guo <mang.guo@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
---
.../Library/PlatformBdsLib/BdsPlatform.h | 13 +++++-
.../Library/PlatformBdsLib/PlatformBdsLib.inf | 1 +
.../Library/PlatformBdsLib/PlatformData.c | 48 +++++++++++++++++++++-
3 files changed, 60 insertions(+), 2 deletions(-)
diff --git a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.h b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.h
index d757243..807094f 100644
--- a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.h
+++ b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.h
@@ -1,6 +1,6 @@
/*++
- Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2004 - 2016, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials are licensed and made available under
the terms and conditions of the BSD License that accompanies this distribution.
@@ -46,6 +46,7 @@ Abstract:
#include <Guid/CapsuleVendor.h>
#include <Guid/MemoryTypeInformation.h>
#include <Guid/GlobalVariable.h>
+#include <Guid/DebugAgentGuid.h>
#include <Library/DebugLib.h>
@@ -281,6 +282,16 @@ typedef struct {
} PLATFORM_USB_DEVICE_PATH;
//
+// Debug Agent UART Console device path definition
+//
+typedef struct {
+ VENDOR_DEVICE_PATH VendorHardware;
+ UART_DEVICE_PATH Uart;
+ VENDOR_DEVICE_PATH TerminalType;
+ EFI_DEVICE_PATH_PROTOCOL End;
+} VENDOR_UART_DEVICE_PATH;
+
+//
// Below is the platform PCI device path
//
typedef struct {
diff --git a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformBdsLib.inf b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformBdsLib.inf
index 3e45a31..7512556 100644
--- a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformBdsLib.inf
+++ b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformBdsLib.inf
@@ -50,6 +50,7 @@
CryptoPkg/CryptoPkg.dec
SecurityPkg/SecurityPkg.dec
SignedCapsulePkg/SignedCapsulePkg.dec
+ SourceLevelDebugPkg/SourceLevelDebugPkg.dec
[LibraryClasses]
DxeServicesTableLib
diff --git a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformData.c b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformData.c
index 64e68d3..45bd32d 100644
--- a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformData.c
+++ b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformData.c
@@ -1,6 +1,6 @@
/** @file
- Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2004 - 2016, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials are licensed and made available under
the terms and conditions of the BSD License that accompanies this distribution.
@@ -119,12 +119,57 @@ USB_CLASS_FORMAT_DEVICE_PATH gUsbClassKeyboardDevicePath = {
};
//
+// Debug Agent UART Console device path
+//
+VENDOR_UART_DEVICE_PATH gDebugAgentUartDevicePath = {
+ {
+ {
+ HARDWARE_DEVICE_PATH,
+ HW_VENDOR_DP,
+ {
+ (UINT8) (sizeof (VENDOR_DEVICE_PATH)),
+ (UINT8) ((sizeof (VENDOR_DEVICE_PATH)) >> 8)
+ }
+ },
+ EFI_DEBUG_AGENT_GUID,
+ },
+ {
+ {
+ MESSAGING_DEVICE_PATH,
+ MSG_UART_DP,
+ {
+ (UINT8) (sizeof (UART_DEVICE_PATH)),
+ (UINT8) ((sizeof (UART_DEVICE_PATH)) >> 8)
+ }
+ },
+ 0, // Reserved
+ 0, // BaudRate - Default
+ 0, // DataBits - Default
+ 0, // Parity - Default
+ 0, // StopBits - Default
+ },
+ {
+ {
+ MESSAGING_DEVICE_PATH,
+ MSG_VENDOR_DP,
+ {
+ (UINT8)(sizeof (VENDOR_DEVICE_PATH)),
+ (UINT8)((sizeof (VENDOR_DEVICE_PATH)) >> 8)
+ }
+ },
+ DEVICE_PATH_MESSAGING_PC_ANSI
+ },
+ gEndEntire
+};
+
+//
// Predefined platform default console device path
//
BDS_CONSOLE_CONNECT_ENTRY gPlatformConsole [] = {
{(EFI_DEVICE_PATH_PROTOCOL*)&gIsaSerialDevicePath, CONSOLE_ALL},
{(EFI_DEVICE_PATH_PROTOCOL*)&gHiiVendorDevicePath0, CONSOLE_IN},
{(EFI_DEVICE_PATH_PROTOCOL*)&gIsaKeyboardDevicePath, CONSOLE_IN},
+ {(EFI_DEVICE_PATH_PROTOCOL*)&gDebugAgentUartDevicePath, CONSOLE_ALL},
{(EFI_DEVICE_PATH_PROTOCOL*)&gUsbClassKeyboardDevicePath, CONSOLE_IN},
{NULL, 0}
};
@@ -242,6 +287,7 @@ BDS_CONSOLE_CONNECT_ENTRY gPlatformSimpleConsole [] = {
{(EFI_DEVICE_PATH_PROTOCOL*)&gOnChipPciVgaDevicePath, CONSOLE_OUT},
{(EFI_DEVICE_PATH_PROTOCOL*)&gIsaSerialDevicePath, CONSOLE_ALL},
{(EFI_DEVICE_PATH_PROTOCOL*)&gHiiVendorDevicePath0, CONSOLE_IN},
+ {(EFI_DEVICE_PATH_PROTOCOL*)&gDebugAgentUartDevicePath, CONSOLE_ALL},
{(EFI_DEVICE_PATH_PROTOCOL*)&gUsbClassKeyboardDevicePath, CONSOLE_IN},
{NULL, 0}
};
--
2.6.3.windows.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [Patch v2 4/4] Vlv2TbltDevicePkg: Update PlatformPkgGccX64.dsc
2016-12-01 22:07 [Patch v2 0/4] Fix SOURCE_DEBUG_ENABLE Michael Kinney
` (2 preceding siblings ...)
2016-12-01 22:07 ` [Patch v2 3/4] Vlv2TbltDevicePkg/PlatformBdsLib: Add DebugAgent Console Michael Kinney
@ 2016-12-01 22:07 ` Michael Kinney
2016-12-02 14:42 ` [Patch v2 0/4] Fix SOURCE_DEBUG_ENABLE Yao, Jiewen
4 siblings, 0 replies; 6+ messages in thread
From: Michael Kinney @ 2016-12-01 22:07 UTC (permalink / raw)
To: edk2-devel; +Cc: Jiewen Yao, David Wei, Mang Guo
Update PlatformPkgGccX64.dsc to align with PlatformPkgX64.dsc
on library mappings and PCD settings.
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: David Wei <david.wei@intel.com>
Cc: Mang Guo <mang.guo@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
---
Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc | 75 +++++++++++++++------------------
1 file changed, 35 insertions(+), 40 deletions(-)
diff --git a/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc b/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
index 5215c56..9c3d4c4 100644
--- a/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
+++ b/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
@@ -227,8 +227,8 @@
DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
SerialPortLib|MdePkg/Library/BaseSerialPortLibNull/BaseSerialPortLibNull.inf
!else
- DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
- SerialPortLib|MdePkg/Library/BaseSerialPortLibNull/BaseSerialPortLibNull.inf
+ DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
+ SerialPortLib|$(PLATFORM_PACKAGE)/Library/SerialPortLib/SerialPortLib.inf
!endif
PerformanceLib|MdePkg/Library/BasePerformanceLibNull/BasePerformanceLibNull.inf
@@ -332,14 +332,15 @@
DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
SerialPortLib|MdePkg/Library/BaseSerialPortLibNull/BaseSerialPortLibNull.inf
!else
- DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
- SerialPortLib|MdePkg/Library/BaseSerialPortLibNull/BaseSerialPortLibNull.inf
+ DebugLib|IntelFrameworkModulePkg/Library/PeiDxeDebugLibReportStatusCode/PeiDxeDebugLibReportStatusCode.inf
+ SerialPortLib|$(PLATFORM_PACKAGE)/Library/SerialPortLib/SerialPortLib.inf
!endif
LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxPeiLib.inf
HashLib|SecurityPkg/Library/HashLibBaseCryptoRouter/HashLibBaseCryptoRouterPei.inf
- PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
- DebugAgentLib|MdeModulePkg/Library/DebugAgentLibNull/DebugAgentLibNull.inf
+!if $(SOURCE_DEBUG_ENABLE) == TRUE
+ DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgentLib.inf
+!endif
!if $(MINNOW2_FSP_BUILD) == TRUE
PlatformFspLib|Vlv2TbltDevicePkg/Library/PlatformFspLib/PlatformFspLib.inf
@@ -413,7 +414,7 @@
BaseCryptLib|CryptoPkg/Library/BaseCryptLib/SmmCryptLib.inf
!if $(TARGET) != RELEASE
- DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
+ DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
!endif
!if $(SOURCE_DEBUG_ENABLE) == TRUE
@@ -436,12 +437,7 @@
PerformanceLib|MdePkg/Library/BasePerformanceLibNull/BasePerformanceLibNull.inf
!if $(TARGET) != RELEASE
- DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
-!endif
-
-!if $(SOURCE_DEBUG_ENABLE) == TRUE
- DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/DxeDebugAgentLib.inf
- TimerLib|$(PLATFORM_PACKAGE)/Library/IntelPchAcpiTimerLib/IntelPchAcpiTimerLib.inf
+ DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
!endif
[LibraryClasses.X64.DXE_RUNTIME_DRIVER]
@@ -616,6 +612,10 @@
gEfiCpuTokenSpaceGuid.PcdCpuSmmBlockStartupThisAp|TRUE
+!if $(SOURCE_DEBUG_ENABLE)
+ gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmDebug|TRUE
+!endif
+
[PcdsFixedAtBuild.common]
!if $(MINNOW2_FSP_BUILD) == TRUE
# $(FLASH_REGION_VLVMICROCODE_BASE)
@@ -694,6 +694,7 @@
gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x17
gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|0x07
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialUseHardwareFlowControl|FALSE
+ gEfiSourceLevelDebugPkgTokenSpaceGuid.PcdDebugLoadImageMethod|2
!endif
[PcdsFixedAtBuild.IA32.PEIM, PcdsFixedAtBuild.IA32.PEI_CORE, PcdsFixedAtBuild.IA32.SEC]
@@ -848,16 +849,15 @@
!if $(TPM_ENABLED) == TRUE
gEfiSecurityPkgTokenSpaceGuid.PcdTpmInstanceGuid|{0x7b, 0x3a, 0xcd, 0x72, 0xA5, 0xFE, 0x5e, 0x4f, 0x91, 0x65, 0x4d, 0xd1, 0x21, 0x87, 0xbb, 0x13}
!endif
- !if $(FTPM_ENABLE) == TRUE
- gEfiSecurityPkgTokenSpaceGuid.PcdTpmInstanceGuid|{0x7b, 0x3a, 0xcd, 0x72, 0xA5, 0xFE, 0x5e, 0x4f, 0x91, 0x65, 0x4d, 0xd1, 0x21, 0x87, 0xbb, 0x13}
- !endif
## This PCD defines the video horizontal resolution.
# This PCD could be set to 0 then video resolution could be at highest resolution.
- gEfiMdeModulePkgTokenSpaceGuid.PcdVideoHorizontalResolution|0
+ #gEfiMdeModulePkgTokenSpaceGuid.PcdVideoHorizontalResolution|0
+ gEfiMdeModulePkgTokenSpaceGuid.PcdVideoHorizontalResolution|800
## This PCD defines the video vertical resolution.
# This PCD could be set to 0 then video resolution could be at highest resolution.
- gEfiMdeModulePkgTokenSpaceGuid.PcdVideoVerticalResolution|0
+ #gEfiMdeModulePkgTokenSpaceGuid.PcdVideoVerticalResolution|0
+ gEfiMdeModulePkgTokenSpaceGuid.PcdVideoVerticalResolution|600
## This PCD defines the Console output column and the default value is 25 according to UEFI spec.
# This PCD could be set to 0 then console output could be at max column and max row.
@@ -943,11 +943,6 @@
!endif
<PcdsPatchableInModule>
gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel|0x80000046
- !if $(TARGET) == DEBUG
- <LibraryClasses>
- DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
- SerialPortLib|$(PLATFORM_PACKAGE)/Library/SerialPortLib/SerialPortLib.inf
- !endif
}
$(PLATFORM_PACKAGE)/MonoStatusCode/MonoStatusCode.inf {
@@ -1013,7 +1008,7 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel|0x803805c6
<LibraryClasses>
!if $(TARGET) != RELEASE
- DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
+ DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
!endif
PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf
}
@@ -1125,7 +1120,6 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
!endif
!if $(TARGET) != RELEASE
DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
- SerialPortLib|$(PLATFORM_PACKAGE)/Library/SerialPortLib/SerialPortLib.inf
!endif
}
IntelFrameworkModulePkg/Universal/Acpi/AcpiS3SaveDxe/AcpiS3SaveDxe.inf {
@@ -1135,7 +1129,7 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x27
<LibraryClasses>
!if $(TARGET) != RELEASE
- DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
+ DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
!endif
<BuildOptions>
ICC:*_*_*_CC_FLAGS = -D MDEPKG_NDEBUG
@@ -1152,16 +1146,19 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
MdeModulePkg/Universal/StatusCodeHandler/RuntimeDxe/StatusCodeHandlerRuntimeDxe.inf {
<LibraryClasses>
!if $(TARGET) != RELEASE
- DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
+ DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
!endif
}
!if $(CAPSULE_ENABLE) == TRUE
MdeModulePkg/Universal/CapsulePei/CapsuleX64.inf {
<LibraryClasses>
- PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf
- MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf
- HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
+ PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf
+ MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf
+ HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
+!if $(SOURCE_DEBUG_ENABLE) == TRUE
+ DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgentLib.inf
+!endif
}
!endif
@@ -1233,7 +1230,7 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
!endif
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf {
<LibraryClasses>
- FileHandleLib|MdePkg/Library/UefiFileHandleLib/UefiFileHandleLib.inf
+ FileHandleLib|MdePkg/Library/UefiFileHandleLib/UefiFileHandleLib.inf
}
MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
@@ -1292,7 +1289,7 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
Vlv2TbltDevicePkg/VlvPlatformInitDxe/VlvPlatformInitDxe.inf{
<LibraryClasses>
!if $(TARGET) != RELEASE
- DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
+ DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
!endif
PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf
}
@@ -1355,7 +1352,7 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
$(PLATFORM_PACKAGE)/PlatformSmm/PlatformSmm.inf{
<LibraryClasses>
!if $(TARGET) != RELEASE
- DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
+ DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
!endif
PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf
}
@@ -1378,13 +1375,7 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
# SMM
#
MdeModulePkg/Core/PiSmmCore/PiSmmIpl.inf
- MdeModulePkg/Core/PiSmmCore/PiSmmCore.inf{
- !if $(TARGET) != RELEASE
- <LibraryClasses>
- DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf
- SerialPortLib|$(PLATFORM_PACKAGE)/Library/SerialPortLib/SerialPortLib.inf
- !endif
- }
+ MdeModulePkg/Core/PiSmmCore/PiSmmCore.inf
UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.inf
UefiCpuPkg/CpuIo2Smm/CpuIo2Smm.inf
MdeModulePkg/Universal/LockBox/SmmLockBox/SmmLockBox.inf
@@ -1674,6 +1665,10 @@ $(PLATFORM_BINARY_PACKAGE)/$(DXE_ARCHITECTURE)$(TARGET)/IA32/fTPMInitPeim.inf
MSFT:*_*_X64_GENFW_FLAGS = --keepexceptiontable
GCC:*_*_X64_GENFW_FLAGS = --keepexceptiontable
INTEL:*_*_X64_GENFW_FLAGS = --keepexceptiontable
+ DEFINE SOURCE_LEVEL_DEBUG_BUILD_OPTIONS =
+!else
+ DEFINE SOURCE_LEVEL_DEBUG_BUILD_OPTIONS =
+
!endif
#
--
2.6.3.windows.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [Patch v2 0/4] Fix SOURCE_DEBUG_ENABLE
2016-12-01 22:07 [Patch v2 0/4] Fix SOURCE_DEBUG_ENABLE Michael Kinney
` (3 preceding siblings ...)
2016-12-01 22:07 ` [Patch v2 4/4] Vlv2TbltDevicePkg: Update PlatformPkgGccX64.dsc Michael Kinney
@ 2016-12-02 14:42 ` Yao, Jiewen
4 siblings, 0 replies; 6+ messages in thread
From: Yao, Jiewen @ 2016-12-02 14:42 UTC (permalink / raw)
To: Kinney, Michael D, edk2-devel@lists.01.org; +Cc: Wei, David, Guo, Mang
Reviewed-by: jiewen.yao@intel.com
> -----Original Message-----
> From: Kinney, Michael D
> Sent: Friday, December 2, 2016 6:08 AM
> To: edk2-devel@lists.01.org
> Cc: Yao, Jiewen <jiewen.yao@intel.com>; Wei, David
> <david.wei@intel.com>; Guo, Mang <mang.guo@intel.com>
> Subject: [Patch v2 0/4] Fix SOURCE_DEBUG_ENABLE
>
> Changes in V2
> =============
> * Fix build failure when SOURCE_DEBUG_ENABLE is FALSE
>
> Fix SOURCE_DEBUG_ENABLE feature that includes updates to library
> mappings, PCD settings, and adding DebugAgent UART Console as one
> of the possible console devices in the PlatformBdsLib.
>
> The series also cleans up a few inconsistencies in the DSC files
> and updates PlatformPkgGccX64.dsc to match PlatformPkgX64.dsc.
>
> Cc: Jiewen Yao <jiewen.yao@intel.com>
> Cc: David Wei <david.wei@intel.com>
> Cc: Mang Guo <mang.guo@intel.com>
> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
>
> Michael Kinney (4):
> Vlv2TbltDevicePkg: Make !if statement usage consistent
> Vlv2TbltDevicePkg: Fix SOURCE_DEBUG_ENABLE feature
> Vlv2TbltDevicePkg/PlatformBdsLib: Add DebugAgent Console
> Vlv2TbltDevicePkg: Update PlatformPkgGccX64.dsc
>
> .../Library/PlatformBdsLib/BdsPlatform.h | 13 +++-
> .../Library/PlatformBdsLib/PlatformBdsLib.inf | 1 +
> .../Library/PlatformBdsLib/PlatformData.c | 48
> +++++++++++++-
> Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc | 77
> ++++++++++------------
> Vlv2TbltDevicePkg/PlatformPkgIA32.dsc | 15 +++--
> Vlv2TbltDevicePkg/PlatformPkgX64.dsc | 26 ++++----
> 6 files changed, 119 insertions(+), 61 deletions(-)
>
> --
> 2.6.3.windows.1
^ permalink raw reply [flat|nested] 6+ messages in thread