\r
Status = gBS->LocateProtocol (&gEdkiiMemoryProfileGuid, NULL, (VOID **) &ProfileProtocol);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UefiMemoryProfile: Locate MemoryProfile protocol - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UefiMemoryProfile: Locate MemoryProfile protocol - %r\n", Status));\r
return Status;\r
}\r
\r
\r
Status = gBS->LocateProtocol (&gEfiSmmCommunicationProtocolGuid, NULL, (VOID **) &SmmCommunication);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfile: Locate SmmCommunication protocol - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfile: Locate SmmCommunication protocol - %r\n", Status));\r
return Status;\r
}\r
\r
(VOID **) &PiSmmCommunicationRegionTable\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfile: Get PiSmmCommunicationRegionTable - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfile: Get PiSmmCommunicationRegionTable - %r\n", Status));\r
return Status;\r
}\r
ASSERT (PiSmmCommunicationRegionTable != NULL);\r
CommSize = sizeof (EFI_GUID) + sizeof (UINTN) + CommHeader->MessageLength;\r
Status = SmmCommunication->Communicate (SmmCommunication, CommBuffer, &CommSize);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfile: SmmCommunication - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfile: SmmCommunication - %r\n", Status));\r
return Status;\r
}\r
\r
\r
Status = GetUefiMemoryProfileData ();\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "GetUefiMemoryProfileData - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "GetUefiMemoryProfileData - %r\n", Status));\r
}\r
\r
Status = GetSmramProfileData ();\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "GetSmramProfileData - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "GetSmramProfileData - %r\n", Status));\r
}\r
\r
return EFI_SUCCESS;\r
//\r
// The threshold exceeded condition is not detected by the device\r
//\r
- DEBUG ((EFI_D_INFO, "The S.M.A.R.T threshold exceeded condition is not detected\n"));\r
+ DEBUG ((DEBUG_INFO, "The S.M.A.R.T threshold exceeded condition is not detected\n"));\r
REPORT_STATUS_CODE (\r
EFI_PROGRESS_CODE,\r
(EFI_IO_BUS_ATA_ATAPI | EFI_IOB_ATA_BUS_SMART_UNDERTHRESHOLD)\r
//\r
// The threshold exceeded condition is detected by the device\r
//\r
- DEBUG ((EFI_D_INFO, "The S.M.A.R.T threshold exceeded condition is detected\n"));\r
+ DEBUG ((DEBUG_INFO, "The S.M.A.R.T threshold exceeded condition is detected\n"));\r
REPORT_STATUS_CODE (\r
EFI_PROGRESS_CODE,\r
(EFI_IO_BUS_ATA_ATAPI | EFI_IOB_ATA_BUS_SMART_OVERTHRESHOLD)\r
//\r
// S.M.A.R.T is not supported by the device\r
//\r
- DEBUG ((EFI_D_INFO, "S.M.A.R.T feature is not supported at port [%d] PortMultiplier [%d]!\n",\r
+ DEBUG ((DEBUG_INFO, "S.M.A.R.T feature is not supported at port [%d] PortMultiplier [%d]!\n",\r
Port, PortMultiplier));\r
REPORT_STATUS_CODE (\r
EFI_ERROR_CODE | EFI_ERROR_MINOR,\r
AtaStatusBlock\r
);\r
\r
- DEBUG ((EFI_D_INFO, "Enabled S.M.A.R.T feature at port [%d] PortMultiplier [%d]!\n",\r
+ DEBUG ((DEBUG_INFO, "Enabled S.M.A.R.T feature at port [%d] PortMultiplier [%d]!\n",\r
Port, PortMultiplier));\r
}\r
\r
NULL\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_WARN,\r
+ DEBUG ((DEBUG_WARN,\r
"AhciModeInitialization: failed to enable 64-bit DMA on 64-bit capable controller (%r)\n",\r
Status));\r
}\r
&SupportedModes\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Calculate Mode Fail, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Calculate Mode Fail, Status = %r\n", Status));\r
continue;\r
}\r
\r
\r
Status = AhciDeviceSetFeature (PciIo, AhciRegisters, Port, 0, 0x03, (UINT32)(*(UINT8 *)&TransferMode), ATA_ATAPI_TIMEOUT);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Set transfer Mode Fail, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Set transfer Mode Fail, Status = %r\n", Status));\r
continue;\r
}\r
\r
\r
return EFI_SUCCESS;\r
}\r
-\r
Instance = NULL;\r
OriginalPciAttributes = 0;\r
\r
- DEBUG ((EFI_D_INFO, "==AtaAtapiPassThru Start== Controller = %x\n", Controller));\r
+ DEBUG ((DEBUG_INFO, "==AtaAtapiPassThru Start== Controller = %x\n", Controller));\r
\r
Status = gBS->OpenProtocol (\r
Controller,\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Open Ide_Controller_Init Error, Status=%r", Status));\r
+ DEBUG ((DEBUG_ERROR, "Open Ide_Controller_Init Error, Status=%r", Status));\r
goto ErrorExit;\r
}\r
\r
EFI_OPEN_PROTOCOL_GET_PROTOCOL\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Get Pci_Io Protocol Error, Status=%r", Status));\r
+ DEBUG ((DEBUG_ERROR, "Get Pci_Io Protocol Error, Status=%r", Status));\r
goto ErrorExit;\r
}\r
\r
EFI_PCI_IO_PROTOCOL *PciIo;\r
EFI_AHCI_REGISTERS *AhciRegisters;\r
\r
- DEBUG ((EFI_D_INFO, "==AtaAtapiPassThru Stop== Controller = %x\n", Controller));\r
+ DEBUG ((DEBUG_INFO, "==AtaAtapiPassThru Stop== Controller = %x\n", Controller));\r
\r
Status = gBS->OpenProtocol (\r
Controller,\r
\r
return EFI_SUCCESS;\r
}\r
-\r
\r
DEBUG_CODE_BEGIN ();\r
if ((StatusBlock.AtaStatus & ATA_STSREG_DWF) != 0) {\r
- DEBUG ((EFI_D_ERROR, "CheckRegisterStatus()-- %02x : Error : Write Fault\n", StatusBlock.AtaStatus));\r
+ DEBUG ((DEBUG_ERROR, "CheckRegisterStatus()-- %02x : Error : Write Fault\n", StatusBlock.AtaStatus));\r
}\r
\r
if ((StatusBlock.AtaStatus & ATA_STSREG_CORR) != 0) {\r
- DEBUG ((EFI_D_ERROR, "CheckRegisterStatus()-- %02x : Error : Corrected Data\n", StatusBlock.AtaStatus));\r
+ DEBUG ((DEBUG_ERROR, "CheckRegisterStatus()-- %02x : Error : Corrected Data\n", StatusBlock.AtaStatus));\r
}\r
\r
if ((StatusBlock.AtaStatus & ATA_STSREG_ERR) != 0) {\r
if ((StatusBlock.AtaError & ATA_ERRREG_BBK) != 0) {\r
- DEBUG ((EFI_D_ERROR, "CheckRegisterStatus()-- %02x : Error : Bad Block Detected\n", StatusBlock.AtaError));\r
+ DEBUG ((DEBUG_ERROR, "CheckRegisterStatus()-- %02x : Error : Bad Block Detected\n", StatusBlock.AtaError));\r
}\r
\r
if ((StatusBlock.AtaError & ATA_ERRREG_UNC) != 0) {\r
- DEBUG ((EFI_D_ERROR, "CheckRegisterStatus()-- %02x : Error : Uncorrectable Data\n", StatusBlock.AtaError));\r
+ DEBUG ((DEBUG_ERROR, "CheckRegisterStatus()-- %02x : Error : Uncorrectable Data\n", StatusBlock.AtaError));\r
}\r
\r
if ((StatusBlock.AtaError & ATA_ERRREG_MC) != 0) {\r
- DEBUG ((EFI_D_ERROR, "CheckRegisterStatus()-- %02x : Error : Media Change\n", StatusBlock.AtaError));\r
+ DEBUG ((DEBUG_ERROR, "CheckRegisterStatus()-- %02x : Error : Media Change\n", StatusBlock.AtaError));\r
}\r
\r
if ((StatusBlock.AtaError & ATA_ERRREG_ABRT) != 0) {\r
- DEBUG ((EFI_D_ERROR, "CheckRegisterStatus()-- %02x : Error : Abort\n", StatusBlock.AtaError));\r
+ DEBUG ((DEBUG_ERROR, "CheckRegisterStatus()-- %02x : Error : Abort\n", StatusBlock.AtaError));\r
}\r
\r
if ((StatusBlock.AtaError & ATA_ERRREG_TK0NF) != 0) {\r
- DEBUG ((EFI_D_ERROR, "CheckRegisterStatus()-- %02x : Error : Track 0 Not Found\n", StatusBlock.AtaError));\r
+ DEBUG ((DEBUG_ERROR, "CheckRegisterStatus()-- %02x : Error : Track 0 Not Found\n", StatusBlock.AtaError));\r
}\r
\r
if ((StatusBlock.AtaError & ATA_ERRREG_AMNF) != 0) {\r
- DEBUG ((EFI_D_ERROR, "CheckRegisterStatus()-- %02x : Error : Address Mark Not Found\n", StatusBlock.AtaError));\r
+ DEBUG ((DEBUG_ERROR, "CheckRegisterStatus()-- %02x : Error : Address Mark Not Found\n", StatusBlock.AtaError));\r
}\r
}\r
DEBUG_CODE_END ();\r
IoPortForBmis = (UINT16) (IdeRegisters->BusMasterBaseAddr + BMIS_OFFSET);\r
RegisterValue = IdeReadPortB (PciIo, IoPortForBmis);\r
if (((RegisterValue & BMIS_ERROR) != 0) || (Timeout == 0)) {\r
- DEBUG ((EFI_D_ERROR, "ATA UDMA operation fails\n"));\r
+ DEBUG ((DEBUG_ERROR, "ATA UDMA operation fails\n"));\r
Status = EFI_DEVICE_ERROR;\r
break;\r
}\r
RegisterValue = IdeReadPortB (PciIo, IoPortForBmis);\r
\r
if ((RegisterValue & BMIS_ERROR) != 0) {\r
- DEBUG ((EFI_D_ERROR, "ATA UDMA operation fails\n"));\r
+ DEBUG ((DEBUG_ERROR, "ATA UDMA operation fails\n"));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
//\r
// The threshold exceeded condition is not detected by the device\r
//\r
- DEBUG ((EFI_D_INFO, "The S.M.A.R.T threshold exceeded condition is not detected\n"));\r
+ DEBUG ((DEBUG_INFO, "The S.M.A.R.T threshold exceeded condition is not detected\n"));\r
REPORT_STATUS_CODE (\r
EFI_PROGRESS_CODE,\r
(EFI_IO_BUS_ATA_ATAPI | EFI_IOB_ATA_BUS_SMART_UNDERTHRESHOLD)\r
//\r
// The threshold exceeded condition is detected by the device\r
//\r
- DEBUG ((EFI_D_INFO, "The S.M.A.R.T threshold exceeded condition is detected\n"));\r
+ DEBUG ((DEBUG_INFO, "The S.M.A.R.T threshold exceeded condition is detected\n"));\r
REPORT_STATUS_CODE (\r
EFI_PROGRESS_CODE,\r
(EFI_IO_BUS_ATA_ATAPI | EFI_IOB_ATA_BUS_SMART_OVERTHRESHOLD)\r
//\r
// S.M.A.R.T is not supported by the device\r
//\r
- DEBUG ((EFI_D_INFO, "S.M.A.R.T feature is not supported at [%a] channel [%a] device!\n",\r
+ DEBUG ((DEBUG_INFO, "S.M.A.R.T feature is not supported at [%a] channel [%a] device!\n",\r
(Channel == 1) ? "secondary" : "primary", (Device == 1) ? "slave" : "master"));\r
REPORT_STATUS_CODE (\r
EFI_ERROR_CODE | EFI_ERROR_MINOR,\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Enabled S.M.A.R.T feature at [%a] channel [%a] device!\n",\r
+ DEBUG ((DEBUG_INFO, "Enabled S.M.A.R.T feature at [%a] channel [%a] device!\n",\r
(Channel == 1) ? "secondary" : "primary", (Device == 1) ? "slave" : "master"));\r
\r
}\r
\r
Status = WaitForBSYClear (PciIo, IdeRegisters, 350000000);\r
if (EFI_ERROR (Status)) {\r
- DEBUG((EFI_D_ERROR, "New detecting method: Send Execute Diagnostic Command: WaitForBSYClear: Status: %d\n", Status));\r
+ DEBUG((DEBUG_ERROR, "New detecting method: Send Execute Diagnostic Command: WaitForBSYClear: Status: %d\n", Status));\r
continue;\r
}\r
\r
continue;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "[%a] channel [%a] [%a] device\n",\r
+ DEBUG ((DEBUG_INFO, "[%a] channel [%a] [%a] device\n",\r
(IdeChannel == 1) ? "secondary" : "primary ", (IdeDevice == 1) ? "slave " : "master",\r
DeviceType == EfiIdeCdrom ? "cdrom " : "harddisk"));\r
//\r
&SupportedModes\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Calculate Mode Fail, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Calculate Mode Fail, Status = %r\n", Status));\r
continue;\r
}\r
\r
Status = SetDeviceTransferMode (Instance, IdeChannel, IdeDevice, &TransferMode, NULL);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Set transfer Mode Fail, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Set transfer Mode Fail, Status = %r\n", Status));\r
continue;\r
}\r
}\r
Status = SetDeviceTransferMode (Instance, IdeChannel, IdeDevice, &TransferMode, NULL);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Set transfer Mode Fail, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Set transfer Mode Fail, Status = %r\n", Status));\r
continue;\r
}\r
} else if (SupportedModes->MultiWordDmaMode.Valid) {\r
Status = SetDeviceTransferMode (Instance, IdeChannel, IdeDevice, &TransferMode, NULL);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Set transfer Mode Fail, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Set transfer Mode Fail, Status = %r\n", Status));\r
continue;\r
}\r
}\r
&MaxDevices\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "[GetChannel, Status=%x]", Status));\r
+ DEBUG ((DEBUG_ERROR, "[GetChannel, Status=%x]", Status));\r
continue;\r
}\r
\r
ErrorExit:\r
return Status;\r
}\r
-\r
// If yes, then install Storage Security Protocol at the ata device handle.\r
//\r
if ((AtaDevice->IdentifyData->trusted_computing_support & BIT0) != 0) {\r
- DEBUG ((EFI_D_INFO, "Found TCG support in Port %x PortMultiplierPort %x\n", Port, PortMultiplierPort));\r
+ DEBUG ((DEBUG_INFO, "Found TCG support in Port %x PortMultiplierPort %x\n", Port, PortMultiplierPort));\r
Status = gBS->InstallProtocolInterface (\r
&AtaDevice->Handle,\r
&gEfiStorageSecurityCommandProtocolGuid,\r
if (EFI_ERROR (Status)) {\r
goto Done;\r
}\r
- DEBUG ((EFI_D_INFO, "Successfully Install Storage Security Protocol on the ATA device\n"));\r
+ DEBUG ((DEBUG_INFO, "Successfully Install Storage Security Protocol on the ATA device\n"));\r
}\r
\r
gBS->OpenProtocol (\r
\r
if (EFI_ERROR (Status) && (AtaDevice != NULL)) {\r
ReleaseAtaResources (AtaDevice);\r
- DEBUG ((EFI_D_ERROR | EFI_D_INIT, "Failed to initialize Port %x PortMultiplierPort %x, status = %r\n", Port, PortMultiplierPort, Status));\r
+ DEBUG ((DEBUG_ERROR | DEBUG_INIT, "Failed to initialize Port %x PortMultiplierPort %x, status = %r\n", Port, PortMultiplierPort, Status));\r
}\r
return Status;\r
}\r
ATA_DEVICE *Private;\r
EFI_TPL OldTpl;\r
\r
- DEBUG ((EFI_D_INFO, "EFI Storage Security Protocol - Read\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI Storage Security Protocol - Read\n"));\r
if ((PayloadBuffer == NULL || PayloadTransferSize == NULL) && PayloadBufferSize != 0) {\r
return EFI_INVALID_PARAMETER;\r
}\r
ATA_DEVICE *Private;\r
EFI_TPL OldTpl;\r
\r
- DEBUG ((EFI_D_INFO, "EFI Storage Security Protocol - Send\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI Storage Security Protocol - Send\n"));\r
if ((PayloadBuffer == NULL) && (PayloadBufferSize != 0)) {\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
return Status;\r
}\r
-\r
return EFI_UNSUPPORTED;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "AtaBus - Identify Device: Port %x PortMultiplierPort %x\n", AtaDevice->Port, AtaDevice->PortMultiplierPort));\r
+ DEBUG ((DEBUG_INFO, "AtaBus - Identify Device: Port %x PortMultiplierPort %x\n", AtaDevice->Port, AtaDevice->PortMultiplierPort));\r
\r
//\r
// Check whether the WORD 88 (supported UltraDMA by drive) is valid\r
}\r
\r
DEBUG ((\r
- EFI_D_BLKIO,\r
+ DEBUG_BLKIO,\r
"NON-BLOCKING EVENT FINISHED!- STATUS = %r\n",\r
Task->Token->TransactionStatus\r
));\r
// Reduce the SubEventCount, till it comes to zero.\r
//\r
(*Task->UnsignalledEventCount) --;\r
- DEBUG ((EFI_D_BLKIO, "UnsignalledEventCount = %d\n", *Task->UnsignalledEventCount));\r
+ DEBUG ((DEBUG_BLKIO, "UnsignalledEventCount = %d\n", *Task->UnsignalledEventCount));\r
\r
//\r
// Remove the SubTask from the Task list.\r
//\r
if (!(*Task->IsError)) {\r
gBS->SignalEvent (Task->Token->Event);\r
- DEBUG ((EFI_D_BLKIO, "Signal the upper layer event!\n"));\r
+ DEBUG ((DEBUG_BLKIO, "Signal the upper layer event!\n"));\r
}\r
\r
FreePool (Task->UnsignalledEventCount);\r
if (!IsListEmpty (&AtaDevice->AtaTaskList)) {\r
Entry = GetFirstNode (&AtaDevice->AtaTaskList);\r
AtaTask = ATA_ASYN_TASK_FROM_ENTRY (Entry);\r
- DEBUG ((EFI_D_BLKIO, "Start to embark a new Ata Task\n"));\r
- DEBUG ((EFI_D_BLKIO, "AtaTask->NumberOfBlocks = %x; AtaTask->Token=%x\n", AtaTask->NumberOfBlocks, AtaTask->Token));\r
+ DEBUG ((DEBUG_BLKIO, "Start to embark a new Ata Task\n"));\r
+ DEBUG ((DEBUG_BLKIO, "AtaTask->NumberOfBlocks = %x; AtaTask->Token=%x\n", AtaTask->NumberOfBlocks, AtaTask->Token));\r
Status = AccessAtaDevice (\r
AtaTask->AtaDevice,\r
AtaTask->Buffer,\r
}\r
\r
DEBUG ((\r
- EFI_D_BLKIO,\r
+ DEBUG_BLKIO,\r
"PACKET INFO: Write=%s, Length=%x, LowCylinder=%x, HighCylinder=%x, SectionNumber=%x\n",\r
Task->Packet.OutDataBuffer != NULL ? L"YES" : L"NO",\r
Task->Packet.OutDataBuffer != NULL ? Task->Packet.OutTransferLength : Task->Packet.InTransferLength,\r
FreePool (EventCount);\r
return EFI_OUT_OF_RESOURCES;\r
}\r
- DEBUG ((EFI_D_BLKIO, "Allocation IsError Addr=%x\n", IsError));\r
+ DEBUG ((DEBUG_BLKIO, "Allocation IsError Addr=%x\n", IsError));\r
*IsError = FALSE;\r
TempCount = (NumberOfBlocks + MaxTransferBlockNumber - 1) / MaxTransferBlockNumber;\r
*EventCount = TempCount;\r
- DEBUG ((EFI_D_BLKIO, "AccessAtaDevice, NumberOfBlocks=%x\n", NumberOfBlocks));\r
- DEBUG ((EFI_D_BLKIO, "AccessAtaDevice, MaxTransferBlockNumber=%x\n", MaxTransferBlockNumber));\r
- DEBUG ((EFI_D_BLKIO, "AccessAtaDevice, EventCount=%x\n", TempCount));\r
+ DEBUG ((DEBUG_BLKIO, "AccessAtaDevice, NumberOfBlocks=%x\n", NumberOfBlocks));\r
+ DEBUG ((DEBUG_BLKIO, "AccessAtaDevice, MaxTransferBlockNumber=%x\n", MaxTransferBlockNumber));\r
+ DEBUG ((DEBUG_BLKIO, "AccessAtaDevice, EventCount=%x\n", TempCount));\r
} else {\r
while (!IsListEmpty (&AtaDevice->AtaTaskList) || !IsListEmpty (&AtaDevice->AtaSubTaskList)) {\r
//\r
//\r
// Blocking Mode.\r
//\r
- DEBUG ((EFI_D_BLKIO, "Blocking AccessAtaDevice, TransferBlockNumber=%x; StartLba = %x\n", TransferBlockNumber, StartLba));\r
+ DEBUG ((DEBUG_BLKIO, "Blocking AccessAtaDevice, TransferBlockNumber=%x; StartLba = %x\n", TransferBlockNumber, StartLba));\r
Status = TransferAtaDevice (AtaDevice, NULL, Buffer, StartLba, (UINT32) TransferBlockNumber, IsWrite, NULL);\r
}\r
\r
((!SystemHasControllerNode) && (RemainingHasControllerNode) && (RemainingControllerNumber == 0)) ||\r
((SystemHasControllerNode) && (RemainingHasControllerNode) && (SystemControllerNumber == RemainingControllerNumber)) ||\r
((!SystemHasControllerNode) && (!RemainingHasControllerNode))) {\r
- DEBUG ((EFI_D_ERROR, "This I2C device has been already started.\n"));\r
+ DEBUG ((DEBUG_ERROR, "This I2C device has been already started.\n"));\r
Status = EFI_UNSUPPORTED;\r
break;\r
}\r
EFI_OPEN_PROTOCOL_BY_DRIVER\r
);\r
if (EFI_ERROR (Status) && (Status != EFI_ALREADY_STARTED)) {\r
- DEBUG ((EFI_D_ERROR, "I2cBus: open I2C host error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cBus: open I2C host error, Status = %r\n", Status));\r
return Status;\r
}\r
\r
EFI_OPEN_PROTOCOL_GET_PROTOCOL\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "I2cBus: open private protocol error, Status = %r.\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cBus: open private protocol error, Status = %r.\n", Status));\r
return Status;\r
}\r
}\r
EFI_OPEN_PROTOCOL_BY_DRIVER\r
);\r
if (EFI_ERROR (Status) && (Status != EFI_ALREADY_STARTED)) {\r
- DEBUG ((EFI_D_ERROR, "I2cBus: open I2C enumerate error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cBus: open I2C enumerate error, Status = %r\n", Status));\r
goto Error;\r
}\r
\r
EFI_OPEN_PROTOCOL_BY_DRIVER\r
);\r
if (EFI_ERROR (Status) && (Status != EFI_ALREADY_STARTED)) {\r
- DEBUG ((EFI_D_ERROR, "I2cBus: open device path error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cBus: open device path error, Status = %r\n", Status));\r
goto Error;\r
}\r
\r
//\r
I2cBusContext = AllocateZeroPool (sizeof (I2C_BUS_CONTEXT));\r
if (I2cBusContext == NULL) {\r
- DEBUG ((EFI_D_ERROR, "I2cBus: there is no enough memory to allocate.\n"));\r
+ DEBUG ((DEBUG_ERROR, "I2cBus: there is no enough memory to allocate.\n"));\r
Status = EFI_OUT_OF_RESOURCES;\r
goto Error;\r
}\r
NULL\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "I2cBus: install private protocol error, Status = %r.\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cBus: install private protocol error, Status = %r.\n", Status));\r
goto Error;\r
}\r
}\r
\r
Error:\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "I2cBus: Start() function failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cBus: Start() function failed, Status = %r\n", Status));\r
if (ParentDevicePath != NULL) {\r
gBS->CloseProtocol (\r
Controller,\r
// Determine if the device info is valid\r
//\r
if ((Device->DeviceGuid == NULL) || (Device->SlaveAddressCount == 0) || (Device->SlaveAddressArray == NULL)) {\r
- DEBUG ((EFI_D_ERROR, "Invalid EFI_I2C_DEVICE reported by I2c Enumerate protocol.\n"));\r
+ DEBUG ((DEBUG_ERROR, "Invalid EFI_I2C_DEVICE reported by I2c Enumerate protocol.\n"));\r
continue;\r
}\r
\r
EFI_OPEN_PROTOCOL_BY_DRIVER\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "I2cHost: Open I2C bus configuration error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cHost: Open I2C bus configuration error, Status = %r\n", Status));\r
return Status;\r
}\r
\r
EFI_OPEN_PROTOCOL_GET_PROTOCOL\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "I2cHost: Open I2C master error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cHost: Open I2C master error, Status = %r\n", Status));\r
goto Exit;\r
}\r
\r
//\r
I2cHostContext = AllocateZeroPool (sizeof (I2C_HOST_CONTEXT));\r
if (I2cHostContext == NULL) {\r
- DEBUG ((EFI_D_ERROR, "I2cHost: there is no enough memory to allocate.\n"));\r
+ DEBUG ((DEBUG_ERROR, "I2cHost: there is no enough memory to allocate.\n"));\r
Status = EFI_OUT_OF_RESOURCES;\r
goto Exit;\r
}\r
//\r
Status = I2cMaster->Reset (I2cMaster);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "I2cHost: I2C controller reset failed!\n"));\r
+ DEBUG ((DEBUG_ERROR, "I2cHost: I2C controller reset failed!\n"));\r
goto Exit;\r
}\r
\r
&I2cHostContext->I2cEvent\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "I2cHost: create complete event error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cHost: create complete event error, Status = %r\n", Status));\r
goto Exit;\r
}\r
\r
&I2cHostContext->I2cBusConfigurationEvent\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "I2cHost: create bus available event error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cHost: create bus available event error, Status = %r\n", Status));\r
goto Exit;\r
}\r
\r
);\r
Exit:\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "I2cHost: Start() function failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "I2cHost: Start() function failed, Status = %r\n", Status));\r
if (I2cBusConfigurationManagement != NULL) {\r
gBS->CloseProtocol (\r
Controller,\r
\r
TplPrevious = EfiGetCurrentTpl ();\r
if (TplPrevious > TPL_I2C_SYNC) {\r
- DEBUG ((EFI_D_ERROR, "I2cHost: TPL %d is too high in Stop.\n", TplPrevious));\r
+ DEBUG ((DEBUG_ERROR, "I2cHost: TPL %d is too high in Stop.\n", TplPrevious));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
//\r
TplPrevious = EfiGetCurrentTpl ();\r
if ((TplPrevious > TPL_I2C_SYNC) || ((Event == NULL) && (TplPrevious > TPL_CALLBACK))) {\r
- DEBUG ((EFI_D_ERROR, "ERROR - TPL %d is too high!\n", TplPrevious));\r
+ DEBUG ((DEBUG_ERROR, "ERROR - TPL %d is too high!\n", TplPrevious));\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
//\r
I2cRequest = AllocateZeroPool (sizeof (I2C_REQUEST));\r
if (I2cRequest == NULL) {\r
- DEBUG ((EFI_D_ERROR, "WARNING - Failed to allocate I2C_REQUEST!\n"));\r
+ DEBUG ((DEBUG_ERROR, "WARNING - Failed to allocate I2C_REQUEST!\n"));\r
return EFI_OUT_OF_RESOURCES;\r
}\r
\r
*PortNumber = (UINT8) (Ehc->HcStructParams & HCSP_NPORTS);\r
*Is64BitCapable = (UINT8) Ehc->Support64BitDma;\r
\r
- DEBUG ((EFI_D_INFO, "EhcGetCapability: %d ports, 64 bit %d\n", *PortNumber, *Is64BitCapable));\r
+ DEBUG ((DEBUG_INFO, "EhcGetCapability: %d ports, 64 bit %d\n", *PortNumber, *Is64BitCapable));\r
\r
gBS->RestoreTPL (OldTpl);\r
return EFI_SUCCESS;\r
}\r
\r
ON_EXIT:\r
- DEBUG ((EFI_D_INFO, "EhcReset: exit status %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "EhcReset: exit status %r\n", Status));\r
gBS->RestoreTPL (OldTpl);\r
return Status;\r
}\r
\r
gBS->RestoreTPL (OldTpl);\r
\r
- DEBUG ((EFI_D_INFO, "EhcGetState: current state %d\n", *State));\r
+ DEBUG ((DEBUG_INFO, "EhcGetState: current state %d\n", *State));\r
return EFI_SUCCESS;\r
}\r
\r
Status = EFI_INVALID_PARAMETER;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "EhcSetState: exit status %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "EhcSetState: exit status %r\n", Status));\r
gBS->RestoreTPL (OldTpl);\r
return Status;\r
}\r
Status = EhcRunHC (Ehc, EHC_GENERIC_TIMEOUT);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "EhcSetRootHubPortFeature :failed to start HC - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "EhcSetRootHubPortFeature :failed to start HC - %r\n", Status));\r
break;\r
}\r
}\r
}\r
\r
ON_EXIT:\r
- DEBUG ((EFI_D_INFO, "EhcSetRootHubPortFeature: exit status %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "EhcSetRootHubPortFeature: exit status %r\n", Status));\r
\r
gBS->RestoreTPL (OldTpl);\r
return Status;\r
}\r
\r
ON_EXIT:\r
- DEBUG ((EFI_D_INFO, "EhcClearRootHubPortFeature: exit status %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "EhcClearRootHubPortFeature: exit status %r\n", Status));\r
gBS->RestoreTPL (OldTpl);\r
return Status;\r
}\r
*TransferResult = EFI_USB_ERR_SYSTEM;\r
\r
if (EhcIsHalt (Ehc) || EhcIsSysError (Ehc)) {\r
- DEBUG ((EFI_D_ERROR, "EhcControlTransfer: HC halted at entrance\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcControlTransfer: HC halted at entrance\n"));\r
\r
EhcAckAllInterrupt (Ehc);\r
goto ON_EXIT;\r
);\r
\r
if (Urb == NULL) {\r
- DEBUG ((EFI_D_ERROR, "EhcControlTransfer: failed to create URB"));\r
+ DEBUG ((DEBUG_ERROR, "EhcControlTransfer: failed to create URB"));\r
\r
Status = EFI_OUT_OF_RESOURCES;\r
goto ON_EXIT;\r
gBS->RestoreTPL (OldTpl);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcControlTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
+ DEBUG ((DEBUG_ERROR, "EhcControlTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
}\r
\r
return Status;\r
Status = EFI_DEVICE_ERROR;\r
\r
if (EhcIsHalt (Ehc) || EhcIsSysError (Ehc)) {\r
- DEBUG ((EFI_D_ERROR, "EhcBulkTransfer: HC is halted\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcBulkTransfer: HC is halted\n"));\r
\r
EhcAckAllInterrupt (Ehc);\r
goto ON_EXIT;\r
);\r
\r
if (Urb == NULL) {\r
- DEBUG ((EFI_D_ERROR, "EhcBulkTransfer: failed to create URB\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcBulkTransfer: failed to create URB\n"));\r
\r
Status = EFI_OUT_OF_RESOURCES;\r
goto ON_EXIT;\r
gBS->RestoreTPL (OldTpl);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcBulkTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
+ DEBUG ((DEBUG_ERROR, "EhcBulkTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
}\r
\r
return Status;\r
if (!IsNewTransfer) {\r
Status = EhciDelAsyncIntTransfer (Ehc, DeviceAddress, EndPointAddress, DataToggle);\r
\r
- DEBUG ((EFI_D_INFO, "EhcAsyncInterruptTransfer: remove old transfer - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "EhcAsyncInterruptTransfer: remove old transfer - %r\n", Status));\r
goto ON_EXIT;\r
}\r
\r
Status = EFI_SUCCESS;\r
\r
if (EhcIsHalt (Ehc) || EhcIsSysError (Ehc)) {\r
- DEBUG ((EFI_D_ERROR, "EhcAsyncInterruptTransfer: HC is halt\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcAsyncInterruptTransfer: HC is halt\n"));\r
EhcAckAllInterrupt (Ehc);\r
\r
Status = EFI_DEVICE_ERROR;\r
Status = EFI_DEVICE_ERROR;\r
\r
if (EhcIsHalt (Ehc) || EhcIsSysError (Ehc)) {\r
- DEBUG ((EFI_D_ERROR, "EhcSyncInterruptTransfer: HC is halt\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcSyncInterruptTransfer: HC is halt\n"));\r
\r
EhcAckAllInterrupt (Ehc);\r
goto ON_EXIT;\r
);\r
\r
if (Urb == NULL) {\r
- DEBUG ((EFI_D_ERROR, "EhcSyncInterruptTransfer: failed to create URB\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcSyncInterruptTransfer: failed to create URB\n"));\r
\r
Status = EFI_OUT_OF_RESOURCES;\r
goto ON_EXIT;\r
gBS->RestoreTPL (OldTpl);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcSyncInterruptTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
+ DEBUG ((DEBUG_ERROR, "EhcSyncInterruptTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
}\r
\r
return Status;\r
Ehc->HcCapParams = EhcReadCapRegister (Ehc, EHC_HCCPARAMS_OFFSET);\r
Ehc->CapLen = EhcReadCapRegister (Ehc, EHC_CAPLENGTH_OFFSET) & 0x0FF;\r
\r
- DEBUG ((EFI_D_INFO, "EhcCreateUsb2Hc: capability length %d\n", Ehc->CapLen));\r
+ DEBUG ((DEBUG_INFO, "EhcCreateUsb2Hc: capability length %d\n", Ehc->CapLen));\r
\r
//\r
// EHCI Controllers with a CapLen of 0 are ignored.\r
}\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcDriverBindingStart: failed to enable controller\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcDriverBindingStart: failed to enable controller\n"));\r
goto CLOSE_PCIIO;\r
}\r
\r
Ehc = EhcCreateUsb2Hc (PciIo, HcDevicePath, OriginalPciAttributes);\r
\r
if (Ehc == NULL) {\r
- DEBUG ((EFI_D_ERROR, "EhcDriverBindingStart: failed to create USB2_HC\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcDriverBindingStart: failed to create USB2_HC\n"));\r
\r
Status = EFI_OUT_OF_RESOURCES;\r
goto CLOSE_PCIIO;\r
if (!EFI_ERROR (Status)) {\r
Ehc->Support64BitDma = TRUE;\r
} else {\r
- DEBUG ((EFI_D_WARN,\r
+ DEBUG ((DEBUG_WARN,\r
"%a: failed to enable 64-bit DMA on 64-bit capable controller @ %p (%r)\n",\r
__FUNCTION__, Controller, Status));\r
}\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcDriverBindingStart: failed to install USB2_HC Protocol\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcDriverBindingStart: failed to install USB2_HC Protocol\n"));\r
goto FREE_POOL;\r
}\r
\r
Status = EhcInitHC (Ehc);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcDriverBindingStart: failed to init host controller\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcDriverBindingStart: failed to init host controller\n"));\r
goto UNINSTALL_USBHC;\r
}\r
\r
Status = gBS->SetTimer (Ehc->PollTimer, TimerPeriodic, EHC_ASYNC_POLL_INTERVAL);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcDriverBindingStart: failed to start async interrupt monitor\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcDriverBindingStart: failed to start async interrupt monitor\n"));\r
\r
EhcHaltHC (Ehc, EHC_GENERIC_TIMEOUT);\r
goto UNINSTALL_USBHC;\r
);\r
\r
\r
- DEBUG ((EFI_D_INFO, "EhcDriverBindingStart: EHCI started for controller @ %p\n", Controller));\r
+ DEBUG ((DEBUG_INFO, "EhcDriverBindingStart: EHCI started for controller @ %p\n", Controller));\r
return EFI_SUCCESS;\r
\r
UNINSTALL_USBHC:\r
\r
return EFI_SUCCESS;\r
}\r
-\r
)\r
{\r
if (EHC_BIT_IS_SET (State, QTD_STAT_DO_PING)) {\r
- DEBUG ((EFI_D_VERBOSE, " Do_Ping"));\r
+ DEBUG ((DEBUG_VERBOSE, " Do_Ping"));\r
} else {\r
- DEBUG ((EFI_D_VERBOSE, " Do_Out"));\r
+ DEBUG ((DEBUG_VERBOSE, " Do_Out"));\r
}\r
\r
if (EHC_BIT_IS_SET (State, QTD_STAT_DO_CS)) {\r
- DEBUG ((EFI_D_VERBOSE, " Do_CS"));\r
+ DEBUG ((DEBUG_VERBOSE, " Do_CS"));\r
} else {\r
- DEBUG ((EFI_D_VERBOSE, " Do_SS"));\r
+ DEBUG ((DEBUG_VERBOSE, " Do_SS"));\r
}\r
\r
if (EHC_BIT_IS_SET (State, QTD_STAT_TRANS_ERR)) {\r
- DEBUG ((EFI_D_VERBOSE, " Transfer_Error"));\r
+ DEBUG ((DEBUG_VERBOSE, " Transfer_Error"));\r
}\r
\r
if (EHC_BIT_IS_SET (State, QTD_STAT_BABBLE_ERR)) {\r
- DEBUG ((EFI_D_VERBOSE, " Babble_Error"));\r
+ DEBUG ((DEBUG_VERBOSE, " Babble_Error"));\r
}\r
\r
if (EHC_BIT_IS_SET (State, QTD_STAT_BUFF_ERR)) {\r
- DEBUG ((EFI_D_VERBOSE, " Buffer_Error"));\r
+ DEBUG ((DEBUG_VERBOSE, " Buffer_Error"));\r
}\r
\r
if (EHC_BIT_IS_SET (State, QTD_STAT_HALTED)) {\r
- DEBUG ((EFI_D_VERBOSE, " Halted"));\r
+ DEBUG ((DEBUG_VERBOSE, " Halted"));\r
}\r
\r
if (EHC_BIT_IS_SET (State, QTD_STAT_ACTIVE)) {\r
- DEBUG ((EFI_D_VERBOSE, " Active"));\r
+ DEBUG ((DEBUG_VERBOSE, " Active"));\r
}\r
\r
- DEBUG ((EFI_D_VERBOSE, "\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "\n"));\r
}\r
\r
\r
UINTN Index;\r
\r
if (Msg != NULL) {\r
- DEBUG ((EFI_D_VERBOSE, Msg));\r
+ DEBUG ((DEBUG_VERBOSE, Msg));\r
}\r
\r
- DEBUG ((EFI_D_VERBOSE, "Queue TD @ 0x%p, data length %d\n", Qtd, (UINT32)Qtd->DataLen));\r
+ DEBUG ((DEBUG_VERBOSE, "Queue TD @ 0x%p, data length %d\n", Qtd, (UINT32)Qtd->DataLen));\r
\r
QtdHw = &Qtd->QtdHw;\r
\r
- DEBUG ((EFI_D_VERBOSE, "Next QTD : %x\n", QtdHw->NextQtd));\r
- DEBUG ((EFI_D_VERBOSE, "AltNext QTD : %x\n", QtdHw->AltNext));\r
- DEBUG ((EFI_D_VERBOSE, "Status : %x\n", QtdHw->Status));\r
+ DEBUG ((DEBUG_VERBOSE, "Next QTD : %x\n", QtdHw->NextQtd));\r
+ DEBUG ((DEBUG_VERBOSE, "AltNext QTD : %x\n", QtdHw->AltNext));\r
+ DEBUG ((DEBUG_VERBOSE, "Status : %x\n", QtdHw->Status));\r
EhcDumpStatus (QtdHw->Status);\r
\r
if (QtdHw->Pid == QTD_PID_SETUP) {\r
- DEBUG ((EFI_D_VERBOSE, "PID : Setup\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "PID : Setup\n"));\r
\r
} else if (QtdHw->Pid == QTD_PID_INPUT) {\r
- DEBUG ((EFI_D_VERBOSE, "PID : IN\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "PID : IN\n"));\r
\r
} else if (QtdHw->Pid == QTD_PID_OUTPUT) {\r
- DEBUG ((EFI_D_VERBOSE, "PID : OUT\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "PID : OUT\n"));\r
\r
}\r
\r
- DEBUG ((EFI_D_VERBOSE, "Error Count : %d\n", QtdHw->ErrCnt));\r
- DEBUG ((EFI_D_VERBOSE, "Current Page : %d\n", QtdHw->CurPage));\r
- DEBUG ((EFI_D_VERBOSE, "IOC : %d\n", QtdHw->Ioc));\r
- DEBUG ((EFI_D_VERBOSE, "Total Bytes : %d\n", QtdHw->TotalBytes));\r
- DEBUG ((EFI_D_VERBOSE, "Data Toggle : %d\n", QtdHw->DataToggle));\r
+ DEBUG ((DEBUG_VERBOSE, "Error Count : %d\n", QtdHw->ErrCnt));\r
+ DEBUG ((DEBUG_VERBOSE, "Current Page : %d\n", QtdHw->CurPage));\r
+ DEBUG ((DEBUG_VERBOSE, "IOC : %d\n", QtdHw->Ioc));\r
+ DEBUG ((DEBUG_VERBOSE, "Total Bytes : %d\n", QtdHw->TotalBytes));\r
+ DEBUG ((DEBUG_VERBOSE, "Data Toggle : %d\n", QtdHw->DataToggle));\r
\r
for (Index = 0; Index < 5; Index++) {\r
- DEBUG ((EFI_D_VERBOSE, "Page[%d] : 0x%x\n", (UINT32)Index, QtdHw->Page[Index]));\r
+ DEBUG ((DEBUG_VERBOSE, "Page[%d] : 0x%x\n", (UINT32)Index, QtdHw->Page[Index]));\r
}\r
}\r
\r
UINTN Index;\r
\r
if (Msg != NULL) {\r
- DEBUG ((EFI_D_VERBOSE, Msg));\r
+ DEBUG ((DEBUG_VERBOSE, Msg));\r
}\r
\r
- DEBUG ((EFI_D_VERBOSE, "Queue head @ 0x%p, interval %ld, next qh %p\n",\r
+ DEBUG ((DEBUG_VERBOSE, "Queue head @ 0x%p, interval %ld, next qh %p\n",\r
Qh, (UINT64)Qh->Interval, Qh->NextQh));\r
\r
QhHw = &Qh->QhHw;\r
\r
- DEBUG ((EFI_D_VERBOSE, "Hoziontal link: %x\n", QhHw->HorizonLink));\r
- DEBUG ((EFI_D_VERBOSE, "Device address: %d\n", QhHw->DeviceAddr));\r
- DEBUG ((EFI_D_VERBOSE, "Inactive : %d\n", QhHw->Inactive));\r
- DEBUG ((EFI_D_VERBOSE, "EP number : %d\n", QhHw->EpNum));\r
- DEBUG ((EFI_D_VERBOSE, "EP speed : %d\n", QhHw->EpSpeed));\r
- DEBUG ((EFI_D_VERBOSE, "DT control : %d\n", QhHw->DtCtrl));\r
- DEBUG ((EFI_D_VERBOSE, "Reclaim head : %d\n", QhHw->ReclaimHead));\r
- DEBUG ((EFI_D_VERBOSE, "Max packet len: %d\n", QhHw->MaxPacketLen));\r
- DEBUG ((EFI_D_VERBOSE, "Ctrl EP : %d\n", QhHw->CtrlEp));\r
- DEBUG ((EFI_D_VERBOSE, "Nak reload : %d\n", QhHw->NakReload));\r
-\r
- DEBUG ((EFI_D_VERBOSE, "SMask : %x\n", QhHw->SMask));\r
- DEBUG ((EFI_D_VERBOSE, "CMask : %x\n", QhHw->CMask));\r
- DEBUG ((EFI_D_VERBOSE, "Hub address : %d\n", QhHw->HubAddr));\r
- DEBUG ((EFI_D_VERBOSE, "Hub port : %d\n", QhHw->PortNum));\r
- DEBUG ((EFI_D_VERBOSE, "Multiplier : %d\n", QhHw->Multiplier));\r
-\r
- DEBUG ((EFI_D_VERBOSE, "Cur QTD : %x\n", QhHw->CurQtd));\r
-\r
- DEBUG ((EFI_D_VERBOSE, "Next QTD : %x\n", QhHw->NextQtd));\r
- DEBUG ((EFI_D_VERBOSE, "AltNext QTD : %x\n", QhHw->AltQtd));\r
- DEBUG ((EFI_D_VERBOSE, "Status : %x\n", QhHw->Status));\r
+ DEBUG ((DEBUG_VERBOSE, "Hoziontal link: %x\n", QhHw->HorizonLink));\r
+ DEBUG ((DEBUG_VERBOSE, "Device address: %d\n", QhHw->DeviceAddr));\r
+ DEBUG ((DEBUG_VERBOSE, "Inactive : %d\n", QhHw->Inactive));\r
+ DEBUG ((DEBUG_VERBOSE, "EP number : %d\n", QhHw->EpNum));\r
+ DEBUG ((DEBUG_VERBOSE, "EP speed : %d\n", QhHw->EpSpeed));\r
+ DEBUG ((DEBUG_VERBOSE, "DT control : %d\n", QhHw->DtCtrl));\r
+ DEBUG ((DEBUG_VERBOSE, "Reclaim head : %d\n", QhHw->ReclaimHead));\r
+ DEBUG ((DEBUG_VERBOSE, "Max packet len: %d\n", QhHw->MaxPacketLen));\r
+ DEBUG ((DEBUG_VERBOSE, "Ctrl EP : %d\n", QhHw->CtrlEp));\r
+ DEBUG ((DEBUG_VERBOSE, "Nak reload : %d\n", QhHw->NakReload));\r
+\r
+ DEBUG ((DEBUG_VERBOSE, "SMask : %x\n", QhHw->SMask));\r
+ DEBUG ((DEBUG_VERBOSE, "CMask : %x\n", QhHw->CMask));\r
+ DEBUG ((DEBUG_VERBOSE, "Hub address : %d\n", QhHw->HubAddr));\r
+ DEBUG ((DEBUG_VERBOSE, "Hub port : %d\n", QhHw->PortNum));\r
+ DEBUG ((DEBUG_VERBOSE, "Multiplier : %d\n", QhHw->Multiplier));\r
+\r
+ DEBUG ((DEBUG_VERBOSE, "Cur QTD : %x\n", QhHw->CurQtd));\r
+\r
+ DEBUG ((DEBUG_VERBOSE, "Next QTD : %x\n", QhHw->NextQtd));\r
+ DEBUG ((DEBUG_VERBOSE, "AltNext QTD : %x\n", QhHw->AltQtd));\r
+ DEBUG ((DEBUG_VERBOSE, "Status : %x\n", QhHw->Status));\r
\r
EhcDumpStatus (QhHw->Status);\r
\r
if (QhHw->Pid == QTD_PID_SETUP) {\r
- DEBUG ((EFI_D_VERBOSE, "PID : Setup\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "PID : Setup\n"));\r
\r
} else if (QhHw->Pid == QTD_PID_INPUT) {\r
- DEBUG ((EFI_D_VERBOSE, "PID : IN\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "PID : IN\n"));\r
\r
} else if (QhHw->Pid == QTD_PID_OUTPUT) {\r
- DEBUG ((EFI_D_VERBOSE, "PID : OUT\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "PID : OUT\n"));\r
}\r
\r
- DEBUG ((EFI_D_VERBOSE, "Error Count : %d\n", QhHw->ErrCnt));\r
- DEBUG ((EFI_D_VERBOSE, "Current Page : %d\n", QhHw->CurPage));\r
- DEBUG ((EFI_D_VERBOSE, "IOC : %d\n", QhHw->Ioc));\r
- DEBUG ((EFI_D_VERBOSE, "Total Bytes : %d\n", QhHw->TotalBytes));\r
- DEBUG ((EFI_D_VERBOSE, "Data Toggle : %d\n", QhHw->DataToggle));\r
+ DEBUG ((DEBUG_VERBOSE, "Error Count : %d\n", QhHw->ErrCnt));\r
+ DEBUG ((DEBUG_VERBOSE, "Current Page : %d\n", QhHw->CurPage));\r
+ DEBUG ((DEBUG_VERBOSE, "IOC : %d\n", QhHw->Ioc));\r
+ DEBUG ((DEBUG_VERBOSE, "Total Bytes : %d\n", QhHw->TotalBytes));\r
+ DEBUG ((DEBUG_VERBOSE, "Data Toggle : %d\n", QhHw->DataToggle));\r
\r
for (Index = 0; Index < 5; Index++) {\r
- DEBUG ((EFI_D_VERBOSE, "Page[%d] : 0x%x\n", Index, QhHw->Page[Index]));\r
+ DEBUG ((DEBUG_VERBOSE, "Page[%d] : 0x%x\n", Index, QhHw->Page[Index]));\r
}\r
\r
- DEBUG ((EFI_D_VERBOSE, "\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "\n"));\r
\r
BASE_LIST_FOR_EACH (Entry, &Qh->Qtds) {\r
Qtd = EFI_LIST_CONTAINER (Entry, EHC_QTD, QtdList);\r
\r
for (Index = 0; Index < Len; Index++) {\r
if (Index % 16 == 0) {\r
- DEBUG ((EFI_D_VERBOSE,"\n"));\r
+ DEBUG ((DEBUG_VERBOSE,"\n"));\r
}\r
\r
- DEBUG ((EFI_D_VERBOSE, "%02x ", Buf[Index]));\r
+ DEBUG ((DEBUG_VERBOSE, "%02x ", Buf[Index]));\r
}\r
\r
- DEBUG ((EFI_D_VERBOSE, "\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "\n"));\r
}\r
-\r
-\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcReadCapRegister: Pci Io read error - %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "EhcReadCapRegister: Pci Io read error - %r at %d\n", Status, Offset));\r
Data = 0xFFFF;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcReadDbgRegister: Pci Io read error - %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "EhcReadDbgRegister: Pci Io read error - %r at %d\n", Status, Offset));\r
Data = 0xFFFF;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcReadOpReg: Pci Io Read error - %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "EhcReadOpReg: Pci Io Read error - %r at %d\n", Status, Offset));\r
Data = 0xFFFF;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcWriteOpReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "EhcWriteOpReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
}\r
}\r
\r
UINT32 Value;\r
UINT32 TimeOut;\r
\r
- DEBUG ((EFI_D_INFO, "EhcClearLegacySupport: called to clear legacy support\n"));\r
+ DEBUG ((DEBUG_INFO, "EhcClearLegacySupport: called to clear legacy support\n"));\r
\r
PciIo = Ehc->PciIo;\r
ExtendCap = (Ehc->HcCapParams >> 8) & 0xFF;\r
Status = EhcEnablePeriodSchd (Ehc, EHC_GENERIC_TIMEOUT);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcInitHC: failed to enable period schedule\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcInitHC: failed to enable period schedule\n"));\r
return Status;\r
}\r
\r
Status = EhcEnableAsyncSchd (Ehc, EHC_GENERIC_TIMEOUT);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcInitHC: failed to enable async schedule\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcInitHC: failed to enable async schedule\n"));\r
return Status;\r
}\r
\r
Status = EhcSetAndWaitDoorBell (Ehc, EHC_GENERIC_TIMEOUT);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcUnlinkQhFromAsync: Failed to synchronize with doorbell\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcUnlinkQhFromAsync: Failed to synchronize with doorbell\n"));\r
}\r
}\r
\r
//\r
PciAddr = UsbHcGetPciAddressForHostMem (Ehc->MemPool, Ehc->ShortReadStop, sizeof (EHC_QTD));\r
if (QtdHw->AltNext == QTD_LINK (PciAddr, FALSE)) {\r
- DEBUG ((EFI_D_VERBOSE, "EhcCheckUrbResult: Short packet read, break\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "EhcCheckUrbResult: Short packet read, break\n"));\r
\r
Finished = TRUE;\r
goto ON_EXIT;\r
}\r
\r
- DEBUG ((EFI_D_VERBOSE, "EhcCheckUrbResult: Short packet read, continue\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "EhcCheckUrbResult: Short packet read, continue\n"));\r
}\r
}\r
}\r
}\r
\r
if (!Finished) {\r
- DEBUG ((EFI_D_ERROR, "EhcExecTransfer: transfer not finished in %dms\n", (UINT32)TimeOut));\r
+ DEBUG ((DEBUG_ERROR, "EhcExecTransfer: transfer not finished in %dms\n", (UINT32)TimeOut));\r
EhcDumpQh (Urb->Qh, NULL, FALSE);\r
\r
Status = EFI_TIMEOUT;\r
\r
} else if (Urb->Result != EFI_USB_NOERROR) {\r
- DEBUG ((EFI_D_ERROR, "EhcExecTransfer: transfer failed with %x\n", Urb->Result));\r
+ DEBUG ((DEBUG_ERROR, "EhcExecTransfer: transfer failed with %x\n", Urb->Result));\r
EhcDumpQh (Urb->Qh, NULL, FALSE);\r
\r
Status = EFI_DEVICE_ERROR;\r
//\r
Status = EhcFlushAsyncIntMap (Ehc, Urb);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EhcMonitorAsyncRequests: Fail to Flush AsyncInt Mapped Memeory\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcMonitorAsyncRequests: Fail to Flush AsyncInt Mapped Memeory\n"));\r
}\r
\r
//\r
NewBlock = UsbHcAllocMemBlock (Pool, Pages);\r
\r
if (NewBlock == NULL) {\r
- DEBUG ((EFI_D_ERROR, "UsbHcAllocateMem: failed to allocate block\n"));\r
+ DEBUG ((DEBUG_ERROR, "UsbHcAllocateMem: failed to allocate block\n"));\r
return NULL;\r
}\r
\r
AtapiBlkIoDev->PpiDescriptor2.Guid = &gEfiPeiVirtualBlockIo2PpiGuid;\r
AtapiBlkIoDev->PpiDescriptor2.Ppi = &AtapiBlkIoDev->AtapiBlkIo2;\r
\r
- DEBUG ((EFI_D_INFO, "Atatpi Device Count is %d\n", AtapiBlkIoDev->DeviceCount));\r
+ DEBUG ((DEBUG_INFO, "Atatpi Device Count is %d\n", AtapiBlkIoDev->DeviceCount));\r
if (AtapiBlkIoDev->DeviceCount != 0) {\r
Status = PeiServicesInstallPpi (&AtapiBlkIoDev->PpiDescriptor);\r
if (EFI_ERROR (Status)) {\r
//\r
// probe media and retrieve latest media information\r
//\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo DevicePosition is %d\n", AtapiBlkIoDev->DeviceInfo[Index].DevicePosition));\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo DeviceType is %d\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.DeviceType));\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo MediaPresent is %d\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.MediaPresent));\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo BlockSize is 0x%x\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.BlockSize));\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo LastBlock is 0x%x\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.LastBlock));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo DevicePosition is %d\n", AtapiBlkIoDev->DeviceInfo[Index].DevicePosition));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo DeviceType is %d\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.DeviceType));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo MediaPresent is %d\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.MediaPresent));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo BlockSize is 0x%x\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.BlockSize));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo LastBlock is 0x%x\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.LastBlock));\r
\r
Status = DetectMedia (\r
AtapiBlkIoDev,\r
return EFI_DEVICE_ERROR;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo DevicePosition is %d\n", AtapiBlkIoDev->DeviceInfo[Index].DevicePosition));\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo DeviceType is %d\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.DeviceType));\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo MediaPresent is %d\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.MediaPresent));\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo BlockSize is 0x%x\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.BlockSize));\r
- DEBUG ((EFI_D_INFO, "Atatpi GetInfo LastBlock is 0x%x\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.LastBlock));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo DevicePosition is %d\n", AtapiBlkIoDev->DeviceInfo[Index].DevicePosition));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo DeviceType is %d\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.DeviceType));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo MediaPresent is %d\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.MediaPresent));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo BlockSize is 0x%x\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.BlockSize));\r
+ DEBUG ((DEBUG_INFO, "Atatpi GetInfo LastBlock is 0x%x\n", AtapiBlkIoDev->DeviceInfo[Index].MediaInfo.LastBlock));\r
\r
//\r
// Get media info from AtapiBlkIoDev\r
// Allow SATA Devices to spin-up. This is needed if\r
// SEC and PEI phase is too short, for example Release Build.\r
//\r
- DEBUG ((EFI_D_INFO, "Delay for %d seconds for SATA devices to spin-up\n", PcdGet16 (PcdSataSpinUpDelayInSecForRecoveryPath)));\r
+ DEBUG ((DEBUG_INFO, "Delay for %d seconds for SATA devices to spin-up\n", PcdGet16 (PcdSataSpinUpDelayInSecForRecoveryPath)));\r
MicroSecondDelay (PcdGet16 (PcdSataSpinUpDelayInSecForRecoveryPath) * 1000 * 1000); //\r
\r
//\r
CopyMem (&(AtapiBlkIoDev->DeviceInfo[DeviceCount].MediaInfo), &MediaInfo, sizeof (MediaInfo));\r
CopyMem (&(AtapiBlkIoDev->DeviceInfo[DeviceCount].MediaInfo2), &MediaInfo2, sizeof (MediaInfo2));\r
\r
- DEBUG ((EFI_D_INFO, "Atatpi Device Position is %d\n", DevicePosition));\r
- DEBUG ((EFI_D_INFO, "Atatpi DeviceType is %d\n", MediaInfo.DeviceType));\r
- DEBUG ((EFI_D_INFO, "Atatpi MediaPresent is %d\n", MediaInfo.MediaPresent));\r
- DEBUG ((EFI_D_INFO, "Atatpi BlockSize is 0x%x\n", MediaInfo.BlockSize));\r
+ DEBUG ((DEBUG_INFO, "Atatpi Device Position is %d\n", DevicePosition));\r
+ DEBUG ((DEBUG_INFO, "Atatpi DeviceType is %d\n", MediaInfo.DeviceType));\r
+ DEBUG ((DEBUG_INFO, "Atatpi MediaPresent is %d\n", MediaInfo.MediaPresent));\r
+ DEBUG ((DEBUG_INFO, "Atatpi BlockSize is 0x%x\n", MediaInfo.BlockSize));\r
\r
if (EFI_ERROR (Status)) {\r
AtapiBlkIoDev->DeviceInfo[DeviceCount].MediaInfo.MediaPresent = FALSE;\r
SenseBuffers,\r
&SenseCounts\r
);\r
- DEBUG ((EFI_D_INFO, "Atapi Request Sense Count is %d\n", SenseCounts));\r
+ DEBUG ((DEBUG_INFO, "Atapi Request Sense Count is %d\n", SenseCounts));\r
if (IsDeviceStateUnclear (SenseBuffers, SenseCounts) || IsNoMedia (SenseBuffers, SenseCounts)) {\r
//\r
// We are not sure whether the media is present or not, try again\r
//\r
// Dump NvmExpress Identify Namespace Data\r
//\r
- DEBUG ((EFI_D_INFO, " == NVME IDENTIFY NAMESPACE [%d] DATA ==\n", NamespaceId));\r
- DEBUG ((EFI_D_INFO, " NSZE : 0x%x\n", NamespaceData->Nsze));\r
- DEBUG ((EFI_D_INFO, " NCAP : 0x%x\n", NamespaceData->Ncap));\r
- DEBUG ((EFI_D_INFO, " NUSE : 0x%x\n", NamespaceData->Nuse));\r
- DEBUG ((EFI_D_INFO, " LBAF0.LBADS : 0x%x\n", (NamespaceData->LbaFormat[0].Lbads)));\r
+ DEBUG ((DEBUG_INFO, " == NVME IDENTIFY NAMESPACE [%d] DATA ==\n", NamespaceId));\r
+ DEBUG ((DEBUG_INFO, " NSZE : 0x%x\n", NamespaceData->Nsze));\r
+ DEBUG ((DEBUG_INFO, " NCAP : 0x%x\n", NamespaceData->Ncap));\r
+ DEBUG ((DEBUG_INFO, " NUSE : 0x%x\n", NamespaceData->Nuse));\r
+ DEBUG ((DEBUG_INFO, " LBAF0.LBADS : 0x%x\n", (NamespaceData->LbaFormat[0].Lbads)));\r
\r
//\r
// Build controller name for Component Name (2) protocol.\r
UINTN Bytes;\r
EFI_NVM_EXPRESS_PASS_THRU_PROTOCOL *Passthru;\r
\r
- DEBUG ((EFI_D_INFO, "NvmExpressDriverBindingStart: start\n"));\r
+ DEBUG ((DEBUG_INFO, "NvmExpressDriverBindingStart: start\n"));\r
\r
Private = NULL;\r
Passthru = NULL;\r
Private = AllocateZeroPool (sizeof (NVME_CONTROLLER_PRIVATE_DATA));\r
\r
if (Private == NULL) {\r
- DEBUG ((EFI_D_ERROR, "NvmExpressDriverBindingStart: allocating pool for Nvme Private Data failed!\n"));\r
+ DEBUG ((DEBUG_ERROR, "NvmExpressDriverBindingStart: allocating pool for Nvme Private Data failed!\n"));\r
Status = EFI_OUT_OF_RESOURCES;\r
goto Exit;\r
}\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "NvmExpressDriverBindingStart: end successfully\n"));\r
+ DEBUG ((DEBUG_INFO, "NvmExpressDriverBindingStart: end successfully\n"));\r
return EFI_SUCCESS;\r
\r
Exit:\r
Controller\r
);\r
\r
- DEBUG ((EFI_D_INFO, "NvmExpressDriverBindingStart: end with %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "NvmExpressDriverBindingStart: end with %r\n", Status));\r
\r
return Status;\r
}\r
return Status;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Cc.En: %d\n", Cc->En));\r
- DEBUG ((EFI_D_INFO, "Cc.Css: %d\n", Cc->Css));\r
- DEBUG ((EFI_D_INFO, "Cc.Mps: %d\n", Cc->Mps));\r
- DEBUG ((EFI_D_INFO, "Cc.Ams: %d\n", Cc->Ams));\r
- DEBUG ((EFI_D_INFO, "Cc.Shn: %d\n", Cc->Shn));\r
- DEBUG ((EFI_D_INFO, "Cc.Iosqes: %d\n", Cc->Iosqes));\r
- DEBUG ((EFI_D_INFO, "Cc.Iocqes: %d\n", Cc->Iocqes));\r
+ DEBUG ((DEBUG_INFO, "Cc.En: %d\n", Cc->En));\r
+ DEBUG ((DEBUG_INFO, "Cc.Css: %d\n", Cc->Css));\r
+ DEBUG ((DEBUG_INFO, "Cc.Mps: %d\n", Cc->Mps));\r
+ DEBUG ((DEBUG_INFO, "Cc.Ams: %d\n", Cc->Ams));\r
+ DEBUG ((DEBUG_INFO, "Cc.Shn: %d\n", Cc->Shn));\r
+ DEBUG ((DEBUG_INFO, "Cc.Iosqes: %d\n", Cc->Iosqes));\r
+ DEBUG ((DEBUG_INFO, "Cc.Iocqes: %d\n", Cc->Iocqes));\r
\r
return EFI_SUCCESS;\r
}\r
return Status;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Aqa.Asqs: %d\n", Aqa->Asqs));\r
- DEBUG ((EFI_D_INFO, "Aqa.Acqs: %d\n", Aqa->Acqs));\r
+ DEBUG ((DEBUG_INFO, "Aqa.Asqs: %d\n", Aqa->Asqs));\r
+ DEBUG ((DEBUG_INFO, "Aqa.Acqs: %d\n", Aqa->Acqs));\r
\r
return EFI_SUCCESS;\r
}\r
return Status;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Asq: %lx\n", *Asq));\r
+ DEBUG ((DEBUG_INFO, "Asq: %lx\n", *Asq));\r
\r
return EFI_SUCCESS;\r
}\r
return Status;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Acq: %lxh\n", *Acq));\r
+ DEBUG ((DEBUG_INFO, "Acq: %lxh\n", *Acq));\r
\r
return EFI_SUCCESS;\r
}\r
);\r
}\r
\r
- DEBUG ((EFI_D_INFO, "NVMe controller is disabled with status [%r].\n", Status));\r
+ DEBUG ((DEBUG_INFO, "NVMe controller is disabled with status [%r].\n", Status));\r
return Status;\r
}\r
\r
);\r
}\r
\r
- DEBUG ((EFI_D_INFO, "NVMe controller is enabled with status [%r].\n", Status));\r
+ DEBUG ((DEBUG_INFO, "NVMe controller is enabled with status [%r].\n", Status));\r
return Status;\r
}\r
\r
}\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "NvmeControllerInit: failed to enable controller\n"));\r
+ DEBUG ((DEBUG_INFO, "NvmeControllerInit: failed to enable controller\n"));\r
return Status;\r
}\r
\r
NULL\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_WARN, "NvmeControllerInit: failed to enable 64-bit DMA (%r)\n", Status));\r
+ DEBUG ((DEBUG_WARN, "NvmeControllerInit: failed to enable 64-bit DMA (%r)\n", Status));\r
}\r
\r
//\r
}\r
\r
if (Private->Cap.Css != 0x01) {\r
- DEBUG ((EFI_D_INFO, "NvmeControllerInit: the controller doesn't support NVMe command set\n"));\r
+ DEBUG ((DEBUG_INFO, "NvmeControllerInit: the controller doesn't support NVMe command set\n"));\r
return EFI_UNSUPPORTED;\r
}\r
\r
Private->CqBuffer[2] = (NVME_CQ *)(UINTN)(Private->Buffer + 5 * EFI_PAGE_SIZE);\r
Private->CqBufferPciAddr[2] = (NVME_CQ *)(UINTN)(Private->BufferPciAddr + 5 * EFI_PAGE_SIZE);\r
\r
- DEBUG ((EFI_D_INFO, "Private->Buffer = [%016X]\n", (UINT64)(UINTN)Private->Buffer));\r
- DEBUG ((EFI_D_INFO, "Admin Submission Queue size (Aqa.Asqs) = [%08X]\n", Aqa.Asqs));\r
- DEBUG ((EFI_D_INFO, "Admin Completion Queue size (Aqa.Acqs) = [%08X]\n", Aqa.Acqs));\r
- DEBUG ((EFI_D_INFO, "Admin Submission Queue (SqBuffer[0]) = [%016X]\n", Private->SqBuffer[0]));\r
- DEBUG ((EFI_D_INFO, "Admin Completion Queue (CqBuffer[0]) = [%016X]\n", Private->CqBuffer[0]));\r
- DEBUG ((EFI_D_INFO, "Sync I/O Submission Queue (SqBuffer[1]) = [%016X]\n", Private->SqBuffer[1]));\r
- DEBUG ((EFI_D_INFO, "Sync I/O Completion Queue (CqBuffer[1]) = [%016X]\n", Private->CqBuffer[1]));\r
- DEBUG ((EFI_D_INFO, "Async I/O Submission Queue (SqBuffer[2]) = [%016X]\n", Private->SqBuffer[2]));\r
- DEBUG ((EFI_D_INFO, "Async I/O Completion Queue (CqBuffer[2]) = [%016X]\n", Private->CqBuffer[2]));\r
+ DEBUG ((DEBUG_INFO, "Private->Buffer = [%016X]\n", (UINT64)(UINTN)Private->Buffer));\r
+ DEBUG ((DEBUG_INFO, "Admin Submission Queue size (Aqa.Asqs) = [%08X]\n", Aqa.Asqs));\r
+ DEBUG ((DEBUG_INFO, "Admin Completion Queue size (Aqa.Acqs) = [%08X]\n", Aqa.Acqs));\r
+ DEBUG ((DEBUG_INFO, "Admin Submission Queue (SqBuffer[0]) = [%016X]\n", Private->SqBuffer[0]));\r
+ DEBUG ((DEBUG_INFO, "Admin Completion Queue (CqBuffer[0]) = [%016X]\n", Private->CqBuffer[0]));\r
+ DEBUG ((DEBUG_INFO, "Sync I/O Submission Queue (SqBuffer[1]) = [%016X]\n", Private->SqBuffer[1]));\r
+ DEBUG ((DEBUG_INFO, "Sync I/O Completion Queue (CqBuffer[1]) = [%016X]\n", Private->CqBuffer[1]));\r
+ DEBUG ((DEBUG_INFO, "Async I/O Submission Queue (SqBuffer[2]) = [%016X]\n", Private->SqBuffer[2]));\r
+ DEBUG ((DEBUG_INFO, "Async I/O Completion Queue (CqBuffer[2]) = [%016X]\n", Private->CqBuffer[2]));\r
\r
//\r
// Program admin queue attributes.\r
Sn[20] = 0;\r
CopyMem (Mn, Private->ControllerData->Mn, sizeof (Private->ControllerData->Mn));\r
Mn[40] = 0;\r
- DEBUG ((EFI_D_INFO, " == NVME IDENTIFY CONTROLLER DATA ==\n"));\r
- DEBUG ((EFI_D_INFO, " PCI VID : 0x%x\n", Private->ControllerData->Vid));\r
- DEBUG ((EFI_D_INFO, " PCI SSVID : 0x%x\n", Private->ControllerData->Ssvid));\r
- DEBUG ((EFI_D_INFO, " SN : %a\n", Sn));\r
- DEBUG ((EFI_D_INFO, " MN : %a\n", Mn));\r
- DEBUG ((EFI_D_INFO, " FR : 0x%x\n", *((UINT64*)Private->ControllerData->Fr)));\r
+ DEBUG ((DEBUG_INFO, " == NVME IDENTIFY CONTROLLER DATA ==\n"));\r
+ DEBUG ((DEBUG_INFO, " PCI VID : 0x%x\n", Private->ControllerData->Vid));\r
+ DEBUG ((DEBUG_INFO, " PCI SSVID : 0x%x\n", Private->ControllerData->Ssvid));\r
+ DEBUG ((DEBUG_INFO, " SN : %a\n", Sn));\r
+ DEBUG ((DEBUG_INFO, " MN : %a\n", Mn));\r
+ DEBUG ((DEBUG_INFO, " FR : 0x%x\n", *((UINT64*)Private->ControllerData->Fr)));\r
DEBUG ((DEBUG_INFO, " TNVMCAP (high 8-byte) : 0x%lx\n", *((UINT64*)(Private->ControllerData->Tnvmcap + 8))));\r
DEBUG ((DEBUG_INFO, " TNVMCAP (low 8-byte) : 0x%lx\n", *((UINT64*)Private->ControllerData->Tnvmcap)));\r
- DEBUG ((EFI_D_INFO, " RAB : 0x%x\n", Private->ControllerData->Rab));\r
- DEBUG ((EFI_D_INFO, " IEEE : 0x%x\n", *(UINT32*)Private->ControllerData->Ieee_oui));\r
- DEBUG ((EFI_D_INFO, " AERL : 0x%x\n", Private->ControllerData->Aerl));\r
- DEBUG ((EFI_D_INFO, " SQES : 0x%x\n", Private->ControllerData->Sqes));\r
- DEBUG ((EFI_D_INFO, " CQES : 0x%x\n", Private->ControllerData->Cqes));\r
- DEBUG ((EFI_D_INFO, " NN : 0x%x\n", Private->ControllerData->Nn));\r
+ DEBUG ((DEBUG_INFO, " RAB : 0x%x\n", Private->ControllerData->Rab));\r
+ DEBUG ((DEBUG_INFO, " IEEE : 0x%x\n", *(UINT32*)Private->ControllerData->Ieee_oui));\r
+ DEBUG ((DEBUG_INFO, " AERL : 0x%x\n", Private->ControllerData->Aerl));\r
+ DEBUG ((DEBUG_INFO, " SQES : 0x%x\n", Private->ControllerData->Sqes));\r
+ DEBUG ((DEBUG_INFO, " CQES : 0x%x\n", Private->ControllerData->Cqes));\r
+ DEBUG ((DEBUG_INFO, " NN : 0x%x\n", Private->ControllerData->Nn));\r
\r
//\r
// Create two I/O completion queues.\r
IN NVME_CQ *Cq\r
)\r
{\r
- DEBUG ((EFI_D_VERBOSE, "Dump NVMe Completion Entry Status from [0x%x]:\n", Cq));\r
+ DEBUG ((DEBUG_VERBOSE, "Dump NVMe Completion Entry Status from [0x%x]:\n", Cq));\r
\r
- DEBUG ((EFI_D_VERBOSE, " SQ Identifier : [0x%x], Phase Tag : [%d], Cmd Identifier : [0x%x]\n", Cq->Sqid, Cq->Pt, Cq->Cid));\r
+ DEBUG ((DEBUG_VERBOSE, " SQ Identifier : [0x%x], Phase Tag : [%d], Cmd Identifier : [0x%x]\n", Cq->Sqid, Cq->Pt, Cq->Cid));\r
\r
- DEBUG ((EFI_D_VERBOSE, " NVMe Cmd Execution Result - "));\r
+ DEBUG ((DEBUG_VERBOSE, " NVMe Cmd Execution Result - "));\r
\r
switch (Cq->Sct) {\r
case 0x0:\r
switch (Cq->Sc) {\r
case 0x0:\r
- DEBUG ((EFI_D_VERBOSE, "Successful Completion\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Successful Completion\n"));\r
break;\r
case 0x1:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Command Opcode\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Command Opcode\n"));\r
break;\r
case 0x2:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Field in Command\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Field in Command\n"));\r
break;\r
case 0x3:\r
- DEBUG ((EFI_D_VERBOSE, "Command ID Conflict\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Command ID Conflict\n"));\r
break;\r
case 0x4:\r
- DEBUG ((EFI_D_VERBOSE, "Data Transfer Error\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Data Transfer Error\n"));\r
break;\r
case 0x5:\r
- DEBUG ((EFI_D_VERBOSE, "Commands Aborted due to Power Loss Notification\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Commands Aborted due to Power Loss Notification\n"));\r
break;\r
case 0x6:\r
- DEBUG ((EFI_D_VERBOSE, "Internal Device Error\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Internal Device Error\n"));\r
break;\r
case 0x7:\r
- DEBUG ((EFI_D_VERBOSE, "Command Abort Requested\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Command Abort Requested\n"));\r
break;\r
case 0x8:\r
- DEBUG ((EFI_D_VERBOSE, "Command Aborted due to SQ Deletion\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Command Aborted due to SQ Deletion\n"));\r
break;\r
case 0x9:\r
- DEBUG ((EFI_D_VERBOSE, "Command Aborted due to Failed Fused Command\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Command Aborted due to Failed Fused Command\n"));\r
break;\r
case 0xA:\r
- DEBUG ((EFI_D_VERBOSE, "Command Aborted due to Missing Fused Command\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Command Aborted due to Missing Fused Command\n"));\r
break;\r
case 0xB:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Namespace or Format\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Namespace or Format\n"));\r
break;\r
case 0xC:\r
- DEBUG ((EFI_D_VERBOSE, "Command Sequence Error\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Command Sequence Error\n"));\r
break;\r
case 0xD:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid SGL Last Segment Descriptor\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid SGL Last Segment Descriptor\n"));\r
break;\r
case 0xE:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Number of SGL Descriptors\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Number of SGL Descriptors\n"));\r
break;\r
case 0xF:\r
- DEBUG ((EFI_D_VERBOSE, "Data SGL Length Invalid\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Data SGL Length Invalid\n"));\r
break;\r
case 0x10:\r
- DEBUG ((EFI_D_VERBOSE, "Metadata SGL Length Invalid\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Metadata SGL Length Invalid\n"));\r
break;\r
case 0x11:\r
- DEBUG ((EFI_D_VERBOSE, "SGL Descriptor Type Invalid\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "SGL Descriptor Type Invalid\n"));\r
break;\r
case 0x80:\r
- DEBUG ((EFI_D_VERBOSE, "LBA Out of Range\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "LBA Out of Range\n"));\r
break;\r
case 0x81:\r
- DEBUG ((EFI_D_VERBOSE, "Capacity Exceeded\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Capacity Exceeded\n"));\r
break;\r
case 0x82:\r
- DEBUG ((EFI_D_VERBOSE, "Namespace Not Ready\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Namespace Not Ready\n"));\r
break;\r
case 0x83:\r
- DEBUG ((EFI_D_VERBOSE, "Reservation Conflict\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Reservation Conflict\n"));\r
break;\r
}\r
break;\r
case 0x1:\r
switch (Cq->Sc) {\r
case 0x0:\r
- DEBUG ((EFI_D_VERBOSE, "Completion Queue Invalid\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Completion Queue Invalid\n"));\r
break;\r
case 0x1:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Queue Identifier\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Queue Identifier\n"));\r
break;\r
case 0x2:\r
- DEBUG ((EFI_D_VERBOSE, "Maximum Queue Size Exceeded\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Maximum Queue Size Exceeded\n"));\r
break;\r
case 0x3:\r
- DEBUG ((EFI_D_VERBOSE, "Abort Command Limit Exceeded\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Abort Command Limit Exceeded\n"));\r
break;\r
case 0x5:\r
- DEBUG ((EFI_D_VERBOSE, "Asynchronous Event Request Limit Exceeded\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Asynchronous Event Request Limit Exceeded\n"));\r
break;\r
case 0x6:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Firmware Slot\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Firmware Slot\n"));\r
break;\r
case 0x7:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Firmware Image\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Firmware Image\n"));\r
break;\r
case 0x8:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Interrupt Vector\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Interrupt Vector\n"));\r
break;\r
case 0x9:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Log Page\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Log Page\n"));\r
break;\r
case 0xA:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Format\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Format\n"));\r
break;\r
case 0xB:\r
- DEBUG ((EFI_D_VERBOSE, "Firmware Application Requires Conventional Reset\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Firmware Application Requires Conventional Reset\n"));\r
break;\r
case 0xC:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Queue Deletion\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Queue Deletion\n"));\r
break;\r
case 0xD:\r
- DEBUG ((EFI_D_VERBOSE, "Feature Identifier Not Saveable\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Feature Identifier Not Saveable\n"));\r
break;\r
case 0xE:\r
- DEBUG ((EFI_D_VERBOSE, "Feature Not Changeable\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Feature Not Changeable\n"));\r
break;\r
case 0xF:\r
- DEBUG ((EFI_D_VERBOSE, "Feature Not Namespace Specific\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Feature Not Namespace Specific\n"));\r
break;\r
case 0x10:\r
- DEBUG ((EFI_D_VERBOSE, "Firmware Application Requires NVM Subsystem Reset\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Firmware Application Requires NVM Subsystem Reset\n"));\r
break;\r
case 0x80:\r
- DEBUG ((EFI_D_VERBOSE, "Conflicting Attributes\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Conflicting Attributes\n"));\r
break;\r
case 0x81:\r
- DEBUG ((EFI_D_VERBOSE, "Invalid Protection Information\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Invalid Protection Information\n"));\r
break;\r
case 0x82:\r
- DEBUG ((EFI_D_VERBOSE, "Attempted Write to Read Only Range\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Attempted Write to Read Only Range\n"));\r
break;\r
}\r
break;\r
case 0x2:\r
switch (Cq->Sc) {\r
case 0x80:\r
- DEBUG ((EFI_D_VERBOSE, "Write Fault\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Write Fault\n"));\r
break;\r
case 0x81:\r
- DEBUG ((EFI_D_VERBOSE, "Unrecovered Read Error\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Unrecovered Read Error\n"));\r
break;\r
case 0x82:\r
- DEBUG ((EFI_D_VERBOSE, "End-to-end Guard Check Error\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "End-to-end Guard Check Error\n"));\r
break;\r
case 0x83:\r
- DEBUG ((EFI_D_VERBOSE, "End-to-end Application Tag Check Error\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "End-to-end Application Tag Check Error\n"));\r
break;\r
case 0x84:\r
- DEBUG ((EFI_D_VERBOSE, "End-to-end Reference Tag Check Error\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "End-to-end Reference Tag Check Error\n"));\r
break;\r
case 0x85:\r
- DEBUG ((EFI_D_VERBOSE, "Compare Failure\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Compare Failure\n"));\r
break;\r
case 0x86:\r
- DEBUG ((EFI_D_VERBOSE, "Access Denied\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Access Denied\n"));\r
break;\r
}\r
break;\r
);\r
\r
if (EFI_ERROR (Status) || (Bytes != EFI_PAGES_TO_SIZE (*PrpListNo))) {\r
- DEBUG ((EFI_D_ERROR, "NvmeCreatePrpList: create PrpList failure!\n"));\r
+ DEBUG ((DEBUG_ERROR, "NvmeCreatePrpList: create PrpList failure!\n"));\r
goto EXIT;\r
}\r
//\r
//\r
ASSERT (Sq->Psdt == 0);\r
if (Sq->Psdt != 0) {\r
- DEBUG ((EFI_D_ERROR, "NvmExpressPassThru: doesn't support SGL mechanism\n"));\r
+ DEBUG ((DEBUG_ERROR, "NvmExpressPassThru: doesn't support SGL mechanism\n"));\r
return EFI_UNSUPPORTED;\r
}\r
\r
\r
return Status;\r
}\r
-\r
Status = RejectPciDevice (PciResNode->PciDev);\r
if (Status == EFI_SUCCESS) {\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
"PciBus: [%02x|%02x|%02x] was rejected due to resource confliction.\n",\r
PciResNode->PciDev->BusNumber, PciResNode->PciDev->DeviceNumber, PciResNode->PciDev->FunctionNumber\r
));\r
\r
return EFI_SUCCESS;\r
}\r
-\r
PciIoDevice = NULL;\r
\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"PciBus: Discovered %s @ [%02x|%02x|%02x]\n",\r
IS_PCI_BRIDGE (Pci) ? L"PPB" :\r
IS_CARDBUS_BRIDGE (Pci) ? L"P2C" :\r
\r
if ((Type != PciBarTypeUnknown) && ((ResourceType == PciBarTypeUnknown) || (ResourceType == Type))) {\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
" Padding: Type = %s; Alignment = 0x%lx;\tLength = 0x%lx\n",\r
mBarTypeStr[Type], Descriptor->AddrRangeMax, Descriptor->AddrLen\r
));\r
}\r
\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
" BAR[%d]: Type = %s; Alignment = 0x%lx;\tLength = 0x%lx;\tOffset = 0x%02x\n",\r
Index, mBarTypeStr[MIN (PciIoDevice->PciBar[Index].BarType, PciBarTypeMaxType)],\r
PciIoDevice->PciBar[Index].Alignment, PciIoDevice->PciBar[Index].Length, PciIoDevice->PciBar[Index].Offset\r
}\r
\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
" VFBAR[%d]: Type = %s; Alignment = 0x%lx;\tLength = 0x%lx;\tOffset = 0x%02x\n",\r
Index, mBarTypeStr[MIN (PciIoDevice->VfPciBar[Index].BarType, PciBarTypeMaxType)],\r
PciIoDevice->VfPciBar[Index].Alignment, PciIoDevice->VfPciBar[Index].Length, PciIoDevice->VfPciBar[Index].Offset\r
));\r
}\r
- DEBUG ((EFI_D_INFO, "\n"));\r
+ DEBUG ((DEBUG_INFO, "\n"));\r
}\r
\r
/**\r
// Fix the length to support some special 64 bit BAR\r
//\r
if (Value == 0) {\r
- DEBUG ((EFI_D_INFO, "[PciBus]BAR probing for upper 32bit of MEM64 BAR returns 0, change to 0xFFFFFFFF.\n"));\r
+ DEBUG ((DEBUG_INFO, "[PciBus]BAR probing for upper 32bit of MEM64 BAR returns 0, change to 0xFFFFFFFF.\n"));\r
Value = (UINT32) -1;\r
} else {\r
Value |= ((UINT32)(-1) << HighBitSet32 (Value));\r
&Data32\r
);\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
" ARI: forwarding enabled for PPB[%02x:%02x:%02x]\n",\r
Bridge->BusNumber,\r
Bridge->DeviceNumber,\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, " ARI: CapOffset = 0x%x\n", PciIoDevice->AriCapabilityOffset));\r
+ DEBUG ((DEBUG_INFO, " ARI: CapOffset = 0x%x\n", PciIoDevice->AriCapabilityOffset));\r
}\r
}\r
\r
PciIoDevice->ReservedBusNum = (UINT16)(EFI_PCI_BUS_OF_RID (LastVF) - Bus + 1);\r
\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
" SR-IOV: SupportedPageSize = 0x%x; SystemPageSize = 0x%x; FirstVFOffset = 0x%x;\n",\r
SupportedPageSize, PciIoDevice->SystemPageSize >> 12, FirstVFOffset\r
));\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
" InitialVFs = 0x%x; ReservedBusNum = 0x%x; CapOffset = 0x%x\n",\r
PciIoDevice->InitialVFs, PciIoDevice->ReservedBusNum, PciIoDevice->SrIovCapabilityOffset\r
));\r
NULL\r
);\r
if (!EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, " MR-IOV: CapOffset = 0x%x\n", PciIoDevice->MrIovCapabilityOffset));\r
+ DEBUG ((DEBUG_INFO, " MR-IOV: CapOffset = 0x%x\n", PciIoDevice->MrIovCapabilityOffset));\r
}\r
}\r
\r
}\r
}\r
}\r
-\r
\r
if ((BridgeResource != NULL) && (BridgeResource->Length != 0)) {\r
DEBUG ((\r
- EFI_D_INFO, "Type = %s; Base = 0x%lx;\tLength = 0x%lx;\tAlignment = 0x%lx\n",\r
+ DEBUG_INFO, "Type = %s; Base = 0x%lx;\tLength = 0x%lx;\tAlignment = 0x%lx\n",\r
mBarTypeStr[MIN (BridgeResource->ResType, PciBarTypeMaxType)],\r
BridgeResource->PciDev->PciBar[BridgeResource->Bar].BaseAddress,\r
BridgeResource->Length, BridgeResource->Alignment\r
if (Resource->ResourceUsage == PciResUsageTypical) {\r
Bar = Resource->Virtual ? Resource->PciDev->VfPciBar : Resource->PciDev->PciBar;\r
DEBUG ((\r
- EFI_D_INFO, " Base = 0x%lx;\tLength = 0x%lx;\tAlignment = 0x%lx;\tOwner = %s [%02x|%02x|%02x:",\r
+ DEBUG_INFO, " Base = 0x%lx;\tLength = 0x%lx;\tAlignment = 0x%lx;\tOwner = %s [%02x|%02x|%02x:",\r
Bar[Resource->Bar].BaseAddress, Resource->Length, Resource->Alignment,\r
IS_PCI_BRIDGE (&Resource->PciDev->Pci) ? L"PPB" :\r
IS_CARDBUS_BRIDGE (&Resource->PciDev->Pci) ? L"P2C" :\r
//\r
// The resource requirement comes from the device itself.\r
//\r
- DEBUG ((EFI_D_INFO, "%02x]", Bar[Resource->Bar].Offset));\r
+ DEBUG ((DEBUG_INFO, "%02x]", Bar[Resource->Bar].Offset));\r
} else {\r
//\r
// The resource requirement comes from the subordinate devices.\r
//\r
- DEBUG ((EFI_D_INFO, "**]"));\r
+ DEBUG ((DEBUG_INFO, "**]"));\r
}\r
} else {\r
- DEBUG ((EFI_D_INFO, " Base = Padding;\tLength = 0x%lx;\tAlignment = 0x%lx", Resource->Length, Resource->Alignment));\r
+ DEBUG ((DEBUG_INFO, " Base = Padding;\tLength = 0x%lx;\tAlignment = 0x%lx", Resource->Length, Resource->Alignment));\r
}\r
if (BridgeResource->ResType != Resource->ResType) {\r
- DEBUG ((EFI_D_INFO, "; Type = %s", mBarTypeStr[MIN (Resource->ResType, PciBarTypeMaxType)]));\r
+ DEBUG ((DEBUG_INFO, "; Type = %s", mBarTypeStr[MIN (Resource->ResType, PciBarTypeMaxType)]));\r
}\r
- DEBUG ((EFI_D_INFO, "\n"));\r
+ DEBUG ((DEBUG_INFO, "\n"));\r
}\r
}\r
}\r
PCI_RESOURCE_NODE **ChildResources;\r
UINTN ChildResourceCount;\r
\r
- DEBUG ((EFI_D_INFO, "PciBus: Resource Map for "));\r
+ DEBUG ((DEBUG_INFO, "PciBus: Resource Map for "));\r
\r
Status = gBS->OpenProtocol (\r
Bridge->Handle,\r
);\r
if (EFI_ERROR (Status)) {\r
DEBUG ((\r
- EFI_D_INFO, "Bridge [%02x|%02x|%02x]\n",\r
+ DEBUG_INFO, "Bridge [%02x|%02x|%02x]\n",\r
Bridge->BusNumber, Bridge->DeviceNumber, Bridge->FunctionNumber\r
));\r
} else {\r
FALSE,\r
FALSE\r
);\r
- DEBUG ((EFI_D_INFO, "Root Bridge %s\n", Str != NULL ? Str : L""));\r
+ DEBUG ((DEBUG_INFO, "Root Bridge %s\n", Str != NULL ? Str : L""));\r
if (Str != NULL) {\r
FreePool (Str);\r
}\r
for (Index = 0; Index < ResourceCount; Index++) {\r
DumpBridgeResource (Resources[Index]);\r
}\r
- DEBUG ((EFI_D_INFO, "\n"));\r
+ DEBUG ((DEBUG_INFO, "\n"));\r
\r
for ( Link = Bridge->ChildList.ForwardLink\r
; Link != &Bridge->ChildList\r
// If SubmitResources returns error, PciBus isn't able to start.\r
// It's a fatal error so assertion is added.\r
//\r
- DEBUG ((EFI_D_INFO, "PciBus: HostBridge->SubmitResources() - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "PciBus: HostBridge->SubmitResources() - %r\n", Status));\r
ASSERT_EFI_ERROR (Status);\r
}\r
\r
// Notify platform to start to program the resource\r
//\r
Status = NotifyPhase (PciResAlloc, EfiPciHostBridgeAllocateResources);\r
- DEBUG ((EFI_D_INFO, "PciBus: HostBridge->NotifyPhase(AllocateResources) - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "PciBus: HostBridge->NotifyPhase(AllocateResources) - %r\n", Status));\r
if (!FeaturePcdGet (PcdPciBusHotplugDeviceSupport)) {\r
//\r
// If Hot Plug is not supported\r
TempReservedBusNum = PciDevice->ReservedBusNum;\r
\r
if (Func == 0) {\r
- DEBUG ((EFI_D_INFO, "PCI-IOV ScanBus - SubBusNumber - 0x%x\n", *SubBusNumber));\r
+ DEBUG ((DEBUG_INFO, "PCI-IOV ScanBus - SubBusNumber - 0x%x\n", *SubBusNumber));\r
} else {\r
- DEBUG ((EFI_D_INFO, "PCI-IOV ScanBus - SubBusNumber - 0x%x (Update)\n", *SubBusNumber));\r
+ DEBUG ((DEBUG_INFO, "PCI-IOV ScanBus - SubBusNumber - 0x%x (Update)\n", *SubBusNumber));\r
}\r
}\r
}\r
return Status;\r
}\r
\r
- DEBUG((EFI_D_INFO, "PCI Bus First Scanning\n"));\r
+ DEBUG((DEBUG_INFO, "PCI Bus First Scanning\n"));\r
RootBridgeHandle = NULL;\r
while (PciResAlloc->GetNextRootBridge (PciResAlloc, &RootBridgeHandle) == EFI_SUCCESS) {\r
\r
Status = AllRootHPCInitialized (STALL_1_SECOND * 15);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Some root HPC failed to initialize\n"));\r
+ DEBUG ((DEBUG_ERROR, "Some root HPC failed to initialize\n"));\r
return Status;\r
}\r
\r
return Status;\r
}\r
\r
- DEBUG((EFI_D_INFO, "PCI Bus Second Scanning\n"));\r
+ DEBUG((DEBUG_INFO, "PCI Bus Second Scanning\n"));\r
RootBridgeHandle = NULL;\r
while (PciResAlloc->GetNextRootBridge (PciResAlloc, &RootBridgeHandle) == EFI_SUCCESS) {\r
\r
Status = gDS->AddIoSpace (EfiGcdIoTypeIo, IntersectionBase,\r
IntersectionEnd - IntersectionBase);\r
\r
- DEBUG ((EFI_ERROR (Status) ? EFI_D_ERROR : EFI_D_VERBOSE,\r
+ DEBUG ((EFI_ERROR (Status) ? DEBUG_ERROR : DEBUG_VERBOSE,\r
"%a: %a: add [%Lx, %Lx): %r\n", gEfiCallerBaseName, __FUNCTION__,\r
IntersectionBase, IntersectionEnd, Status));\r
return Status;\r
}\r
\r
- DEBUG ((EFI_D_ERROR, "%a: %a: desc [%Lx, %Lx) type %u conflicts with "\r
+ DEBUG ((DEBUG_ERROR, "%a: %a: desc [%Lx, %Lx) type %u conflicts with "\r
"aperture [%Lx, %Lx)\n", gEfiCallerBaseName, __FUNCTION__,\r
Descriptor->BaseAddress, Descriptor->BaseAddress + Descriptor->Length,\r
(UINT32)Descriptor->GcdIoType, Base, Base + Length));\r
\r
Status = gDS->GetIoSpaceMap (&NumberOfDescriptors, &IoSpaceMap);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "%a: %a: GetIoSpaceMap(): %r\n",\r
+ DEBUG ((DEBUG_ERROR, "%a: %a: GetIoSpaceMap(): %r\n",\r
gEfiCallerBaseName, __FUNCTION__, Status));\r
return Status;\r
}\r
IntersectionBase, IntersectionEnd - IntersectionBase,\r
Capabilities);\r
\r
- DEBUG ((EFI_ERROR (Status) ? EFI_D_ERROR : EFI_D_VERBOSE,\r
+ DEBUG ((EFI_ERROR (Status) ? DEBUG_ERROR : DEBUG_VERBOSE,\r
"%a: %a: add [%Lx, %Lx): %r\n", gEfiCallerBaseName, __FUNCTION__,\r
IntersectionBase, IntersectionEnd, Status));\r
return Status;\r
}\r
\r
- DEBUG ((EFI_D_ERROR, "%a: %a: desc [%Lx, %Lx) type %u cap %Lx conflicts "\r
+ DEBUG ((DEBUG_ERROR, "%a: %a: desc [%Lx, %Lx) type %u cap %Lx conflicts "\r
"with aperture [%Lx, %Lx) cap %Lx\n", gEfiCallerBaseName, __FUNCTION__,\r
Descriptor->BaseAddress, Descriptor->BaseAddress + Descriptor->Length,\r
(UINT32)Descriptor->GcdMemoryType, Descriptor->Capabilities,\r
\r
Status = gDS->GetMemorySpaceMap (&NumberOfDescriptors, &MemorySpaceMap);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "%a: %a: GetMemorySpaceMap(): %r\n",\r
+ DEBUG ((DEBUG_ERROR, "%a: %a: GetMemorySpaceMap(): %r\n",\r
gEfiCallerBaseName, __FUNCTION__, Status));\r
return Status;\r
}\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "PciHostBridge: NotifyPhase (AllocateResources)\n"));\r
+ DEBUG ((DEBUG_INFO, "PciHostBridge: NotifyPhase (AllocateResources)\n"));\r
for (Link = GetFirstNode (&HostBridge->RootBridges)\r
; !IsNull (&HostBridge->RootBridges, Link)\r
; Link = GetNextNode (&HostBridge->RootBridges, Link)\r
}\r
\r
RootBridge = ROOT_BRIDGE_FROM_LINK (Link);\r
- DEBUG ((EFI_D_INFO, " RootBridge: %s\n", RootBridge->DevicePathStr));\r
+ DEBUG ((DEBUG_INFO, " RootBridge: %s\n", RootBridge->DevicePathStr));\r
\r
for (Index1 = TypeIo; Index1 < TypeBus; Index1++) {\r
if (RootBridge->ResAllocNode[Index1].Status == ResNone) {\r
) {\r
RootBridge = ROOT_BRIDGE_FROM_LINK (Link);\r
if (RootBridgeHandle == RootBridge->Handle) {\r
- DEBUG ((EFI_D_INFO, "PciHostBridge: SubmitResources for %s\n", RootBridge->DevicePathStr));\r
+ DEBUG ((DEBUG_INFO, "PciHostBridge: SubmitResources for %s\n", RootBridge->DevicePathStr));\r
//\r
// Check the resource descriptors.\r
// If the Configuration includes one or more invalid resource descriptors, all the resource\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
- DEBUG ((EFI_D_INFO, " %s: Granularity/SpecificFlag = %ld / %02x%s\n",\r
+ DEBUG ((DEBUG_INFO, " %s: Granularity/SpecificFlag = %ld / %02x%s\n",\r
mAcpiAddressSpaceTypeStr[Descriptor->ResType], Descriptor->AddrSpaceGranularity, Descriptor->SpecificFlag,\r
(Descriptor->SpecificFlag & EFI_ACPI_MEMORY_RESOURCE_SPECIFIC_FLAG_CACHEABLE_PREFETCHABLE) != 0 ? L" (Prefetchable)" : L""\r
));\r
- DEBUG ((EFI_D_INFO, " Length/Alignment = 0x%lx / 0x%lx\n", Descriptor->AddrLen, Descriptor->AddrRangeMax));\r
+ DEBUG ((DEBUG_INFO, " Length/Alignment = 0x%lx / 0x%lx\n", Descriptor->AddrLen, Descriptor->AddrRangeMax));\r
switch (Descriptor->ResType) {\r
case ACPI_ADDRESS_SPACE_TYPE_MEM:\r
if (Descriptor->AddrSpaceGranularity != 32 && Descriptor->AddrSpaceGranularity != 64) {\r
\r
DevicePathStr = NULL;\r
\r
- DEBUG ((EFI_D_INFO, "RootBridge: "));\r
- DEBUG ((EFI_D_INFO, "%s\n", DevicePathStr = ConvertDevicePathToText (Bridge->DevicePath, FALSE, FALSE)));\r
- DEBUG ((EFI_D_INFO, " Support/Attr: %lx / %lx\n", Bridge->Supports, Bridge->Attributes));\r
- DEBUG ((EFI_D_INFO, " DmaAbove4G: %s\n", Bridge->DmaAbove4G ? L"Yes" : L"No"));\r
- DEBUG ((EFI_D_INFO, "NoExtConfSpace: %s\n", Bridge->NoExtendedConfigSpace ? L"Yes" : L"No"));\r
- DEBUG ((EFI_D_INFO, " AllocAttr: %lx (%s%s)\n", Bridge->AllocationAttributes,\r
+ DEBUG ((DEBUG_INFO, "RootBridge: "));\r
+ DEBUG ((DEBUG_INFO, "%s\n", DevicePathStr = ConvertDevicePathToText (Bridge->DevicePath, FALSE, FALSE)));\r
+ DEBUG ((DEBUG_INFO, " Support/Attr: %lx / %lx\n", Bridge->Supports, Bridge->Attributes));\r
+ DEBUG ((DEBUG_INFO, " DmaAbove4G: %s\n", Bridge->DmaAbove4G ? L"Yes" : L"No"));\r
+ DEBUG ((DEBUG_INFO, "NoExtConfSpace: %s\n", Bridge->NoExtendedConfigSpace ? L"Yes" : L"No"));\r
+ DEBUG ((DEBUG_INFO, " AllocAttr: %lx (%s%s)\n", Bridge->AllocationAttributes,\r
(Bridge->AllocationAttributes & EFI_PCI_HOST_BRIDGE_COMBINE_MEM_PMEM) != 0 ? L"CombineMemPMem " : L"",\r
(Bridge->AllocationAttributes & EFI_PCI_HOST_BRIDGE_MEM64_DECODE) != 0 ? L"Mem64Decode" : L""\r
));\r
DEBUG ((\r
- EFI_D_INFO, " Bus: %lx - %lx Translation=%lx\n",\r
+ DEBUG_INFO, " Bus: %lx - %lx Translation=%lx\n",\r
Bridge->Bus.Base, Bridge->Bus.Limit, Bridge->Bus.Translation\r
));\r
//\r
Node = NextDevicePathNode (Node);\r
} while (!IsDevicePathEnd (Node));\r
Status = CreateSerialDevice (Controller, Uart, ParentDevicePath, FALSE, Acpi->UID, ParentIo, NULL, NULL);\r
- DEBUG ((EFI_D_INFO, "PciSioSerial: Create SIO child serial device - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "PciSioSerial: Create SIO child serial device - %r\n", Status));\r
}\r
} else {\r
Status = ParentIo.PciIo->Pci.Read (ParentIo.PciIo, EfiPciIoWidthUint8, 0, sizeof (Pci), &Pci);\r
}\r
\r
Status = CreateSerialDevice (Controller, Uart, ParentDevicePath, FALSE, 0, ParentIo, PciSerialParameter, PciDeviceInfo);\r
- DEBUG ((EFI_D_INFO, "PciSioSerial: Create PCI child serial device (single) - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "PciSioSerial: Create PCI child serial device (single) - %r\n", Status));\r
if (!EFI_ERROR (Status)) {\r
PciDeviceInfo->ChildCount++;\r
}\r
//\r
Status = CreateSerialDevice (Controller, Uart, ParentDevicePath, TRUE, PciSerialCount, ParentIo, PciSerialParameter, PciDeviceInfo);\r
PciSerialCount++;\r
- DEBUG ((EFI_D_INFO, "PciSioSerial: Create PCI child serial device (multiple) - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "PciSioSerial: Create PCI child serial device (multiple) - %r\n", Status));\r
if (!EFI_ERROR (Status)) {\r
PciDeviceInfo->ChildCount++;\r
}\r
}\r
\r
Percent = DivU64x32 (MultU64x32 (BaudRate, 100), ComputedBaudRate);\r
- DEBUG ((EFI_D_INFO, "ClockRate = %d\n", ClockRate));\r
- DEBUG ((EFI_D_INFO, "Divisor = %ld\n", ComputedDivisor));\r
- DEBUG ((EFI_D_INFO, "BaudRate/Actual (%ld/%d) = %d%%\n", BaudRate, ComputedBaudRate, Percent));\r
+ DEBUG ((DEBUG_INFO, "ClockRate = %d\n", ClockRate));\r
+ DEBUG ((DEBUG_INFO, "Divisor = %ld\n", ComputedDivisor));\r
+ DEBUG ((DEBUG_INFO, "BaudRate/Actual (%ld/%d) = %d%%\n", BaudRate, ComputedBaudRate, Percent));\r
\r
//\r
// If the requested BaudRate is not supported:\r
return FALSE;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "ClockRate = %d\n", ClockRate));\r
- DEBUG ((EFI_D_INFO, "Divisor = %ld\n", ComputedDivisor));\r
- DEBUG ((EFI_D_INFO, "BaudRate/Actual (%ld/%d) = %d%%\n", BaudRate, ComputedBaudRate, Percent));\r
+ DEBUG ((DEBUG_INFO, "ClockRate = %d\n", ClockRate));\r
+ DEBUG ((DEBUG_INFO, "Divisor = %ld\n", ComputedDivisor));\r
+ DEBUG ((DEBUG_INFO, "BaudRate/Actual (%ld/%d) = %d%%\n", BaudRate, ComputedBaudRate, Percent));\r
\r
if (ActualBaudRate != NULL) {\r
*ActualBaudRate = ComputedBaudRate;\r
if ((IdentifyData->AtaData.field_validity & 0x02) == 0x02) {\r
\r
AdvancedPioMode = IdentifyData->AtaData.advanced_pio_modes;\r
- DEBUG ((EFI_D_INFO, "CalculateBestPioMode: AdvancedPioMode = %x\n", AdvancedPioMode));\r
+ DEBUG ((DEBUG_INFO, "CalculateBestPioMode: AdvancedPioMode = %x\n", AdvancedPioMode));\r
\r
for (Index = 0; Index < 8; Index++) {\r
if ((AdvancedPioMode & 0x01) != 0) {\r
}\r
\r
DeviceUDmaMode = IdentifyData->AtaData.ultra_dma_mode;\r
- DEBUG ((EFI_D_INFO, "CalculateBestUdmaMode: DeviceUDmaMode = %x\n", DeviceUDmaMode));\r
+ DEBUG ((DEBUG_INFO, "CalculateBestUdmaMode: DeviceUDmaMode = %x\n", DeviceUDmaMode));\r
DeviceUDmaMode &= 0x3f;\r
TempMode = 0; // initialize it to UDMA-0\r
\r
UINT64 Supports;\r
UINT8 MaxPortNumber;\r
\r
- DEBUG ((EFI_D_INFO, "SataControllerStart start\n"));\r
+ DEBUG ((DEBUG_INFO, "SataControllerStart start\n"));\r
\r
Private = NULL;\r
\r
EFI_OPEN_PROTOCOL_BY_DRIVER\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SataControllerStart error. return status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SataControllerStart error. return status = %r\n", Status));\r
return Status;\r
}\r
\r
}\r
\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"Original PCI Attributes = 0x%llx\n",\r
Private->OriginalPciAttributes\r
));\r
goto Done;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Supported PCI Attributes = 0x%llx\n", Supports));\r
+ DEBUG ((DEBUG_INFO, "Supported PCI Attributes = 0x%llx\n", Supports));\r
\r
Supports &= (UINT64)EFI_PCI_DEVICE_ENABLE;\r
Status = PciIo->Attributes (\r
goto Done;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Enabled PCI Attributes = 0x%llx\n", Supports));\r
+ DEBUG ((DEBUG_INFO, "Enabled PCI Attributes = 0x%llx\n", Supports));\r
Private->PciAttributesChanged = TRUE;\r
\r
Status = PciIo->Pci.Read (\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "SataControllerStart end with %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "SataControllerStart end with %r\n", Status));\r
\r
return Status;\r
}\r
} else {\r
(*SupportedModes)->PioMode.Valid = FALSE;\r
}\r
- DEBUG ((EFI_D_INFO, "IdeInitCalculateMode: PioMode = %x\n", (*SupportedModes)->PioMode.Mode));\r
+ DEBUG ((DEBUG_INFO, "IdeInitCalculateMode: PioMode = %x\n", (*SupportedModes)->PioMode.Mode));\r
\r
Status = CalculateBestUdmaMode (\r
IdentifyData,\r
} else {\r
(*SupportedModes)->UdmaMode.Valid = FALSE;\r
}\r
- DEBUG ((EFI_D_INFO, "IdeInitCalculateMode: UdmaMode = %x\n", (*SupportedModes)->UdmaMode.Mode));\r
+ DEBUG ((DEBUG_INFO, "IdeInitCalculateMode: UdmaMode = %x\n", (*SupportedModes)->UdmaMode.Mode));\r
\r
//\r
// The modes other than PIO and UDMA are not supported\r
{\r
return EFI_SUCCESS;\r
}\r
-\r
\r
Private = (SD_MMC_HC_PEI_PRIVATE_DATA *) AllocateZeroPool (sizeof (SD_MMC_HC_PEI_PRIVATE_DATA));\r
if (Private == NULL) {\r
- DEBUG ((EFI_D_ERROR, "Failed to allocate memory for SD_MMC_HC_PEI_PRIVATE_DATA! \n"));\r
+ DEBUG ((DEBUG_ERROR, "Failed to allocate memory for SD_MMC_HC_PEI_PRIVATE_DATA! \n"));\r
return EFI_OUT_OF_RESOURCES;\r
}\r
\r
\r
Private = (UFS_HC_PEI_PRIVATE_DATA *) AllocateZeroPool (sizeof (UFS_HC_PEI_PRIVATE_DATA));\r
if (Private == NULL) {\r
- DEBUG ((EFI_D_ERROR, "Failed to allocate memory for UFS_HC_PEI_PRIVATE_DATA! \n"));\r
+ DEBUG ((DEBUG_ERROR, "Failed to allocate memory for UFS_HC_PEI_PRIVATE_DATA! \n"));\r
return EFI_OUT_OF_RESOURCES;\r
}\r
\r
\r
Uhc->RootPorts = *PortNumber;\r
\r
- DEBUG ((EFI_D_INFO, "Uhci2GetCapability: %d ports\n", (UINT32)Uhc->RootPorts));\r
+ DEBUG ((DEBUG_INFO, "Uhci2GetCapability: %d ports\n", (UINT32)Uhc->RootPorts));\r
return EFI_SUCCESS;\r
}\r
\r
}\r
\r
if ((PortSC & USBPORTSC_SUSP) != 0) {\r
- DEBUG ((EFI_D_INFO, "Uhci2GetRootHubPortStatus: port %d is suspended\n", PortNumber));\r
+ DEBUG ((DEBUG_INFO, "Uhci2GetRootHubPortStatus: port %d is suspended\n", PortNumber));\r
PortStatus->PortStatus |= USB_PORT_STAT_SUSPEND;\r
}\r
\r
\r
return EFI_SUCCESS;\r
}\r
-\r
IN UHCI_QH_SW *QhSw\r
)\r
{\r
- DEBUG ((EFI_D_VERBOSE, "&QhSw @ 0x%p\n", QhSw));\r
- DEBUG ((EFI_D_VERBOSE, "QhSw.NextQh - 0x%p\n", QhSw->NextQh));\r
- DEBUG ((EFI_D_VERBOSE, "QhSw.TDs - 0x%p\n", QhSw->TDs));\r
- DEBUG ((EFI_D_VERBOSE, "QhSw.QhHw:\n"));\r
- DEBUG ((EFI_D_VERBOSE, " Horizon Link - %x\n", QhSw->QhHw.HorizonLink));\r
- DEBUG ((EFI_D_VERBOSE, " Vertical Link - %x\n\n", QhSw->QhHw.VerticalLink));\r
+ DEBUG ((DEBUG_VERBOSE, "&QhSw @ 0x%p\n", QhSw));\r
+ DEBUG ((DEBUG_VERBOSE, "QhSw.NextQh - 0x%p\n", QhSw->NextQh));\r
+ DEBUG ((DEBUG_VERBOSE, "QhSw.TDs - 0x%p\n", QhSw->TDs));\r
+ DEBUG ((DEBUG_VERBOSE, "QhSw.QhHw:\n"));\r
+ DEBUG ((DEBUG_VERBOSE, " Horizon Link - %x\n", QhSw->QhHw.HorizonLink));\r
+ DEBUG ((DEBUG_VERBOSE, " Vertical Link - %x\n\n", QhSw->QhHw.VerticalLink));\r
}\r
\r
\r
CurTdSw = TdSw;\r
\r
while (CurTdSw != NULL) {\r
- DEBUG ((EFI_D_VERBOSE, "TdSw @ 0x%p\n", CurTdSw));\r
- DEBUG ((EFI_D_VERBOSE, "TdSw.NextTd - 0x%p\n", CurTdSw->NextTd));\r
- DEBUG ((EFI_D_VERBOSE, "TdSw.DataLen - %d\n", CurTdSw->DataLen));\r
- DEBUG ((EFI_D_VERBOSE, "TdSw.Data - 0x%p\n", CurTdSw->Data));\r
- DEBUG ((EFI_D_VERBOSE, "TdHw:\n"));\r
- DEBUG ((EFI_D_VERBOSE, " NextLink - 0x%x\n", CurTdSw->TdHw.NextLink));\r
- DEBUG ((EFI_D_VERBOSE, " ActualLen - %d\n", CurTdSw->TdHw.ActualLen));\r
- DEBUG ((EFI_D_VERBOSE, " Status - 0x%x\n", CurTdSw->TdHw.Status));\r
- DEBUG ((EFI_D_VERBOSE, " IOC - %d\n", CurTdSw->TdHw.IntOnCpl));\r
- DEBUG ((EFI_D_VERBOSE, " IsIsoCh - %d\n", CurTdSw->TdHw.IsIsoch));\r
- DEBUG ((EFI_D_VERBOSE, " LowSpeed - %d\n", CurTdSw->TdHw.LowSpeed));\r
- DEBUG ((EFI_D_VERBOSE, " ErrorCount - %d\n", CurTdSw->TdHw.ErrorCount));\r
- DEBUG ((EFI_D_VERBOSE, " ShortPacket - %d\n", CurTdSw->TdHw.ShortPacket));\r
- DEBUG ((EFI_D_VERBOSE, " PidCode - 0x%x\n", CurTdSw->TdHw.PidCode));\r
- DEBUG ((EFI_D_VERBOSE, " DevAddr - %d\n", CurTdSw->TdHw.DeviceAddr));\r
- DEBUG ((EFI_D_VERBOSE, " EndPoint - %d\n", CurTdSw->TdHw.EndPoint));\r
- DEBUG ((EFI_D_VERBOSE, " DataToggle - %d\n", CurTdSw->TdHw.DataToggle));\r
- DEBUG ((EFI_D_VERBOSE, " MaxPacketLen - %d\n", CurTdSw->TdHw.MaxPacketLen));\r
- DEBUG ((EFI_D_VERBOSE, " DataBuffer - 0x%x\n\n",CurTdSw->TdHw.DataBuffer));\r
+ DEBUG ((DEBUG_VERBOSE, "TdSw @ 0x%p\n", CurTdSw));\r
+ DEBUG ((DEBUG_VERBOSE, "TdSw.NextTd - 0x%p\n", CurTdSw->NextTd));\r
+ DEBUG ((DEBUG_VERBOSE, "TdSw.DataLen - %d\n", CurTdSw->DataLen));\r
+ DEBUG ((DEBUG_VERBOSE, "TdSw.Data - 0x%p\n", CurTdSw->Data));\r
+ DEBUG ((DEBUG_VERBOSE, "TdHw:\n"));\r
+ DEBUG ((DEBUG_VERBOSE, " NextLink - 0x%x\n", CurTdSw->TdHw.NextLink));\r
+ DEBUG ((DEBUG_VERBOSE, " ActualLen - %d\n", CurTdSw->TdHw.ActualLen));\r
+ DEBUG ((DEBUG_VERBOSE, " Status - 0x%x\n", CurTdSw->TdHw.Status));\r
+ DEBUG ((DEBUG_VERBOSE, " IOC - %d\n", CurTdSw->TdHw.IntOnCpl));\r
+ DEBUG ((DEBUG_VERBOSE, " IsIsoCh - %d\n", CurTdSw->TdHw.IsIsoch));\r
+ DEBUG ((DEBUG_VERBOSE, " LowSpeed - %d\n", CurTdSw->TdHw.LowSpeed));\r
+ DEBUG ((DEBUG_VERBOSE, " ErrorCount - %d\n", CurTdSw->TdHw.ErrorCount));\r
+ DEBUG ((DEBUG_VERBOSE, " ShortPacket - %d\n", CurTdSw->TdHw.ShortPacket));\r
+ DEBUG ((DEBUG_VERBOSE, " PidCode - 0x%x\n", CurTdSw->TdHw.PidCode));\r
+ DEBUG ((DEBUG_VERBOSE, " DevAddr - %d\n", CurTdSw->TdHw.DeviceAddr));\r
+ DEBUG ((DEBUG_VERBOSE, " EndPoint - %d\n", CurTdSw->TdHw.EndPoint));\r
+ DEBUG ((DEBUG_VERBOSE, " DataToggle - %d\n", CurTdSw->TdHw.DataToggle));\r
+ DEBUG ((DEBUG_VERBOSE, " MaxPacketLen - %d\n", CurTdSw->TdHw.MaxPacketLen));\r
+ DEBUG ((DEBUG_VERBOSE, " DataBuffer - 0x%x\n\n",CurTdSw->TdHw.DataBuffer));\r
\r
CurTdSw = CurTdSw->NextTd;\r
}\r
}\r
-\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UhciReadReg: PciIo Io.Read error: %r at offset %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "UhciReadReg: PciIo Io.Read error: %r at offset %d\n", Status, Offset));\r
\r
Data = 0xFFFF;\r
}\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UhciWriteReg: PciIo Io.Write error: %r at offset %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "UhciWriteReg: PciIo Io.Write error: %r at offset %d\n", Status, Offset));\r
}\r
}\r
\r
// is a temporary error status.\r
//\r
if (!UhciIsHcWorking (Uhc->PciIo)) {\r
- DEBUG ((EFI_D_ERROR, "UhciAckAllInterrupt: re-enable the UHCI from system error\n"));\r
+ DEBUG ((DEBUG_ERROR, "UhciAckAllInterrupt: re-enable the UHCI from system error\n"));\r
Uhc->Usb2Hc.SetState (&Uhc->Usb2Hc, EfiUsbHcStateOperational);\r
}\r
}\r
UsbSts = UhciReadReg (PciIo, USBSTS_OFFSET);\r
\r
if ((UsbSts & (USBSTS_HCPE | USBSTS_HSE | USBSTS_HCH)) != 0) {\r
- DEBUG ((EFI_D_ERROR, "UhciIsHcWorking: current USB state is %x\n", UsbSts));\r
+ DEBUG ((DEBUG_ERROR, "UhciIsHcWorking: current USB state is %x\n", UsbSts));\r
return FALSE;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UhciSetFrameListBaseAddr: PciIo Io.Write error: %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UhciSetFrameListBaseAddr: PciIo Io.Write error: %r\n", Status));\r
}\r
}\r
\r
}\r
\r
if (!Finished) {\r
- DEBUG ((EFI_D_ERROR, "UhciExecuteTransfer: execution not finished for %dms\n", (UINT32)TimeOut));\r
+ DEBUG ((DEBUG_ERROR, "UhciExecuteTransfer: execution not finished for %dms\n", (UINT32)TimeOut));\r
UhciDumpQh (Qh);\r
UhciDumpTds (Td);\r
\r
Status = EFI_TIMEOUT;\r
\r
} else if (QhResult->Result != EFI_USB_NOERROR) {\r
- DEBUG ((EFI_D_ERROR, "UhciExecuteTransfer: execution failed with result %x\n", QhResult->Result));\r
+ DEBUG ((DEBUG_ERROR, "UhciExecuteTransfer: execution failed with result %x\n", QhResult->Result));\r
UhciDumpQh (Qh);\r
UhciDumpTds (Td);\r
\r
NewBlock = UsbHcAllocMemBlock (Pool, Pages);\r
\r
if (NewBlock == NULL) {\r
- DEBUG ((EFI_D_INFO, "UsbHcAllocateMem: failed to allocate block\n"));\r
+ DEBUG ((DEBUG_INFO, "UsbHcAllocateMem: failed to allocate block\n"));\r
return NULL;\r
}\r
\r
NewBlock = UsbHcAllocMemBlock (Pool, Pages);\r
\r
if (NewBlock == NULL) {\r
- DEBUG ((EFI_D_ERROR, "UsbHcAllocateMem: failed to allocate block\n"));\r
+ DEBUG ((DEBUG_ERROR, "UsbHcAllocateMem: failed to allocate block\n"));\r
return NULL;\r
}\r
\r
*MaxSpeed = EFI_USB_SPEED_SUPER;\r
*PortNumber = (UINT8) (Xhc->HcSParams1.Data.MaxPorts);\r
*Is64BitCapable = (UINT8) Xhc->Support64BitDma;\r
- DEBUG ((EFI_D_INFO, "XhcGetCapability: %d ports, 64 bit %d\n", *PortNumber, *Is64BitCapable));\r
+ DEBUG ((DEBUG_INFO, "XhcGetCapability: %d ports, 64 bit %d\n", *PortNumber, *Is64BitCapable));\r
\r
gBS->RestoreTPL (OldTpl);\r
\r
}\r
\r
ON_EXIT:\r
- DEBUG ((EFI_D_INFO, "XhcReset: status %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcReset: status %r\n", Status));\r
gBS->RestoreTPL (OldTpl);\r
\r
return Status;\r
*State = EfiUsbHcStateOperational;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "XhcGetState: current state %d\n", *State));\r
+ DEBUG ((DEBUG_INFO, "XhcGetState: current state %d\n", *State));\r
gBS->RestoreTPL (OldTpl);\r
\r
return EFI_SUCCESS;\r
Status = EFI_INVALID_PARAMETER;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "XhcSetState: status %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcSetState: status %r\n", Status));\r
gBS->RestoreTPL (OldTpl);\r
\r
return Status;\r
break;\r
\r
case EfiUsbPortReset:\r
- DEBUG ((EFI_D_INFO, "XhcUsbPortReset!\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcUsbPortReset!\n"));\r
//\r
// Make sure Host Controller not halt before reset it\r
//\r
Status = XhcRunHC (Xhc, XHC_GENERIC_TIMEOUT);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "XhcSetRootHubPortFeature :failed to start HC - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcSetRootHubPortFeature :failed to start HC - %r\n", Status));\r
break;\r
}\r
}\r
}\r
\r
ON_EXIT:\r
- DEBUG ((EFI_D_INFO, "XhcSetRootHubPortFeature: status %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcSetRootHubPortFeature: status %r\n", Status));\r
gBS->RestoreTPL (OldTpl);\r
\r
return Status;\r
}\r
\r
ON_EXIT:\r
- DEBUG ((EFI_D_INFO, "XhcClearRootHubPortFeature: status %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcClearRootHubPortFeature: status %r\n", Status));\r
gBS->RestoreTPL (OldTpl);\r
\r
return Status;\r
Len = 0;\r
\r
if (XhcIsHalt (Xhc) || XhcIsSysError (Xhc)) {\r
- DEBUG ((EFI_D_ERROR, "XhcControlTransfer: HC halted at entrance\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcControlTransfer: HC halted at entrance\n"));\r
goto ON_EXIT;\r
}\r
\r
// Don't support multi-TT feature for super speed hub now.\r
//\r
MTT = 0;\r
- DEBUG ((EFI_D_ERROR, "XHCI: Don't support multi-TT feature for Hub now. (force to disable MTT)\n"));\r
+ DEBUG ((DEBUG_ERROR, "XHCI: Don't support multi-TT feature for Hub now. (force to disable MTT)\n"));\r
} else {\r
MTT = 0;\r
}\r
\r
ON_EXIT:\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcControlTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
+ DEBUG ((DEBUG_ERROR, "XhcControlTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
}\r
\r
gBS->RestoreTPL (OldTpl);\r
Status = EFI_DEVICE_ERROR;\r
\r
if (XhcIsHalt (Xhc) || XhcIsSysError (Xhc)) {\r
- DEBUG ((EFI_D_ERROR, "XhcBulkTransfer: HC is halted\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcBulkTransfer: HC is halted\n"));\r
goto ON_EXIT;\r
}\r
\r
\r
ON_EXIT:\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcBulkTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
+ DEBUG ((DEBUG_ERROR, "XhcBulkTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
}\r
gBS->RestoreTPL (OldTpl);\r
\r
}\r
\r
Status = XhciDelAsyncIntTransfer (Xhc, DeviceAddress, EndPointAddress);\r
- DEBUG ((EFI_D_INFO, "XhcAsyncInterruptTransfer: remove old transfer for addr %d, Status = %r\n", DeviceAddress, Status));\r
+ DEBUG ((DEBUG_INFO, "XhcAsyncInterruptTransfer: remove old transfer for addr %d, Status = %r\n", DeviceAddress, Status));\r
goto ON_EXIT;\r
}\r
\r
Status = EFI_SUCCESS;\r
\r
if (XhcIsHalt (Xhc) || XhcIsSysError (Xhc)) {\r
- DEBUG ((EFI_D_ERROR, "XhcAsyncInterruptTransfer: HC is halt\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcAsyncInterruptTransfer: HC is halt\n"));\r
Status = EFI_DEVICE_ERROR;\r
goto ON_EXIT;\r
}\r
Status = EFI_DEVICE_ERROR;\r
\r
if (XhcIsHalt (Xhc) || XhcIsSysError (Xhc)) {\r
- DEBUG ((EFI_D_ERROR, "EhcSyncInterruptTransfer: HC is halt\n"));\r
+ DEBUG ((DEBUG_ERROR, "EhcSyncInterruptTransfer: HC is halt\n"));\r
goto ON_EXIT;\r
}\r
\r
\r
ON_EXIT:\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcSyncInterruptTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
+ DEBUG ((DEBUG_ERROR, "XhcSyncInterruptTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
}\r
gBS->RestoreTPL (OldTpl);\r
\r
Xhc->UsbLegSupOffset = XhcGetCapabilityAddr (Xhc, XHC_CAP_USB_LEGACY);\r
Xhc->DebugCapSupOffset = XhcGetCapabilityAddr (Xhc, XHC_CAP_USB_DEBUG);\r
\r
- DEBUG ((EFI_D_INFO, "XhcCreateUsb3Hc: Capability length 0x%x\n", Xhc->CapLength));\r
- DEBUG ((EFI_D_INFO, "XhcCreateUsb3Hc: HcSParams1 0x%x\n", Xhc->HcSParams1));\r
- DEBUG ((EFI_D_INFO, "XhcCreateUsb3Hc: HcSParams2 0x%x\n", Xhc->HcSParams2));\r
- DEBUG ((EFI_D_INFO, "XhcCreateUsb3Hc: HcCParams 0x%x\n", Xhc->HcCParams));\r
- DEBUG ((EFI_D_INFO, "XhcCreateUsb3Hc: DBOff 0x%x\n", Xhc->DBOff));\r
- DEBUG ((EFI_D_INFO, "XhcCreateUsb3Hc: RTSOff 0x%x\n", Xhc->RTSOff));\r
- DEBUG ((EFI_D_INFO, "XhcCreateUsb3Hc: UsbLegSupOffset 0x%x\n", Xhc->UsbLegSupOffset));\r
- DEBUG ((EFI_D_INFO, "XhcCreateUsb3Hc: DebugCapSupOffset 0x%x\n", Xhc->DebugCapSupOffset));\r
+ DEBUG ((DEBUG_INFO, "XhcCreateUsb3Hc: Capability length 0x%x\n", Xhc->CapLength));\r
+ DEBUG ((DEBUG_INFO, "XhcCreateUsb3Hc: HcSParams1 0x%x\n", Xhc->HcSParams1));\r
+ DEBUG ((DEBUG_INFO, "XhcCreateUsb3Hc: HcSParams2 0x%x\n", Xhc->HcSParams2));\r
+ DEBUG ((DEBUG_INFO, "XhcCreateUsb3Hc: HcCParams 0x%x\n", Xhc->HcCParams));\r
+ DEBUG ((DEBUG_INFO, "XhcCreateUsb3Hc: DBOff 0x%x\n", Xhc->DBOff));\r
+ DEBUG ((DEBUG_INFO, "XhcCreateUsb3Hc: RTSOff 0x%x\n", Xhc->RTSOff));\r
+ DEBUG ((DEBUG_INFO, "XhcCreateUsb3Hc: UsbLegSupOffset 0x%x\n", Xhc->UsbLegSupOffset));\r
+ DEBUG ((DEBUG_INFO, "XhcCreateUsb3Hc: DebugCapSupOffset 0x%x\n", Xhc->DebugCapSupOffset));\r
\r
//\r
// Create AsyncRequest Polling Timer\r
}\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcDriverBindingStart: failed to enable controller\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcDriverBindingStart: failed to enable controller\n"));\r
goto CLOSE_PCIIO;\r
}\r
\r
Xhc = XhcCreateUsbHc (PciIo, HcDevicePath, OriginalPciAttributes);\r
\r
if (Xhc == NULL) {\r
- DEBUG ((EFI_D_ERROR, "XhcDriverBindingStart: failed to create USB2_HC\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcDriverBindingStart: failed to create USB2_HC\n"));\r
return EFI_OUT_OF_RESOURCES;\r
}\r
\r
if (!EFI_ERROR (Status)) {\r
Xhc->Support64BitDma = TRUE;\r
} else {\r
- DEBUG ((EFI_D_WARN,\r
+ DEBUG ((DEBUG_WARN,\r
"%a: failed to enable 64-bit DMA on 64-bit capable controller @ %p (%r)\n",\r
__FUNCTION__, Controller, Status));\r
}\r
//\r
Status = gBS->SetTimer (Xhc->PollTimer, TimerPeriodic, XHC_ASYNC_TIMER_INTERVAL);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcDriverBindingStart: failed to start async interrupt monitor\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcDriverBindingStart: failed to start async interrupt monitor\n"));\r
XhcHaltHC (Xhc, XHC_GENERIC_TIMEOUT);\r
goto FREE_POOL;\r
}\r
&Xhc->Usb2Hc\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcDriverBindingStart: failed to install USB2_HC Protocol\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcDriverBindingStart: failed to install USB2_HC Protocol\n"));\r
goto FREE_POOL;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "XhcDriverBindingStart: XHCI started for controller @ %x\n", Controller));\r
+ DEBUG ((DEBUG_INFO, "XhcDriverBindingStart: XHCI started for controller @ %x\n", Controller));\r
return EFI_SUCCESS;\r
\r
FREE_POOL:\r
\r
return EFI_SUCCESS;\r
}\r
-\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcReadCapReg: Pci Io read error - %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "XhcReadCapReg: Pci Io read error - %r at %d\n", Status, Offset));\r
Data = 0xFF;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcReadCapReg: Pci Io read error - %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "XhcReadCapReg: Pci Io read error - %r at %d\n", Status, Offset));\r
Data = 0xFFFFFFFF;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcReadOpReg: Pci Io Read error - %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "XhcReadOpReg: Pci Io Read error - %r at %d\n", Status, Offset));\r
Data = 0xFFFFFFFF;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcWriteOpReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "XhcWriteOpReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
}\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcWriteOpReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "XhcWriteOpReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
}\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcReadRuntimeReg: Pci Io Read error - %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "XhcReadRuntimeReg: Pci Io Read error - %r at %d\n", Status, Offset));\r
Data = 0xFFFFFFFF;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcWriteRuntimeReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "XhcWriteRuntimeReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
}\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcReadExtCapReg: Pci Io Read error - %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "XhcReadExtCapReg: Pci Io Read error - %r at %d\n", Status, Offset));\r
Data = 0xFFFFFFFF;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcWriteExtCapReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
+ DEBUG ((DEBUG_ERROR, "XhcWriteExtCapReg: Pci Io Write error: %r at %d\n", Status, Offset));\r
}\r
}\r
\r
return;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "XhcSetBiosOwnership: called to set BIOS ownership\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcSetBiosOwnership: called to set BIOS ownership\n"));\r
\r
Buffer = XhcReadExtCapReg (Xhc, Xhc->UsbLegSupOffset);\r
Buffer = ((Buffer & (~USBLEGSP_OS_SEMAPHORE)) | USBLEGSP_BIOS_SEMAPHORE);\r
return;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "XhcClearBiosOwnership: called to clear BIOS ownership\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcClearBiosOwnership: called to clear BIOS ownership\n"));\r
\r
Buffer = XhcReadExtCapReg (Xhc, Xhc->UsbLegSupOffset);\r
Buffer = ((Buffer & (~USBLEGSP_BIOS_SEMAPHORE)) | USBLEGSP_OS_SEMAPHORE);\r
\r
Status = EFI_SUCCESS;\r
\r
- DEBUG ((EFI_D_INFO, "XhcResetHC!\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcResetHC!\n"));\r
//\r
// Host can only be reset when it is halt. If not so, halt it\r
//\r
Status = XhcWaitOpRegBit (Xhc, XHC_USBSTS_OFFSET, XHC_USBSTS_HALT, FALSE, Timeout);\r
return Status;\r
}\r
-\r
Status = EFI_DEVICE_ERROR;\r
\r
if (XhcIsHalt (Xhc) || XhcIsSysError (Xhc)) {\r
- DEBUG ((EFI_D_ERROR, "XhcCmdTransfer: HC is halted\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcCmdTransfer: HC is halted\n"));\r
goto ON_EXIT;\r
}\r
\r
Urb = XhcCreateCmdTrb (Xhc, CmdTrb);\r
\r
if (Urb == NULL) {\r
- DEBUG ((EFI_D_ERROR, "XhcCmdTransfer: failed to create URB\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcCmdTransfer: failed to create URB\n"));\r
Status = EFI_OUT_OF_RESOURCES;\r
goto ON_EXIT;\r
}\r
Status = XhcCreateTransferTrb (Xhc, Urb);\r
ASSERT_EFI_ERROR (Status);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcCreateUrb: XhcCreateTransferTrb Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcCreateUrb: XhcCreateTransferTrb Failed, Status = %r\n", Status));\r
FreePool (Urb);\r
Urb = NULL;\r
}\r
Status = Xhc->PciIo->Map (Xhc->PciIo, MapOp, Urb->Data, &Len, &PhyAddr, &Map);\r
\r
if (EFI_ERROR (Status) || (Len != Urb->DataLen)) {\r
- DEBUG ((EFI_D_ERROR, "XhcCreateTransferTrb: Fail to map Urb->Data.\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcCreateTransferTrb: Fail to map Urb->Data.\n"));\r
return EFI_OUT_OF_RESOURCES;\r
}\r
\r
break;\r
\r
default:\r
- DEBUG ((EFI_D_INFO, "Not supported EPType 0x%x!\n",EPType));\r
+ DEBUG ((DEBUG_INFO, "Not supported EPType 0x%x!\n",EPType));\r
ASSERT (FALSE);\r
break;\r
}\r
XhcWriteOpReg (Xhc, XHC_DCBAAP_OFFSET, XHC_LOW_32BIT(DcbaaPhy));\r
XhcWriteOpReg (Xhc, XHC_DCBAAP_OFFSET + 4, XHC_HIGH_32BIT (DcbaaPhy));\r
\r
- DEBUG ((EFI_D_INFO, "XhcInitSched:DCBAA=0x%x\n", (UINT64)(UINTN)Xhc->DCBAA));\r
+ DEBUG ((DEBUG_INFO, "XhcInitSched:DCBAA=0x%x\n", (UINT64)(UINTN)Xhc->DCBAA));\r
\r
//\r
// Define the Command Ring Dequeue Pointer by programming the Command Ring Control Register\r
Dci = XhcEndpointToDci (Urb->Ep.EpAddr, (UINT8)(Urb->Ep.Direction));\r
ASSERT (Dci < 32);\r
\r
- DEBUG ((EFI_D_INFO, "Recovery Halted Slot = %x,Dci = %x\n", SlotId, Dci));\r
+ DEBUG ((DEBUG_INFO, "Recovery Halted Slot = %x,Dci = %x\n", SlotId, Dci));\r
\r
//\r
// 1) Send Reset endpoint command to transit from halt to stop state\r
//\r
Status = XhcResetEndpoint(Xhc, SlotId, Dci);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcRecoverHaltedEndpoint: Reset Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcRecoverHaltedEndpoint: Reset Endpoint Failed, Status = %r\n", Status));\r
goto Done;\r
}\r
\r
//\r
Status = XhcSetTrDequeuePointer(Xhc, SlotId, Dci, Urb);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcRecoverHaltedEndpoint: Set Transfer Ring Dequeue Pointer Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcRecoverHaltedEndpoint: Set Transfer Ring Dequeue Pointer Failed, Status = %r\n", Status));\r
goto Done;\r
}\r
\r
Dci = XhcEndpointToDci (Urb->Ep.EpAddr, (UINT8)(Urb->Ep.Direction));\r
ASSERT (Dci < 32);\r
\r
- DEBUG ((EFI_D_INFO, "Stop Slot = %x,Dci = %x\n", SlotId, Dci));\r
+ DEBUG ((DEBUG_INFO, "Stop Slot = %x,Dci = %x\n", SlotId, Dci));\r
\r
//\r
// 1) Send Stop endpoint command to stop xHC from executing of the TDs on the endpoint\r
//\r
Status = XhcStopEndpoint(Xhc, SlotId, Dci, Urb);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcDequeueTrbFromEndpoint: Stop Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcDequeueTrbFromEndpoint: Stop Endpoint Failed, Status = %r\n", Status));\r
goto Done;\r
}\r
\r
case TRB_COMPLETION_STALL_ERROR:\r
CheckedUrb->Result |= EFI_USB_ERR_STALL;\r
CheckedUrb->Finished = TRUE;\r
- DEBUG ((EFI_D_ERROR, "XhcCheckUrbResult: STALL_ERROR! Completecode = %x\n",EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "XhcCheckUrbResult: STALL_ERROR! Completecode = %x\n",EvtTrb->Completecode));\r
goto EXIT;\r
\r
case TRB_COMPLETION_BABBLE_ERROR:\r
CheckedUrb->Result |= EFI_USB_ERR_BABBLE;\r
CheckedUrb->Finished = TRUE;\r
- DEBUG ((EFI_D_ERROR, "XhcCheckUrbResult: BABBLE_ERROR! Completecode = %x\n",EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "XhcCheckUrbResult: BABBLE_ERROR! Completecode = %x\n",EvtTrb->Completecode));\r
goto EXIT;\r
\r
case TRB_COMPLETION_DATA_BUFFER_ERROR:\r
CheckedUrb->Result |= EFI_USB_ERR_BUFFER;\r
CheckedUrb->Finished = TRUE;\r
- DEBUG ((EFI_D_ERROR, "XhcCheckUrbResult: ERR_BUFFER! Completecode = %x\n",EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "XhcCheckUrbResult: ERR_BUFFER! Completecode = %x\n",EvtTrb->Completecode));\r
goto EXIT;\r
\r
case TRB_COMPLETION_USB_TRANSACTION_ERROR:\r
CheckedUrb->Result |= EFI_USB_ERR_TIMEOUT;\r
CheckedUrb->Finished = TRUE;\r
- DEBUG ((EFI_D_ERROR, "XhcCheckUrbResult: TRANSACTION_ERROR! Completecode = %x\n",EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "XhcCheckUrbResult: TRANSACTION_ERROR! Completecode = %x\n",EvtTrb->Completecode));\r
goto EXIT;\r
\r
case TRB_COMPLETION_STOPPED:\r
case TRB_COMPLETION_SHORT_PACKET:\r
case TRB_COMPLETION_SUCCESS:\r
if (EvtTrb->Completecode == TRB_COMPLETION_SHORT_PACKET) {\r
- DEBUG ((EFI_D_VERBOSE, "XhcCheckUrbResult: short packet happens!\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "XhcCheckUrbResult: short packet happens!\n"));\r
}\r
\r
TRBType = (UINT8) (TRBPtr->Type);\r
break;\r
\r
default:\r
- DEBUG ((EFI_D_ERROR, "Transfer Default Error Occur! Completecode = 0x%x!\n",EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "Transfer Default Error Occur! Completecode = 0x%x!\n",EvtTrb->Completecode));\r
CheckedUrb->Result |= EFI_USB_ERR_TIMEOUT;\r
CheckedUrb->Finished = TRUE;\r
goto EXIT;\r
//\r
Status = XhcDequeueTrbFromEndpoint (Xhc, Urb);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhciDelAsyncIntTransfer: XhcDequeueTrbFromEndpoint failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhciDelAsyncIntTransfer: XhcDequeueTrbFromEndpoint failed\n"));\r
}\r
\r
RemoveEntryList (&Urb->UrbList);\r
//\r
Status = XhcDequeueTrbFromEndpoint (Xhc, Urb);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhciDelAllAsyncIntTransfers: XhcDequeueTrbFromEndpoint failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhciDelAllAsyncIntTransfers: XhcDequeueTrbFromEndpoint failed\n"));\r
}\r
\r
RemoveEntryList (&Urb->UrbList);\r
//\r
Status = XhcFlushAsyncIntMap (Xhc, Urb);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcMonitorAsyncRequests: Fail to Flush AsyncInt Mapped Memeory\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcMonitorAsyncRequests: Fail to Flush AsyncInt Mapped Memeory\n"));\r
}\r
\r
//\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcInitializeDeviceSlot: Enable Slot Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcInitializeDeviceSlot: Enable Slot Failed, Status = %r\n", Status));\r
return Status;\r
}\r
ASSERT (EvtTrb->SlotId <= Xhc->MaxSlotsEn);\r
- DEBUG ((EFI_D_INFO, "Enable Slot Successfully, The Slot ID = 0x%x\n", EvtTrb->SlotId));\r
+ DEBUG ((DEBUG_INFO, "Enable Slot Successfully, The Slot ID = 0x%x\n", EvtTrb->SlotId));\r
SlotId = (UINT8)EvtTrb->SlotId;\r
ASSERT (SlotId != 0);\r
\r
);\r
if (!EFI_ERROR (Status)) {\r
DeviceAddress = (UINT8) ((DEVICE_CONTEXT *) OutputContext)->Slot.DeviceAddress;\r
- DEBUG ((EFI_D_INFO, " Address %d assigned successfully\n", DeviceAddress));\r
+ DEBUG ((DEBUG_INFO, " Address %d assigned successfully\n", DeviceAddress));\r
Xhc->UsbDevContext[SlotId].XhciDevAddr = DeviceAddress;\r
} else {\r
DEBUG ((DEBUG_ERROR, " Slot %d address not assigned successfully. Status = %r\n", SlotId, Status));\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcInitializeDeviceSlot64: Enable Slot Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcInitializeDeviceSlot64: Enable Slot Failed, Status = %r\n", Status));\r
return Status;\r
}\r
ASSERT (EvtTrb->SlotId <= Xhc->MaxSlotsEn);\r
- DEBUG ((EFI_D_INFO, "Enable Slot Successfully, The Slot ID = 0x%x\n", EvtTrb->SlotId));\r
+ DEBUG ((DEBUG_INFO, "Enable Slot Successfully, The Slot ID = 0x%x\n", EvtTrb->SlotId));\r
SlotId = (UINT8)EvtTrb->SlotId;\r
ASSERT (SlotId != 0);\r
\r
);\r
if (!EFI_ERROR (Status)) {\r
DeviceAddress = (UINT8) ((DEVICE_CONTEXT_64 *) OutputContext)->Slot.DeviceAddress;\r
- DEBUG ((EFI_D_INFO, " Address %d assigned successfully\n", DeviceAddress));\r
+ DEBUG ((DEBUG_INFO, " Address %d assigned successfully\n", DeviceAddress));\r
Xhc->UsbDevContext[SlotId].XhciDevAddr = DeviceAddress;\r
} else {\r
DEBUG ((DEBUG_ERROR, " Slot %d address not assigned successfully. Status = %r\n", SlotId, Status));\r
Status = XhcDisableSlotCmd (Xhc, Xhc->UsbDevContext[Index + 1].SlotId);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcDisableSlotCmd: failed to disable child, ignore error\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcDisableSlotCmd: failed to disable child, ignore error\n"));\r
Xhc->UsbDevContext[Index + 1].SlotId = 0;\r
}\r
}\r
//\r
// Construct the disable slot command\r
//\r
- DEBUG ((EFI_D_INFO, "Disable device slot %d!\n", SlotId));\r
+ DEBUG ((DEBUG_INFO, "Disable device slot %d!\n", SlotId));\r
\r
ZeroMem (&CmdTrbDisSlot, sizeof (CmdTrbDisSlot));\r
CmdTrbDisSlot.CycleBit = 1;\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcDisableSlotCmd: Disable Slot Command Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcDisableSlotCmd: Disable Slot Command Failed, Status = %r\n", Status));\r
return Status;\r
}\r
//\r
Status = XhcDisableSlotCmd64 (Xhc, Xhc->UsbDevContext[Index + 1].SlotId);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcDisableSlotCmd: failed to disable child, ignore error\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcDisableSlotCmd: failed to disable child, ignore error\n"));\r
Xhc->UsbDevContext[Index + 1].SlotId = 0;\r
}\r
}\r
//\r
// Construct the disable slot command\r
//\r
- DEBUG ((EFI_D_INFO, "Disable device slot %d!\n", SlotId));\r
+ DEBUG ((DEBUG_INFO, "Disable device slot %d!\n", SlotId));\r
\r
ZeroMem (&CmdTrbDisSlot, sizeof (CmdTrbDisSlot));\r
CmdTrbDisSlot.CycleBit = 1;\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcDisableSlotCmd: Disable Slot Command Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcDisableSlotCmd: Disable Slot Command Failed, Status = %r\n", Status));\r
return Status;\r
}\r
//\r
//\r
// Do not support isochronous transfer now.\r
//\r
- DEBUG ((EFI_D_INFO, "XhcInitializeEndpointContext: Unsupport ISO EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcInitializeEndpointContext: Unsupport ISO EP found, Transfer ring is not allocated.\n"));\r
EpDesc = (USB_ENDPOINT_DESCRIPTOR *)((UINTN)EpDesc + EpDesc->Length);\r
continue;\r
case USB_ENDPOINT_INTERRUPT:\r
//\r
// Do not support control transfer now.\r
//\r
- DEBUG ((EFI_D_INFO, "XhcInitializeEndpointContext: Unsupport Control EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcInitializeEndpointContext: Unsupport Control EP found, Transfer ring is not allocated.\n"));\r
default:\r
- DEBUG ((EFI_D_INFO, "XhcInitializeEndpointContext: Unknown EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcInitializeEndpointContext: Unknown EP found, Transfer ring is not allocated.\n"));\r
EpDesc = (USB_ENDPOINT_DESCRIPTOR *)((UINTN)EpDesc + EpDesc->Length);\r
continue;\r
}\r
//\r
// Do not support isochronous transfer now.\r
//\r
- DEBUG ((EFI_D_INFO, "XhcInitializeEndpointContext64: Unsupport ISO EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcInitializeEndpointContext64: Unsupport ISO EP found, Transfer ring is not allocated.\n"));\r
EpDesc = (USB_ENDPOINT_DESCRIPTOR *)((UINTN)EpDesc + EpDesc->Length);\r
continue;\r
case USB_ENDPOINT_INTERRUPT:\r
//\r
// Do not support control transfer now.\r
//\r
- DEBUG ((EFI_D_INFO, "XhcInitializeEndpointContext64: Unsupport Control EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcInitializeEndpointContext64: Unsupport Control EP found, Transfer ring is not allocated.\n"));\r
default:\r
- DEBUG ((EFI_D_INFO, "XhcInitializeEndpointContext64: Unknown EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcInitializeEndpointContext64: Unknown EP found, Transfer ring is not allocated.\n"));\r
EpDesc = (USB_ENDPOINT_DESCRIPTOR *)((UINTN)EpDesc + EpDesc->Length);\r
continue;\r
}\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "Configure Endpoint\n"));\r
+ DEBUG ((DEBUG_INFO, "Configure Endpoint\n"));\r
Status = XhcCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcSetConfigCmd: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcSetConfigCmd: Config Endpoint Failed, Status = %r\n", Status));\r
} else {\r
Xhc->UsbDevContext[SlotId].ActiveConfiguration = ConfigDesc->ConfigurationValue;\r
}\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "Configure Endpoint\n"));\r
+ DEBUG ((DEBUG_INFO, "Configure Endpoint\n"));\r
Status = XhcCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcSetConfigCmd64: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcSetConfigCmd64: Config Endpoint Failed, Status = %r\n", Status));\r
} else {\r
Xhc->UsbDevContext[SlotId].ActiveConfiguration = ConfigDesc->ConfigurationValue;\r
}\r
EVT_TRB_COMMAND_COMPLETION *EvtTrb;\r
CMD_TRB_STOP_ENDPOINT CmdTrbStopED;\r
\r
- DEBUG ((EFI_D_INFO, "XhcStopEndpoint: Slot = 0x%x, Dci = 0x%x\n", SlotId, Dci));\r
+ DEBUG ((DEBUG_INFO, "XhcStopEndpoint: Slot = 0x%x, Dci = 0x%x\n", SlotId, Dci));\r
\r
//\r
// When XhcCheckUrbResult waits for the Stop_Endpoint completion, it also checks\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcStopEndpoint: Stop Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcStopEndpoint: Stop Endpoint Failed, Status = %r\n", Status));\r
}\r
\r
Xhc->PendingUrb = NULL;\r
EVT_TRB_COMMAND_COMPLETION *EvtTrb;\r
CMD_TRB_RESET_ENDPOINT CmdTrbResetED;\r
\r
- DEBUG ((EFI_D_INFO, "XhcResetEndpoint: Slot = 0x%x, Dci = 0x%x\n", SlotId, Dci));\r
+ DEBUG ((DEBUG_INFO, "XhcResetEndpoint: Slot = 0x%x, Dci = 0x%x\n", SlotId, Dci));\r
\r
//\r
// Send stop endpoint command to transit Endpoint from running to stop state\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcResetEndpoint: Reset Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcResetEndpoint: Reset Endpoint Failed, Status = %r\n", Status));\r
}\r
\r
return Status;\r
CMD_SET_TR_DEQ_POINTER CmdSetTRDeq;\r
EFI_PHYSICAL_ADDRESS PhyAddr;\r
\r
- DEBUG ((EFI_D_INFO, "XhcSetTrDequeuePointer: Slot = 0x%x, Dci = 0x%x, Urb = 0x%x\n", SlotId, Dci, Urb));\r
+ DEBUG ((DEBUG_INFO, "XhcSetTrDequeuePointer: Slot = 0x%x, Dci = 0x%x, Urb = 0x%x\n", SlotId, Dci, Urb));\r
\r
//\r
// Send stop endpoint command to transit Endpoint from running to stop state\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcSetTrDequeuePointer: Set TR Dequeue Pointer Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcSetTrDequeuePointer: Set TR Dequeue Pointer Failed, Status = %r\n", Status));\r
}\r
\r
return Status;\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "SetInterface: Configure Endpoint\n"));\r
+ DEBUG ((DEBUG_INFO, "SetInterface: Configure Endpoint\n"));\r
Status = XhcCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SetInterface: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SetInterface: Config Endpoint Failed, Status = %r\n", Status));\r
} else {\r
//\r
// Update the active AlternateSetting.\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "SetInterface64: Configure Endpoint\n"));\r
+ DEBUG ((DEBUG_INFO, "SetInterface64: Configure Endpoint\n"));\r
Status = XhcCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SetInterface64: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SetInterface64: Config Endpoint Failed, Status = %r\n", Status));\r
} else {\r
//\r
// Update the active AlternateSetting.\r
CmdTrbEvalu.CycleBit = 1;\r
CmdTrbEvalu.Type = TRB_TYPE_EVALU_CONTXT;\r
CmdTrbEvalu.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "Evaluate context\n"));\r
+ DEBUG ((DEBUG_INFO, "Evaluate context\n"));\r
Status = XhcCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbEvalu,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcEvaluateContext: Evaluate Context Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcEvaluateContext: Evaluate Context Failed, Status = %r\n", Status));\r
}\r
return Status;\r
}\r
CmdTrbEvalu.CycleBit = 1;\r
CmdTrbEvalu.Type = TRB_TYPE_EVALU_CONTXT;\r
CmdTrbEvalu.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "Evaluate context\n"));\r
+ DEBUG ((DEBUG_INFO, "Evaluate context\n"));\r
Status = XhcCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbEvalu,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcEvaluateContext64: Evaluate Context Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcEvaluateContext64: Evaluate Context Failed, Status = %r\n", Status));\r
}\r
return Status;\r
}\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "Configure Hub Slot Context\n"));\r
+ DEBUG ((DEBUG_INFO, "Configure Hub Slot Context\n"));\r
Status = XhcCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcConfigHubContext: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcConfigHubContext: Config Endpoint Failed, Status = %r\n", Status));\r
}\r
return Status;\r
}\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "Configure Hub Slot Context\n"));\r
+ DEBUG ((DEBUG_INFO, "Configure Hub Slot Context\n"));\r
Status = XhcCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcConfigHubContext64: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcConfigHubContext64: Config Endpoint Failed, Status = %r\n", Status));\r
}\r
return Status;\r
}\r
-\r
-\r
MicroSecondDelay (1000);\r
Status = XhcPeiWaitOpRegBit (Xhc, XHC_USBCMD_OFFSET, XHC_USBCMD_RESET, FALSE, Timeout);\r
ON_EXIT:\r
- DEBUG ((EFI_D_INFO, "XhcPeiResetHC: %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiResetHC: %r\n", Status));\r
return Status;\r
}\r
\r
\r
XhcPeiClearOpRegBit (Xhc, XHC_USBCMD_OFFSET, XHC_USBCMD_RUN);\r
Status = XhcPeiWaitOpRegBit (Xhc, XHC_USBSTS_OFFSET, XHC_USBSTS_HALT, TRUE, Timeout);\r
- DEBUG ((EFI_D_INFO, "XhcPeiHaltHC: %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiHaltHC: %r\n", Status));\r
return Status;\r
}\r
\r
\r
XhcPeiSetOpRegBit (Xhc, XHC_USBCMD_OFFSET, XHC_USBCMD_RUN);\r
Status = XhcPeiWaitOpRegBit (Xhc, XHC_USBSTS_OFFSET, XHC_USBSTS_HALT, FALSE, Timeout);\r
- DEBUG ((EFI_D_INFO, "XhcPeiRunHC: %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiRunHC: %r\n", Status));\r
return Status;\r
}\r
\r
Len = 0;\r
\r
if (XhcPeiIsHalt (Xhc) || XhcPeiIsSysError (Xhc)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiControlTransfer: HC is halted or has system error\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiControlTransfer: HC is halted or has system error\n"));\r
goto ON_EXIT;\r
}\r
\r
);\r
\r
if (Urb == NULL) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiControlTransfer: failed to create URB"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiControlTransfer: failed to create URB"));\r
Status = EFI_OUT_OF_RESOURCES;\r
goto ON_EXIT;\r
}\r
//\r
RecoveryStatus = XhcPeiDequeueTrbFromEndpoint(Xhc, Urb);\r
if (EFI_ERROR(RecoveryStatus)) {\r
- DEBUG((EFI_D_ERROR, "XhcPeiControlTransfer: XhcPeiDequeueTrbFromEndpoint failed\n"));\r
+ DEBUG((DEBUG_ERROR, "XhcPeiControlTransfer: XhcPeiDequeueTrbFromEndpoint failed\n"));\r
}\r
XhcPeiFreeUrb (Xhc, Urb);\r
goto ON_EXIT;\r
} else if ((*TransferResult == EFI_USB_ERR_STALL) || (*TransferResult == EFI_USB_ERR_BABBLE)) {\r
RecoveryStatus = XhcPeiRecoverHaltedEndpoint(Xhc, Urb);\r
if (EFI_ERROR (RecoveryStatus)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiControlTransfer: XhcPeiRecoverHaltedEndpoint failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiControlTransfer: XhcPeiRecoverHaltedEndpoint failed\n"));\r
}\r
Status = EFI_DEVICE_ERROR;\r
XhcPeiFreeUrb (Xhc, Urb);\r
// Don't support multi-TT feature for super speed hub now.\r
//\r
MTT = 0;\r
- DEBUG ((EFI_D_ERROR, "XHCI: Don't support multi-TT feature for Hub now. (force to disable MTT)\n"));\r
+ DEBUG ((DEBUG_ERROR, "XHCI: Don't support multi-TT feature for Hub now. (force to disable MTT)\n"));\r
} else {\r
MTT = 0;\r
}\r
ON_EXIT:\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiControlTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiControlTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
}\r
\r
return Status;\r
Status = EFI_DEVICE_ERROR;\r
\r
if (XhcPeiIsHalt (Xhc) || XhcPeiIsSysError (Xhc)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiBulkTransfer: HC is halted or has system error\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiBulkTransfer: HC is halted or has system error\n"));\r
goto ON_EXIT;\r
}\r
\r
);\r
\r
if (Urb == NULL) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiBulkTransfer: failed to create URB\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiBulkTransfer: failed to create URB\n"));\r
Status = EFI_OUT_OF_RESOURCES;\r
goto ON_EXIT;\r
}\r
//\r
RecoveryStatus = XhcPeiDequeueTrbFromEndpoint(Xhc, Urb);\r
if (EFI_ERROR(RecoveryStatus)) {\r
- DEBUG((EFI_D_ERROR, "XhcPeiBulkTransfer: XhcPeiDequeueTrbFromEndpoint failed\n"));\r
+ DEBUG((DEBUG_ERROR, "XhcPeiBulkTransfer: XhcPeiDequeueTrbFromEndpoint failed\n"));\r
}\r
} else {\r
if (*TransferResult == EFI_USB_NOERROR) {\r
} else if ((*TransferResult == EFI_USB_ERR_STALL) || (*TransferResult == EFI_USB_ERR_BABBLE)) {\r
RecoveryStatus = XhcPeiRecoverHaltedEndpoint(Xhc, Urb);\r
if (EFI_ERROR (RecoveryStatus)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiBulkTransfer: XhcPeiRecoverHaltedEndpoint failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiBulkTransfer: XhcPeiRecoverHaltedEndpoint failed\n"));\r
}\r
Status = EFI_DEVICE_ERROR;\r
}\r
ON_EXIT:\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiBulkTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiBulkTransfer: error - %r, transfer - %x\n", Status, *TransferResult));\r
}\r
\r
return Status;\r
}\r
\r
*PortNumber = XhcDev->HcSParams1.Data.MaxPorts;\r
- DEBUG ((EFI_D_INFO, "XhcPeiGetRootHubPortNumber: PortNumber = %x\n", *PortNumber));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiGetRootHubPortNumber: PortNumber = %x\n", *PortNumber));\r
return EFI_SUCCESS;\r
}\r
\r
\r
Offset = (UINT32) (XHC_PORTSC_OFFSET + (0x10 * PortNumber));\r
State = XhcPeiReadOpReg (Xhc, Offset);\r
- DEBUG ((EFI_D_INFO, "XhcPeiClearRootHubPortFeature: Port: %x State: %x\n", PortNumber, State));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiClearRootHubPortFeature: Port: %x State: %x\n", PortNumber, State));\r
\r
//\r
// Mask off the port status change bits, these bits are\r
}\r
\r
ON_EXIT:\r
- DEBUG ((EFI_D_INFO, "XhcPeiClearRootHubPortFeature: PortFeature: %x Status = %r\n", PortFeature, Status));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiClearRootHubPortFeature: PortFeature: %x Status = %r\n", PortFeature, Status));\r
return Status;\r
}\r
\r
\r
Offset = (UINT32) (XHC_PORTSC_OFFSET + (0x10 * PortNumber));\r
State = XhcPeiReadOpReg (Xhc, Offset);\r
- DEBUG ((EFI_D_INFO, "XhcPeiSetRootHubPortFeature: Port: %x State: %x\n", PortNumber, State));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiSetRootHubPortFeature: Port: %x State: %x\n", PortNumber, State));\r
\r
//\r
// Mask off the port status change bits, these bits are\r
}\r
\r
ON_EXIT:\r
- DEBUG ((EFI_D_INFO, "XhcPeiSetRootHubPortFeature: PortFeature: %x Status = %r\n", PortFeature, Status));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiSetRootHubPortFeature: PortFeature: %x Status = %r\n", PortFeature, Status));\r
return Status;\r
}\r
\r
\r
Offset = (UINT32) (XHC_PORTSC_OFFSET + (0x10 * PortNumber));\r
State = XhcPeiReadOpReg (Xhc, Offset);\r
- DEBUG ((EFI_D_INFO, "XhcPeiGetRootHubPortStatus: Port: %x State: %x\n", PortNumber, State));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiGetRootHubPortStatus: Port: %x State: %x\n", PortNumber, State));\r
\r
//\r
// According to XHCI 1.1 spec November 2017,\r
ParentRouteChart.Dword = 0;\r
XhcPeiPollPortStatusChange (Xhc, ParentRouteChart, PortNumber, PortStatus);\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiGetRootHubPortStatus: PortChangeStatus: %x PortStatus: %x\n", PortStatus->PortChangeStatus, PortStatus->PortStatus));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiGetRootHubPortStatus: PortChangeStatus: %x PortStatus: %x\n", PortStatus->PortChangeStatus, PortStatus->PortStatus));\r
return EFI_SUCCESS;\r
}\r
\r
PageSize = XhcPeiReadOpReg (XhcDev, XHC_PAGESIZE_OFFSET) & XHC_PAGESIZE_MASK;\r
XhcDev->PageSize = 1 << (HighBitSet32 (PageSize) + 12);\r
\r
- DEBUG ((EFI_D_INFO, "XhciPei: UsbHostControllerBaseAddress: %x\n", XhcDev->UsbHostControllerBaseAddress));\r
- DEBUG ((EFI_D_INFO, "XhciPei: CapLength: %x\n", XhcDev->CapLength));\r
- DEBUG ((EFI_D_INFO, "XhciPei: HcSParams1: %x\n", XhcDev->HcSParams1.Dword));\r
- DEBUG ((EFI_D_INFO, "XhciPei: HcSParams2: %x\n", XhcDev->HcSParams2.Dword));\r
- DEBUG ((EFI_D_INFO, "XhciPei: HcCParams: %x\n", XhcDev->HcCParams.Dword));\r
- DEBUG ((EFI_D_INFO, "XhciPei: DBOff: %x\n", XhcDev->DBOff));\r
- DEBUG ((EFI_D_INFO, "XhciPei: RTSOff: %x\n", XhcDev->RTSOff));\r
- DEBUG ((EFI_D_INFO, "XhciPei: PageSize: %x\n", XhcDev->PageSize));\r
+ DEBUG ((DEBUG_INFO, "XhciPei: UsbHostControllerBaseAddress: %x\n", XhcDev->UsbHostControllerBaseAddress));\r
+ DEBUG ((DEBUG_INFO, "XhciPei: CapLength: %x\n", XhcDev->CapLength));\r
+ DEBUG ((DEBUG_INFO, "XhciPei: HcSParams1: %x\n", XhcDev->HcSParams1.Dword));\r
+ DEBUG ((DEBUG_INFO, "XhciPei: HcSParams2: %x\n", XhcDev->HcSParams2.Dword));\r
+ DEBUG ((DEBUG_INFO, "XhciPei: HcCParams: %x\n", XhcDev->HcCParams.Dword));\r
+ DEBUG ((DEBUG_INFO, "XhciPei: DBOff: %x\n", XhcDev->DBOff));\r
+ DEBUG ((DEBUG_INFO, "XhciPei: RTSOff: %x\n", XhcDev->RTSOff));\r
+ DEBUG ((DEBUG_INFO, "XhciPei: PageSize: %x\n", XhcDev->PageSize));\r
\r
XhcPeiResetHC (XhcDev, XHC_RESET_TIMEOUT);\r
ASSERT (XhcPeiIsHalt (XhcDev));\r
\r
return EFI_SUCCESS;\r
}\r
-\r
Status = EFI_DEVICE_ERROR;\r
\r
if (XhcPeiIsHalt (Xhc) || XhcPeiIsSysError (Xhc)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiCmdTransfer: HC is halted or has system error\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiCmdTransfer: HC is halted or has system error\n"));\r
goto ON_EXIT;\r
}\r
\r
//\r
Urb = XhcPeiCreateCmdTrb (Xhc, CmdTrb);\r
if (Urb == NULL) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiCmdTransfer: failed to create URB\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiCmdTransfer: failed to create URB\n"));\r
Status = EFI_OUT_OF_RESOURCES;\r
goto ON_EXIT;\r
}\r
\r
Status = XhcPeiCreateTransferTrb (Xhc, Urb);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiCreateUrb: XhcPeiCreateTransferTrb Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiCreateUrb: XhcPeiCreateTransferTrb Failed, Status = %r\n", Status));\r
FreePool (Urb);\r
Urb = NULL;\r
}\r
break;\r
\r
default:\r
- DEBUG ((EFI_D_INFO, "Not supported EPType 0x%x!\n",EPType));\r
+ DEBUG ((DEBUG_INFO, "Not supported EPType 0x%x!\n",EPType));\r
ASSERT (FALSE);\r
break;\r
}\r
}\r
Dci = XhcPeiEndpointToDci (Urb->Ep.EpAddr, (UINT8) (Urb->Ep.Direction));\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiRecoverHaltedEndpoint: Recovery Halted Slot = %x, Dci = %x\n", SlotId, Dci));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiRecoverHaltedEndpoint: Recovery Halted Slot = %x, Dci = %x\n", SlotId, Dci));\r
\r
//\r
// 1) Send Reset endpoint command to transit from halt to stop state\r
//\r
Status = XhcPeiResetEndpoint (Xhc, SlotId, Dci);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiRecoverHaltedEndpoint: Reset Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiRecoverHaltedEndpoint: Reset Endpoint Failed, Status = %r\n", Status));\r
goto Done;\r
}\r
\r
//\r
Status = XhcPeiSetTrDequeuePointer (Xhc, SlotId, Dci, Urb);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiRecoverHaltedEndpoint: Set Dequeue Pointer Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiRecoverHaltedEndpoint: Set Dequeue Pointer Failed, Status = %r\n", Status));\r
goto Done;\r
}\r
\r
}\r
Dci = XhcPeiEndpointToDci (Urb->Ep.EpAddr, (UINT8) (Urb->Ep.Direction));\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiDequeueTrbFromEndpoint: Stop Slot = %x, Dci = %x\n", SlotId, Dci));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiDequeueTrbFromEndpoint: Stop Slot = %x, Dci = %x\n", SlotId, Dci));\r
\r
//\r
// 1) Send Stop endpoint command to stop endpoint.\r
//\r
Status = XhcPeiStopEndpoint (Xhc, SlotId, Dci);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiDequeueTrbFromEndpoint: Stop Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiDequeueTrbFromEndpoint: Stop Endpoint Failed, Status = %r\n", Status));\r
goto Done;\r
}\r
\r
//\r
Status = XhcPeiSetTrDequeuePointer (Xhc, SlotId, Dci, Urb);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiDequeueTrbFromEndpoint: Set Dequeue Pointer Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiDequeueTrbFromEndpoint: Set Dequeue Pointer Failed, Status = %r\n", Status));\r
goto Done;\r
}\r
\r
case TRB_COMPLETION_STALL_ERROR:\r
CheckedUrb->Result |= EFI_USB_ERR_STALL;\r
CheckedUrb->Finished = TRUE;\r
- DEBUG ((EFI_D_ERROR, "XhcPeiCheckUrbResult: STALL_ERROR! Completecode = %x\n", EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiCheckUrbResult: STALL_ERROR! Completecode = %x\n", EvtTrb->Completecode));\r
goto EXIT;\r
\r
case TRB_COMPLETION_BABBLE_ERROR:\r
CheckedUrb->Result |= EFI_USB_ERR_BABBLE;\r
CheckedUrb->Finished = TRUE;\r
- DEBUG ((EFI_D_ERROR, "XhcPeiCheckUrbResult: BABBLE_ERROR! Completecode = %x\n", EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiCheckUrbResult: BABBLE_ERROR! Completecode = %x\n", EvtTrb->Completecode));\r
goto EXIT;\r
\r
case TRB_COMPLETION_DATA_BUFFER_ERROR:\r
CheckedUrb->Result |= EFI_USB_ERR_BUFFER;\r
CheckedUrb->Finished = TRUE;\r
- DEBUG ((EFI_D_ERROR, "XhcPeiCheckUrbResult: ERR_BUFFER! Completecode = %x\n", EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiCheckUrbResult: ERR_BUFFER! Completecode = %x\n", EvtTrb->Completecode));\r
goto EXIT;\r
\r
case TRB_COMPLETION_USB_TRANSACTION_ERROR:\r
CheckedUrb->Result |= EFI_USB_ERR_TIMEOUT;\r
CheckedUrb->Finished = TRUE;\r
- DEBUG ((EFI_D_ERROR, "XhcPeiCheckUrbResult: TRANSACTION_ERROR! Completecode = %x\n", EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiCheckUrbResult: TRANSACTION_ERROR! Completecode = %x\n", EvtTrb->Completecode));\r
goto EXIT;\r
\r
case TRB_COMPLETION_SHORT_PACKET:\r
case TRB_COMPLETION_SUCCESS:\r
if (EvtTrb->Completecode == TRB_COMPLETION_SHORT_PACKET) {\r
- DEBUG ((EFI_D_VERBOSE, "XhcPeiCheckUrbResult: short packet happens!\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "XhcPeiCheckUrbResult: short packet happens!\n"));\r
}\r
\r
TRBType = (UINT8) (TRBPtr->Type);\r
break;\r
\r
default:\r
- DEBUG ((EFI_D_ERROR, "XhcPeiCheckUrbResult: Transfer Default Error Occur! Completecode = 0x%x!\n", EvtTrb->Completecode));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiCheckUrbResult: Transfer Default Error Occur! Completecode = 0x%x!\n", EvtTrb->Completecode));\r
CheckedUrb->Result |= EFI_USB_ERR_TIMEOUT;\r
CheckedUrb->Finished = TRUE;\r
goto EXIT;\r
UINT8 SlotId;\r
USB_DEV_ROUTE RouteChart;\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiPollPortStatusChange: PortChangeStatus: %x PortStatus: %x\n", PortState->PortChangeStatus, PortState->PortStatus));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiPollPortStatusChange: PortChangeStatus: %x PortStatus: %x\n", PortState->PortChangeStatus, PortState->PortStatus));\r
\r
Status = EFI_SUCCESS;\r
\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiInitializeDeviceSlot: Enable Slot Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiInitializeDeviceSlot: Enable Slot Failed, Status = %r\n", Status));\r
return Status;\r
}\r
ASSERT (EvtTrb->SlotId <= Xhc->MaxSlotsEn);\r
- DEBUG ((EFI_D_INFO, "XhcPeiInitializeDeviceSlot: Enable Slot Successfully, The Slot ID = 0x%x\n", EvtTrb->SlotId));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiInitializeDeviceSlot: Enable Slot Successfully, The Slot ID = 0x%x\n", EvtTrb->SlotId));\r
SlotId = (UINT8) EvtTrb->SlotId;\r
ASSERT (SlotId != 0);\r
\r
);\r
if (!EFI_ERROR (Status)) {\r
DeviceAddress = (UINT8) OutputContext->Slot.DeviceAddress;\r
- DEBUG ((EFI_D_INFO, "XhcPeiInitializeDeviceSlot: Address %d assigned successfully\n", DeviceAddress));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiInitializeDeviceSlot: Address %d assigned successfully\n", DeviceAddress));\r
Xhc->UsbDevContext[SlotId].XhciDevAddr = DeviceAddress;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiInitializeDeviceSlot: Enable Slot, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiInitializeDeviceSlot: Enable Slot, Status = %r\n", Status));\r
return Status;\r
}\r
\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiInitializeDeviceSlot64: Enable Slot Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiInitializeDeviceSlot64: Enable Slot Failed, Status = %r\n", Status));\r
return Status;\r
}\r
ASSERT (EvtTrb->SlotId <= Xhc->MaxSlotsEn);\r
- DEBUG ((EFI_D_INFO, "XhcPeiInitializeDeviceSlot64: Enable Slot Successfully, The Slot ID = 0x%x\n", EvtTrb->SlotId));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiInitializeDeviceSlot64: Enable Slot Successfully, The Slot ID = 0x%x\n", EvtTrb->SlotId));\r
SlotId = (UINT8)EvtTrb->SlotId;\r
ASSERT (SlotId != 0);\r
\r
);\r
if (!EFI_ERROR (Status)) {\r
DeviceAddress = (UINT8) OutputContext->Slot.DeviceAddress;\r
- DEBUG ((EFI_D_INFO, "XhcPeiInitializeDeviceSlot64: Address %d assigned successfully\n", DeviceAddress));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiInitializeDeviceSlot64: Address %d assigned successfully\n", DeviceAddress));\r
Xhc->UsbDevContext[SlotId].XhciDevAddr = DeviceAddress;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiInitializeDeviceSlot64: Enable Slot, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiInitializeDeviceSlot64: Enable Slot, Status = %r\n", Status));\r
return Status;\r
}\r
\r
Status = XhcPeiDisableSlotCmd (Xhc, Xhc->UsbDevContext[Index + 1].SlotId);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiDisableSlotCmd: failed to disable child, ignore error\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiDisableSlotCmd: failed to disable child, ignore error\n"));\r
Xhc->UsbDevContext[Index + 1].SlotId = 0;\r
}\r
}\r
//\r
// Construct the disable slot command\r
//\r
- DEBUG ((EFI_D_INFO, "XhcPeiDisableSlotCmd: Disable device slot %d!\n", SlotId));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiDisableSlotCmd: Disable device slot %d!\n", SlotId));\r
\r
ZeroMem (&CmdTrbDisSlot, sizeof (CmdTrbDisSlot));\r
CmdTrbDisSlot.CycleBit = 1;\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiDisableSlotCmd: Disable Slot Command Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiDisableSlotCmd: Disable Slot Command Failed, Status = %r\n", Status));\r
return Status;\r
}\r
//\r
Xhc->UsbDevContext[SlotId].Enabled = FALSE;\r
Xhc->UsbDevContext[SlotId].SlotId = 0;\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiDisableSlotCmd: Disable Slot Command, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiDisableSlotCmd: Disable Slot Command, Status = %r\n", Status));\r
return Status;\r
}\r
\r
Status = XhcPeiDisableSlotCmd64 (Xhc, Xhc->UsbDevContext[Index + 1].SlotId);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiDisableSlotCmd64: failed to disable child, ignore error\n"));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiDisableSlotCmd64: failed to disable child, ignore error\n"));\r
Xhc->UsbDevContext[Index + 1].SlotId = 0;\r
}\r
}\r
//\r
// Construct the disable slot command\r
//\r
- DEBUG ((EFI_D_INFO, "XhcPeiDisableSlotCmd64: Disable device slot %d!\n", SlotId));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiDisableSlotCmd64: Disable device slot %d!\n", SlotId));\r
\r
ZeroMem (&CmdTrbDisSlot, sizeof (CmdTrbDisSlot));\r
CmdTrbDisSlot.CycleBit = 1;\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiDisableSlotCmd64: Disable Slot Command Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiDisableSlotCmd64: Disable Slot Command Failed, Status = %r\n", Status));\r
return Status;\r
}\r
//\r
Xhc->UsbDevContext[SlotId].Enabled = FALSE;\r
Xhc->UsbDevContext[SlotId].SlotId = 0;\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiDisableSlotCmd64: Disable Slot Command, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiDisableSlotCmd64: Disable Slot Command, Status = %r\n", Status));\r
return Status;\r
}\r
\r
//\r
// Do not support isochronous transfer now.\r
//\r
- DEBUG ((EFI_D_INFO, "XhcPeiSetConfigCmd: Unsupport ISO EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiSetConfigCmd: Unsupport ISO EP found, Transfer ring is not allocated.\n"));\r
EpDesc = (USB_ENDPOINT_DESCRIPTOR *)((UINTN)EpDesc + EpDesc->Length);\r
continue;\r
case USB_ENDPOINT_INTERRUPT:\r
//\r
// Do not support control transfer now.\r
//\r
- DEBUG ((EFI_D_INFO, "XhcPeiSetConfigCmd: Unsupport Control EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiSetConfigCmd: Unsupport Control EP found, Transfer ring is not allocated.\n"));\r
default:\r
- DEBUG ((EFI_D_INFO, "XhcPeiSetConfigCmd: Unknown EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiSetConfigCmd: Unknown EP found, Transfer ring is not allocated.\n"));\r
EpDesc = (USB_ENDPOINT_DESCRIPTOR *)((UINTN)EpDesc + EpDesc->Length);\r
continue;\r
}\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "XhcSetConfigCmd: Configure Endpoint\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcSetConfigCmd: Configure Endpoint\n"));\r
Status = XhcPeiCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcSetConfigCmd: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcSetConfigCmd: Config Endpoint Failed, Status = %r\n", Status));\r
}\r
return Status;\r
}\r
//\r
// Do not support isochronous transfer now.\r
//\r
- DEBUG ((EFI_D_INFO, "XhcPeiSetConfigCmd64: Unsupport ISO EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiSetConfigCmd64: Unsupport ISO EP found, Transfer ring is not allocated.\n"));\r
EpDesc = (USB_ENDPOINT_DESCRIPTOR *)((UINTN)EpDesc + EpDesc->Length);\r
continue;\r
case USB_ENDPOINT_INTERRUPT:\r
//\r
// Do not support control transfer now.\r
//\r
- DEBUG ((EFI_D_INFO, "XhcPeiSetConfigCmd64: Unsupport Control EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiSetConfigCmd64: Unsupport Control EP found, Transfer ring is not allocated.\n"));\r
default:\r
- DEBUG ((EFI_D_INFO, "XhcPeiSetConfigCmd64: Unknown EP found, Transfer ring is not allocated.\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiSetConfigCmd64: Unknown EP found, Transfer ring is not allocated.\n"));\r
EpDesc = (USB_ENDPOINT_DESCRIPTOR *)((UINTN)EpDesc + EpDesc->Length);\r
continue;\r
}\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "XhcSetConfigCmd64: Configure Endpoint\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcSetConfigCmd64: Configure Endpoint\n"));\r
Status = XhcPeiCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcSetConfigCmd64: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcSetConfigCmd64: Config Endpoint Failed, Status = %r\n", Status));\r
}\r
\r
return Status;\r
CmdTrbEvalu.CycleBit = 1;\r
CmdTrbEvalu.Type = TRB_TYPE_EVALU_CONTXT;\r
CmdTrbEvalu.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "XhcEvaluateContext: Evaluate context\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcEvaluateContext: Evaluate context\n"));\r
Status = XhcPeiCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbEvalu,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcEvaluateContext: Evaluate Context Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcEvaluateContext: Evaluate Context Failed, Status = %r\n", Status));\r
}\r
return Status;\r
}\r
CmdTrbEvalu.CycleBit = 1;\r
CmdTrbEvalu.Type = TRB_TYPE_EVALU_CONTXT;\r
CmdTrbEvalu.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "XhcEvaluateContext64: Evaluate context 64\n"));\r
+ DEBUG ((DEBUG_INFO, "XhcEvaluateContext64: Evaluate context 64\n"));\r
Status = XhcPeiCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbEvalu,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcEvaluateContext64: Evaluate Context Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcEvaluateContext64: Evaluate Context Failed, Status = %r\n", Status));\r
}\r
return Status;\r
}\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "Configure Hub Slot Context\n"));\r
+ DEBUG ((DEBUG_INFO, "Configure Hub Slot Context\n"));\r
Status = XhcPeiCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcConfigHubContext: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcConfigHubContext: Config Endpoint Failed, Status = %r\n", Status));\r
}\r
return Status;\r
}\r
CmdTrbCfgEP.CycleBit = 1;\r
CmdTrbCfgEP.Type = TRB_TYPE_CON_ENDPOINT;\r
CmdTrbCfgEP.SlotId = Xhc->UsbDevContext[SlotId].SlotId;\r
- DEBUG ((EFI_D_INFO, "Configure Hub Slot Context 64\n"));\r
+ DEBUG ((DEBUG_INFO, "Configure Hub Slot Context 64\n"));\r
Status = XhcPeiCmdTransfer (\r
Xhc,\r
(TRB_TEMPLATE *) (UINTN) &CmdTrbCfgEP,\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcConfigHubContext64: Config Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcConfigHubContext64: Config Endpoint Failed, Status = %r\n", Status));\r
}\r
return Status;\r
}\r
EVT_TRB_COMMAND_COMPLETION *EvtTrb;\r
CMD_TRB_STOP_ENDPOINT CmdTrbStopED;\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiStopEndpoint: Slot = 0x%x, Dci = 0x%x\n", SlotId, Dci));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiStopEndpoint: Slot = 0x%x, Dci = 0x%x\n", SlotId, Dci));\r
\r
//\r
// Send stop endpoint command to transit Endpoint from running to stop state\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiStopEndpoint: Stop Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiStopEndpoint: Stop Endpoint Failed, Status = %r\n", Status));\r
}\r
\r
return Status;\r
EVT_TRB_COMMAND_COMPLETION *EvtTrb;\r
CMD_TRB_RESET_ENDPOINT CmdTrbResetED;\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiResetEndpoint: Slot = 0x%x, Dci = 0x%x\n", SlotId, Dci));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiResetEndpoint: Slot = 0x%x, Dci = 0x%x\n", SlotId, Dci));\r
\r
//\r
// Send stop endpoint command to transit Endpoint from running to stop state\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiResetEndpoint: Reset Endpoint Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiResetEndpoint: Reset Endpoint Failed, Status = %r\n", Status));\r
}\r
\r
return Status;\r
CMD_SET_TR_DEQ_POINTER CmdSetTRDeq;\r
EFI_PHYSICAL_ADDRESS PhyAddr;\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiSetTrDequeuePointer: Slot = 0x%x, Dci = 0x%x, Urb = 0x%x\n", SlotId, Dci, Urb));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiSetTrDequeuePointer: Slot = 0x%x, Dci = 0x%x, Urb = 0x%x\n", SlotId, Dci, Urb));\r
\r
//\r
// Send stop endpoint command to transit Endpoint from running to stop state\r
(TRB_TEMPLATE **) (UINTN) &EvtTrb\r
);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "XhcPeiSetTrDequeuePointer: Set TR Dequeue Pointer Failed, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "XhcPeiSetTrDequeuePointer: Set TR Dequeue Pointer Failed, Status = %r\n", Status));\r
}\r
\r
return Status;\r
XhcPeiWriteOpReg (Xhc, XHC_DCBAAP_OFFSET, XHC_LOW_32BIT (DcbaaPhy));\r
XhcPeiWriteOpReg (Xhc, XHC_DCBAAP_OFFSET + 4, XHC_HIGH_32BIT (DcbaaPhy));\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiInitSched:DCBAA=0x%x\n", Xhc->DCBAA));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiInitSched:DCBAA=0x%x\n", Xhc->DCBAA));\r
\r
//\r
// Define the Command Ring Dequeue Pointer by programming the Command Ring Control Register\r
XhcPeiWriteOpReg (Xhc, XHC_CRCR_OFFSET, XHC_LOW_32BIT (CmdRingPhy));\r
XhcPeiWriteOpReg (Xhc, XHC_CRCR_OFFSET + 4, XHC_HIGH_32BIT (CmdRingPhy));\r
\r
- DEBUG ((EFI_D_INFO, "XhcPeiInitSched:XHC_CRCR=0x%x\n", Xhc->CmdRing.RingSeg0));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiInitSched:XHC_CRCR=0x%x\n", Xhc->CmdRing.RingSeg0));\r
\r
//\r
// Disable the 'interrupter enable' bit in USB_CMD\r
// Allocate EventRing for Cmd, Ctrl, Bulk, Interrupt, AsynInterrupt transfer\r
//\r
XhcPeiCreateEventRing (Xhc, &Xhc->EventRing);\r
- DEBUG ((EFI_D_INFO, "XhcPeiInitSched:XHC_EVENTRING=0x%x\n", Xhc->EventRing.EventRingSeg0));\r
+ DEBUG ((DEBUG_INFO, "XhcPeiInitSched:XHC_EVENTRING=0x%x\n", Xhc->EventRing.EventRingSeg0));\r
}\r
\r
/**\r
Xhc->MemPool = NULL;\r
}\r
}\r
-\r
Status = CheckHostAdapterStatus (CommandPacket->HostAdapterStatus);\r
if (EFI_ERROR(Status)) {\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
"ScsiDiskAsyncUnmapNotify: Host adapter indicating error status 0x%x.\n",\r
CommandPacket->HostAdapterStatus\r
));\r
Status = CheckTargetStatus (CommandPacket->TargetStatus);\r
if (EFI_ERROR(Status)) {\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
"ScsiDiskAsyncUnmapNotify: Target indicating error status 0x%x.\n",\r
CommandPacket->HostAdapterStatus\r
));\r
Status = CheckHostAdapterStatus (CommandPacket->HostAdapterStatus);\r
if (EFI_ERROR(Status)) {\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
"ScsiDiskUnmap: Host adapter indicating error status 0x%x.\n",\r
CommandPacket->HostAdapterStatus\r
));\r
Status = CheckTargetStatus (CommandPacket->TargetStatus);\r
if (EFI_ERROR(Status)) {\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
"ScsiDiskUnmap: Target indicating error status 0x%x.\n",\r
CommandPacket->HostAdapterStatus\r
));\r
// Sanity checks for coping with broken devices\r
//\r
if (PageLength > sizeof SupportedVpdPages->SupportedVpdPageList) {\r
- DEBUG ((EFI_D_WARN,\r
+ DEBUG ((DEBUG_WARN,\r
"%a: invalid PageLength (%u) in Supported VPD Pages page\n",\r
__FUNCTION__, (UINT32)PageLength));\r
PageLength = 0;\r
if ((PageLength > 0) &&\r
(SupportedVpdPages->SupportedVpdPageList[0] !=\r
EFI_SCSI_PAGE_CODE_SUPPORTED_VPD)) {\r
- DEBUG ((EFI_D_WARN,\r
+ DEBUG ((DEBUG_WARN,\r
"%a: Supported VPD Pages page doesn't start with code 0x%02x\n",\r
__FUNCTION__, EFI_SCSI_PAGE_CODE_SUPPORTED_VPD));\r
PageLength = 0;\r
if ((Index > 0) &&\r
(SupportedVpdPages->SupportedVpdPageList[Index] <=\r
SupportedVpdPages->SupportedVpdPageList[Index - 1])) {\r
- DEBUG ((EFI_D_WARN,\r
+ DEBUG ((DEBUG_WARN,\r
"%a: non-ascending code in Supported VPD Pages page @ %u\n",\r
__FUNCTION__, Index));\r
Index = 0;\r
ScsiDiskDevice->BlkIo.Media->MediaPresent = FALSE;\r
ScsiDiskDevice->BlkIo.Media->LastBlock = 0;\r
*Action = ACTION_NO_ACTION;\r
- DEBUG ((EFI_D_VERBOSE, "ScsiDisk: ScsiDiskIsNoMedia\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "ScsiDisk: ScsiDiskIsNoMedia\n"));\r
return EFI_SUCCESS;\r
}\r
\r
if (ScsiDiskIsMediaChange (SenseData, NumberOfSenseKeys)) {\r
ScsiDiskDevice->BlkIo.Media->MediaId++;\r
- DEBUG ((EFI_D_VERBOSE, "ScsiDisk: ScsiDiskIsMediaChange!\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "ScsiDisk: ScsiDiskIsMediaChange!\n"));\r
return EFI_SUCCESS;\r
}\r
\r
if (ScsiDiskIsResetBefore (SenseData, NumberOfSenseKeys)) {\r
*Action = ACTION_RETRY_COMMAND_LATER;\r
- DEBUG ((EFI_D_VERBOSE, "ScsiDisk: ScsiDiskIsResetBefore!\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "ScsiDisk: ScsiDiskIsResetBefore!\n"));\r
return EFI_SUCCESS;\r
}\r
\r
if (ScsiDiskIsMediaError (SenseData, NumberOfSenseKeys)) {\r
- DEBUG ((EFI_D_VERBOSE, "ScsiDisk: ScsiDiskIsMediaError\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "ScsiDisk: ScsiDiskIsMediaError\n"));\r
*Action = ACTION_RETRY_WITH_BACKOFF_ALGO;\r
return EFI_DEVICE_ERROR;\r
}\r
\r
if (ScsiDiskIsHardwareError (SenseData, NumberOfSenseKeys)) {\r
- DEBUG ((EFI_D_VERBOSE, "ScsiDisk: ScsiDiskIsHardwareError\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "ScsiDisk: ScsiDiskIsHardwareError\n"));\r
*Action = ACTION_RETRY_WITH_BACKOFF_ALGO;\r
return EFI_DEVICE_ERROR;\r
}\r
if (!ScsiDiskIsDriveReady (SenseData, NumberOfSenseKeys, &RetryLater)) {\r
if (RetryLater) {\r
*Action = ACTION_RETRY_COMMAND_LATER;\r
- DEBUG ((EFI_D_VERBOSE, "ScsiDisk: ScsiDiskDriveNotReady!\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "ScsiDisk: ScsiDiskDriveNotReady!\n"));\r
return EFI_SUCCESS;\r
}\r
*Action = ACTION_NO_ACTION;\r
}\r
\r
*Action = ACTION_RETRY_WITH_BACKOFF_ALGO;\r
- DEBUG ((EFI_D_VERBOSE, "ScsiDisk: Sense Key = 0x%x ASC = 0x%x!\n", SenseData->Sense_Key, SenseData->Addnl_Sense_Code));\r
+ DEBUG ((DEBUG_VERBOSE, "ScsiDisk: Sense Key = 0x%x ASC = 0x%x!\n", SenseData->Sense_Key, SenseData->Addnl_Sense_Code));\r
return EFI_SUCCESS;\r
}\r
\r
}\r
\r
if ((TargetStatus == EFI_EXT_SCSI_STATUS_TARGET_CHECK_CONDITION) || (EFI_ERROR (ReturnStatus))) {\r
- DEBUG ((EFI_D_ERROR, "ScsiDiskRead10: Check Condition happened!\n"));\r
+ DEBUG ((DEBUG_ERROR, "ScsiDiskRead10: Check Condition happened!\n"));\r
Status = DetectMediaParsingSenseKeys (ScsiDiskDevice, ScsiDiskDevice->SenseData, SenseDataLength / sizeof (EFI_SCSI_SENSE_DATA), &Action);\r
if (Action == ACTION_RETRY_COMMAND_LATER) {\r
*NeedRetry = TRUE;\r
}\r
\r
if ((TargetStatus == EFI_EXT_SCSI_STATUS_TARGET_CHECK_CONDITION) || (EFI_ERROR (ReturnStatus))) {\r
- DEBUG ((EFI_D_ERROR, "ScsiDiskWrite10: Check Condition happened!\n"));\r
+ DEBUG ((DEBUG_ERROR, "ScsiDiskWrite10: Check Condition happened!\n"));\r
Status = DetectMediaParsingSenseKeys (ScsiDiskDevice, ScsiDiskDevice->SenseData, SenseDataLength / sizeof (EFI_SCSI_SENSE_DATA), &Action);\r
if (Action == ACTION_RETRY_COMMAND_LATER) {\r
*NeedRetry = TRUE;\r
}\r
\r
if ((TargetStatus == EFI_EXT_SCSI_STATUS_TARGET_CHECK_CONDITION) || (EFI_ERROR (ReturnStatus))) {\r
- DEBUG ((EFI_D_ERROR, "ScsiDiskRead16: Check Condition happened!\n"));\r
+ DEBUG ((DEBUG_ERROR, "ScsiDiskRead16: Check Condition happened!\n"));\r
Status = DetectMediaParsingSenseKeys (ScsiDiskDevice, ScsiDiskDevice->SenseData, SenseDataLength / sizeof (EFI_SCSI_SENSE_DATA), &Action);\r
if (Action == ACTION_RETRY_COMMAND_LATER) {\r
*NeedRetry = TRUE;\r
}\r
\r
if ((TargetStatus == EFI_EXT_SCSI_STATUS_TARGET_CHECK_CONDITION) || (EFI_ERROR (ReturnStatus))) {\r
- DEBUG ((EFI_D_ERROR, "ScsiDiskWrite16: Check Condition happened!\n"));\r
+ DEBUG ((DEBUG_ERROR, "ScsiDiskWrite16: Check Condition happened!\n"));\r
Status = DetectMediaParsingSenseKeys (ScsiDiskDevice, ScsiDiskDevice->SenseData, SenseDataLength / sizeof (EFI_SCSI_SENSE_DATA), &Action);\r
if (Action == ACTION_RETRY_COMMAND_LATER) {\r
*NeedRetry = TRUE;\r
}\r
\r
if (Request->TargetStatus == EFI_EXT_SCSI_STATUS_TARGET_CHECK_CONDITION) {\r
- DEBUG ((EFI_D_ERROR, "ScsiDiskNotify: Check Condition happened!\n"));\r
+ DEBUG ((DEBUG_ERROR, "ScsiDiskNotify: Check Condition happened!\n"));\r
\r
Status = DetectMediaParsingSenseKeys (\r
ScsiDiskDevice,\r
if (((CapacityData16->LowestAlignLogic2 & BIT7) == 0) ||\r
((CapacityData16->LowestAlignLogic2 & BIT6) == 0)) {\r
DEBUG ((\r
- EFI_D_VERBOSE,\r
+ DEBUG_VERBOSE,\r
"ScsiDisk EraseBlock: Either TPE or TPRZ is not set: 0x%x.\n",\r
CapacityData16->LowestAlignLogic2\r
));\r
}\r
} else {\r
DEBUG ((\r
- EFI_D_VERBOSE,\r
+ DEBUG_VERBOSE,\r
"ScsiDisk EraseBlock: ReadCapacity16 failed with status %r.\n",\r
CommandStatus\r
));\r
if ((ScsiDiskDevice->UnmapInfo.MaxLbaCnt == 0) ||\r
(ScsiDiskDevice->UnmapInfo.MaxBlkDespCnt == 0)) {\r
DEBUG ((\r
- EFI_D_VERBOSE,\r
+ DEBUG_VERBOSE,\r
"ScsiDisk EraseBlock: The device server does not implement the UNMAP command.\n"\r
));\r
\r
continue;\r
}\r
if (Capability.SlotType != 0x1) {\r
- DEBUG ((EFI_D_INFO, "The slot at 0x%x is not embedded slot type\n", MmioBase[Index]));\r
+ DEBUG ((DEBUG_INFO, "The slot at 0x%x is not embedded slot type\n", MmioBase[Index]));\r
Status = EFI_UNSUPPORTED;\r
continue;\r
}\r
\r
ExtCsd = &Slot->ExtCsd;\r
if (ExtCsd->ExtCsdRev < 5) {\r
- DEBUG ((EFI_D_ERROR, "The EMMC device version is too low, we don't support!!!\n"));\r
+ DEBUG ((DEBUG_ERROR, "The EMMC device version is too low, we don't support!!!\n"));\r
Status = EFI_UNSUPPORTED;\r
continue;\r
}\r
if ((ExtCsd->PartitioningSupport & BIT0) != BIT0) {\r
- DEBUG ((EFI_D_ERROR, "The EMMC device doesn't support Partition Feature!!!\n"));\r
+ DEBUG ((DEBUG_ERROR, "The EMMC device doesn't support Partition Feature!!!\n"));\r
Status = EFI_UNSUPPORTED;\r
continue;\r
}\r
Status = EmmcPeimHcRwMmio (Bar + EMMC_HC_SW_RST, FALSE, sizeof (SwReset), &SwReset);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimHcReset: write full 1 fails: %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimHcReset: write full 1 fails: %r\n", Status));\r
return Status;\r
}\r
\r
EMMC_TIMEOUT\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "EmmcPeimHcReset: reset done with %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "EmmcPeimHcReset: reset done with %r\n", Status));\r
return Status;\r
}\r
//\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "BaseClkFreq %dMHz Divisor %d ClockFreq %dKhz\n", BaseClkFreq, Divisor, ClockFreq));\r
+ DEBUG ((DEBUG_INFO, "BaseClkFreq %dMHz Divisor %d ClockFreq %dKhz\n", BaseClkFreq, Divisor, ClockFreq));\r
\r
Status = EmmcPeimHcRwMmio (Bar + EMMC_HC_CTRL_VER, TRUE, sizeof (ControllerVer), &ControllerVer);\r
if (EFI_ERROR (Status)) {\r
ASSERT (Divisor <= 0x80);\r
ClockCtrl = (Divisor & 0xFF) << 8;\r
} else {\r
- DEBUG ((EFI_D_ERROR, "Unknown SD Host Controller Spec version [0x%x]!!!\n", ControllerVer));\r
+ DEBUG ((DEBUG_ERROR, "Unknown SD Host Controller Spec version [0x%x]!!!\n", ControllerVer));\r
return EFI_UNSUPPORTED;\r
}\r
\r
ClockCtrl |= BIT0;\r
Status = EmmcPeimHcRwMmio (Bar + EMMC_HC_CLOCK_CTRL, FALSE, sizeof (ClockCtrl), &ClockCtrl);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Set SDCLK Frequency Select and Internal Clock Enable fields fails\n"));\r
+ DEBUG ((DEBUG_ERROR, "Set SDCLK Frequency Select and Internal Clock Enable fields fails\n"));\r
return Status;\r
}\r
\r
// for 32-bit address descriptor table.\r
//\r
if ((Data & (BIT0 | BIT1)) != 0) {\r
- DEBUG ((EFI_D_INFO, "The buffer [0x%x] to construct ADMA desc is not aligned to 4 bytes boundary!\n", Data));\r
+ DEBUG ((DEBUG_INFO, "The buffer [0x%x] to construct ADMA desc is not aligned to 4 bytes boundary!\n", Data));\r
}\r
\r
Entries = DivU64x32 ((DataLen + ADMA_MAX_DATA_PER_LINE - 1), ADMA_MAX_DATA_PER_LINE);\r
}\r
} while (++Retry < 40);\r
\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimTuningClkForHs200: Send tuning block fails at %d times with HostCtrl2 %02x\n", Retry, HostCtrl2));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimTuningClkForHs200: Send tuning block fails at %d times with HostCtrl2 %02x\n", Retry, HostCtrl2));\r
//\r
// Abort the tuning procedure and reset the tuning circuit.\r
//\r
\r
Status = EmmcPeimGetCsd (Slot, Rca, &Slot->Csd);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimSetBusMode: EmmcPeimGetCsd fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimSetBusMode: EmmcPeimGetCsd fails with %r\n", Status));\r
return Status;\r
}\r
\r
\r
Status = EmmcPeimSelect (Slot, Rca);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimSetBusMode: EmmcPeimSelect fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimSetBusMode: EmmcPeimSelect fails with %r\n", Status));\r
return Status;\r
}\r
\r
Status = EmmcPeimHcGetCapability (Slot->EmmcHcBase, &Capability);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimSetBusMode: EmmcPeimHcGetCapability fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimSetBusMode: EmmcPeimHcGetCapability fails with %r\n", Status));\r
return Status;\r
}\r
\r
//\r
Status = EmmcPeimGetExtCsd (Slot, &Slot->ExtCsd);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimSetBusMode: EmmcPeimGetExtCsd fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimSetBusMode: EmmcPeimGetExtCsd fails with %r\n", Status));\r
return Status;\r
}\r
//\r
return EFI_SUCCESS;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "HsTiming %d ClockFreq %d BusWidth %d Ddr %a\n", HsTiming, ClockFreq, BusWidth, IsDdr ? "TRUE":"FALSE"));\r
+ DEBUG ((DEBUG_INFO, "HsTiming %d ClockFreq %d BusWidth %d Ddr %a\n", HsTiming, ClockFreq, BusWidth, IsDdr ? "TRUE":"FALSE"));\r
\r
if (HsTiming == 3) {\r
//\r
\r
Status = EmmcPeimReset (Slot);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimIdentification: EmmcPeimReset fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimIdentification: EmmcPeimReset fails with %r\n", Status));\r
return Status;\r
}\r
\r
do {\r
Status = EmmcPeimGetOcr (Slot, &Ocr);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimIdentification: EmmcPeimGetOcr fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimIdentification: EmmcPeimGetOcr fails with %r\n", Status));\r
return Status;\r
}\r
\r
if (Retry++ == 100) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimIdentification: EmmcPeimGetOcr fails too many times\n"));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimIdentification: EmmcPeimGetOcr fails too many times\n"));\r
return EFI_DEVICE_ERROR;\r
}\r
MicroSecondDelay (10 * 1000);\r
\r
Status = EmmcPeimGetAllCid (Slot);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimIdentification: EmmcPeimGetAllCid fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimIdentification: EmmcPeimGetAllCid fails with %r\n", Status));\r
return Status;\r
}\r
//\r
Rca = 1;\r
Status = EmmcPeimSetRca (Slot, Rca);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EmmcPeimIdentification: EmmcPeimSetRca fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EmmcPeimIdentification: EmmcPeimSetRca fails with %r\n", Status));\r
return Status;\r
}\r
//\r
// Enter Data Tranfer Mode.\r
//\r
- DEBUG ((EFI_D_INFO, "Found a EMMC device at slot [%d], RCA [%d]\n", Slot, Rca));\r
+ DEBUG ((DEBUG_INFO, "Found a EMMC device at slot [%d], RCA [%d]\n", Slot, Rca));\r
\r
Status = EmmcPeimSetBusMode (Slot, Rca);\r
\r
return Status;\r
}\r
-\r
Request = (EMMC_REQUEST *) Context;\r
\r
DEBUG_CODE_BEGIN ();\r
- DEBUG ((EFI_D_INFO, "Emmc Async Request: CmdIndex[%d] Arg[%08x] %r\n",\r
+ DEBUG ((DEBUG_INFO, "Emmc Async Request: CmdIndex[%d] Arg[%08x] %r\n",\r
Request->SdMmcCmdBlk.CommandIndex, Request->SdMmcCmdBlk.CommandArgument,\r
Request->Packet.TransactionStatus));\r
DEBUG_CODE_END ();\r
\r
return Status;\r
}\r
-\r
DumpExtCsd (ExtCsd);\r
\r
if (ExtCsd->ExtCsdRev < 5) {\r
- DEBUG ((EFI_D_ERROR, "The EMMC device version is too low, we don't support!!!\n"));\r
+ DEBUG ((DEBUG_ERROR, "The EMMC device version is too low, we don't support!!!\n"));\r
return EFI_UNSUPPORTED;\r
}\r
\r
if ((ExtCsd->PartitioningSupport & BIT0) != BIT0) {\r
- DEBUG ((EFI_D_ERROR, "The EMMC device doesn't support Partition Feature!!!\n"));\r
+ DEBUG ((DEBUG_ERROR, "The EMMC device doesn't support Partition Feature!!!\n"));\r
return EFI_UNSUPPORTED;\r
}\r
\r
\r
return Status;\r
}\r
-\r
continue;\r
}\r
if (Capability.SlotType != 0x1) {\r
- DEBUG ((EFI_D_INFO, "The slot at 0x%x is not embedded slot type\n", MmioBase[Index]));\r
+ DEBUG ((DEBUG_INFO, "The slot at 0x%x is not embedded slot type\n", MmioBase[Index]));\r
Status = EFI_UNSUPPORTED;\r
continue;\r
}\r
Status = SdPeimHcRwMmio (Bar + SD_HC_SW_RST, FALSE, sizeof (SwReset), &SwReset);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimHcReset: write full 1 fails: %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimHcReset: write full 1 fails: %r\n", Status));\r
return Status;\r
}\r
\r
SD_TIMEOUT\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "SdPeimHcReset: reset done with %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "SdPeimHcReset: reset done with %r\n", Status));\r
return Status;\r
}\r
//\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "BaseClkFreq %dMHz Divisor %d ClockFreq %dKhz\n", BaseClkFreq, Divisor, ClockFreq));\r
+ DEBUG ((DEBUG_INFO, "BaseClkFreq %dMHz Divisor %d ClockFreq %dKhz\n", BaseClkFreq, Divisor, ClockFreq));\r
\r
Status = SdPeimHcRwMmio (Bar + SD_HC_CTRL_VER, TRUE, sizeof (ControllerVer), &ControllerVer);\r
if (EFI_ERROR (Status)) {\r
ASSERT (Divisor <= 0x80);\r
ClockCtrl = (Divisor & 0xFF) << 8;\r
} else {\r
- DEBUG ((EFI_D_ERROR, "Unknown SD Host Controller Spec version [0x%x]!!!\n", ControllerVer));\r
+ DEBUG ((DEBUG_ERROR, "Unknown SD Host Controller Spec version [0x%x]!!!\n", ControllerVer));\r
return EFI_UNSUPPORTED;\r
}\r
\r
ClockCtrl |= BIT0;\r
Status = SdPeimHcRwMmio (Bar + SD_HC_CLOCK_CTRL, FALSE, sizeof (ClockCtrl), &ClockCtrl);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Set SDCLK Frequency Select and Internal Clock Enable fields fails\n"));\r
+ DEBUG ((DEBUG_ERROR, "Set SDCLK Frequency Select and Internal Clock Enable fields fails\n"));\r
return Status;\r
}\r
\r
// for 32-bit address descriptor table.\r
//\r
if ((Data & (BIT0 | BIT1)) != 0) {\r
- DEBUG ((EFI_D_INFO, "The buffer [0x%x] to construct ADMA desc is not aligned to 4 bytes boundary!\n", Data));\r
+ DEBUG ((DEBUG_INFO, "The buffer [0x%x] to construct ADMA desc is not aligned to 4 bytes boundary!\n", Data));\r
}\r
\r
Entries = DivU64x32 ((DataLen + ADMA_MAX_DATA_PER_LINE - 1), ADMA_MAX_DATA_PER_LINE);\r
}\r
} while (++Retry < 40);\r
\r
- DEBUG ((EFI_D_ERROR, "SdPeimTuningClock: Send tuning block fails at %d times with HostCtrl2 %02x\n", Retry, HostCtrl2));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimTuningClock: Send tuning block fails at %d times with HostCtrl2 %02x\n", Retry, HostCtrl2));\r
//\r
// Abort the tuning procedure and reset the tuning circuit.\r
//\r
\r
Status = SdPeimGetCsd (Slot, Rca, &Slot->Csd);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimSetBusMode: SdPeimGetCsd fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimSetBusMode: SdPeimGetCsd fails with %r\n", Status));\r
return Status;\r
}\r
\r
\r
Status = SdPeimSelect (Slot, Rca);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimSetBusMode: SdPeimSelect fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimSetBusMode: SdPeimSelect fails with %r\n", Status));\r
return Status;\r
}\r
\r
BusWidth = 4;\r
Status = SdPeimSwitchBusWidth (Slot, Rca, BusWidth);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimSetBusMode: SdPeimSwitchBusWidth fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimSetBusMode: SdPeimSwitchBusWidth fails with %r\n", Status));\r
return Status;\r
}\r
\r
AccessMode = 0;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "SdPeimSetBusMode: AccessMode %d ClockFreq %d BusWidth %d\n", AccessMode, ClockFreq, BusWidth));\r
+ DEBUG ((DEBUG_INFO, "SdPeimSetBusMode: AccessMode %d ClockFreq %d BusWidth %d\n", AccessMode, ClockFreq, BusWidth));\r
\r
Status = SdPeimSwitch (Slot, AccessMode, 0xF, 0xF, 0xF, TRUE, SwitchResp);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimSetBusMode: SdPeimSwitch fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimSetBusMode: SdPeimSwitch fails with %r\n", Status));\r
return Status;\r
}\r
\r
if ((SwitchResp[16] & 0xF) != AccessMode) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimSetBusMode: SdPeimSwitch to AccessMode %d ClockFreq %d BusWidth %d fails! The Switch response is 0x%1x\n", AccessMode, ClockFreq, BusWidth, SwitchResp[16] & 0xF));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimSetBusMode: SdPeimSwitch to AccessMode %d ClockFreq %d BusWidth %d fails! The Switch response is 0x%1x\n", AccessMode, ClockFreq, BusWidth, SwitchResp[16] & 0xF));\r
return EFI_DEVICE_ERROR;\r
}\r
//\r
\r
Status = SdPeimHcClockSupply (Slot->SdHcBase, ClockFreq * 1000);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimSetBusMode: SdPeimHcClockSupply %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimSetBusMode: SdPeimHcClockSupply %r\n", Status));\r
return Status;\r
}\r
\r
if ((AccessMode == 3) || ((AccessMode == 2) && (Capability.TuningSDR50 != 0))) {\r
Status = SdPeimTuningClock (Slot);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimSetBusMode: SdPeimTuningClock fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimSetBusMode: SdPeimTuningClock fails with %r\n", Status));\r
return Status;\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "SdPeimSetBusMode: SdPeimSetBusMode %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "SdPeimSetBusMode: SdPeimSetBusMode %r\n", Status));\r
\r
return Status;\r
}\r
//\r
Status = SdPeimReset (Slot);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: Executing Cmd0 fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: Executing Cmd0 fails with %r\n", Status));\r
return Status;\r
}\r
//\r
//\r
Status = SdPeimVoltageCheck (Slot, 0x1, 0xFF);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: Executing Cmd8 fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: Executing Cmd8 fails with %r\n", Status));\r
return Status;\r
}\r
//\r
//\r
Status = SdioSendOpCond (Slot, 0, FALSE);\r
if (!EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: Found SDIO device, ignore it as we don't support\n"));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: Found SDIO device, ignore it as we don't support\n"));\r
return EFI_DEVICE_ERROR;\r
}\r
//\r
//\r
Status = SdPeimSendOpCond (Slot, 0, 0, FALSE, FALSE, FALSE, &Ocr);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: Executing SdPeimSendOpCond fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: Executing SdPeimSendOpCond fails with %r\n", Status));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
do {\r
Status = SdPeimSendOpCond (Slot, 0, Ocr, S18r, Xpc, TRUE, &Ocr);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: SdPeimSendOpCond fails with %r Ocr %x, S18r %x, Xpc %x\n", Status, Ocr, S18r, Xpc));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: SdPeimSendOpCond fails with %r Ocr %x, S18r %x, Xpc %x\n", Status, Ocr, S18r, Xpc));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
if (Retry++ == 100) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: SdPeimSendOpCond fails too many times\n"));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: SdPeimSendOpCond fails too many times\n"));\r
return EFI_DEVICE_ERROR;\r
}\r
MicroSecondDelay (10 * 1000);\r
((Ocr & BIT24) != 0)) {\r
Status = SdPeimVoltageSwitch (Slot);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: Executing SdPeimVoltageSwitch fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: Executing SdPeimVoltageSwitch fails with %r\n", Status));\r
Status = EFI_DEVICE_ERROR;\r
goto Error;\r
} else {\r
\r
SdPeimHcRwMmio (Slot->SdHcBase + SD_HC_PRESENT_STATE, TRUE, sizeof (PresentState), &PresentState);\r
if (((PresentState >> 20) & 0xF) != 0) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: SwitchVoltage fails with PresentState = 0x%x\n", PresentState));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: SwitchVoltage fails with PresentState = 0x%x\n", PresentState));\r
Status = EFI_DEVICE_ERROR;\r
goto Error;\r
}\r
\r
SdPeimHcRwMmio (Slot->SdHcBase + SD_HC_HOST_CTRL2, TRUE, sizeof (HostCtrl2), &HostCtrl2);\r
if ((HostCtrl2 & BIT3) == 0) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: SwitchVoltage fails with HostCtrl2 = 0x%x\n", HostCtrl2));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: SwitchVoltage fails with HostCtrl2 = 0x%x\n", HostCtrl2));\r
Status = EFI_DEVICE_ERROR;\r
goto Error;\r
}\r
\r
SdPeimHcRwMmio (Slot->SdHcBase + SD_HC_PRESENT_STATE, TRUE, sizeof (PresentState), &PresentState);\r
if (((PresentState >> 20) & 0xF) != 0xF) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: SwitchVoltage fails with PresentState = 0x%x, It should be 0xF\n", PresentState));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: SwitchVoltage fails with PresentState = 0x%x, It should be 0xF\n", PresentState));\r
Status = EFI_DEVICE_ERROR;\r
goto Error;\r
}\r
}\r
- DEBUG ((EFI_D_INFO, "SdPeimIdentification: Switch to 1.8v signal voltage success\n"));\r
+ DEBUG ((DEBUG_INFO, "SdPeimIdentification: Switch to 1.8v signal voltage success\n"));\r
}\r
\r
Status = SdPeimAllSendCid (Slot);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: Executing SdPeimAllSendCid fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: Executing SdPeimAllSendCid fails with %r\n", Status));\r
return Status;\r
}\r
\r
Status = SdPeimSetRca (Slot, &Rca);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SdPeimIdentification: Executing SdPeimSetRca fails with %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "SdPeimIdentification: Executing SdPeimSetRca fails with %r\n", Status));\r
return Status;\r
}\r
//\r
// Enter Data Tranfer Mode.\r
//\r
- DEBUG ((EFI_D_INFO, "Found a SD device at slot [%d]\n", Slot));\r
+ DEBUG ((DEBUG_INFO, "Found a SD device at slot [%d]\n", Slot));\r
\r
Status = SdPeimSetBusMode (Slot, Rca, ((Ocr & BIT24) != 0));\r
\r
Request = (SD_REQUEST *) Context;\r
\r
DEBUG_CODE_BEGIN ();\r
- DEBUG ((EFI_D_INFO, "Sd Async Request: CmdIndex[%d] Arg[%08x] %r\n",\r
+ DEBUG ((DEBUG_INFO, "Sd Async Request: CmdIndex[%d] Arg[%08x] %r\n",\r
Request->SdMmcCmdBlk.CommandIndex, Request->SdMmcCmdBlk.CommandArgument,\r
Request->Packet.TransactionStatus));\r
DEBUG_CODE_END ();\r
\r
Status = PassThru->PassThru (PassThru, Device->Slot, &Packet, NULL);\r
if (!EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "Set RCA succeeds with Resp0 = 0x%x\n", SdMmcStatusBlk.Resp0));\r
+ DEBUG ((DEBUG_INFO, "Set RCA succeeds with Resp0 = 0x%x\n", SdMmcStatusBlk.Resp0));\r
*Rca = (UINT16)(SdMmcStatusBlk.Resp0 >> 16);\r
}\r
\r
\r
return Status;\r
}\r
-\r
\r
Status = SdSetRca (Device, &Rca);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "DiscoverUserArea(): Assign new Rca = 0x%x fails with %r\n", Rca, Status));\r
+ DEBUG ((DEBUG_ERROR, "DiscoverUserArea(): Assign new Rca = 0x%x fails with %r\n", Rca, Status));\r
return Status;\r
}\r
\r
\r
Status = SdSelect (Device, Rca);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "DiscoverUserArea(): Reselect the device 0x%x fails with %r\n", Rca, Status));\r
+ DEBUG ((DEBUG_ERROR, "DiscoverUserArea(): Reselect the device 0x%x fails with %r\n", Rca, Status));\r
return Status;\r
}\r
\r
\r
return Status;\r
}\r
-\r
(SenseData->Addnl_Sense_Code == EFI_SCSI_ASC_NO_MEDIA)) {\r
Media->MediaPresent = FALSE;\r
*NeedRetry = FALSE;\r
- DEBUG ((EFI_D_VERBOSE, "UfsBlockIoPei: Is No Media\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UfsBlockIoPei: Is No Media\n"));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
if ((SenseData->Sense_Key == EFI_SCSI_SK_UNIT_ATTENTION) &&\r
(SenseData->Addnl_Sense_Code == EFI_SCSI_ASC_MEDIA_CHANGE)) {\r
*NeedRetry = TRUE;\r
- DEBUG ((EFI_D_VERBOSE, "UfsBlockIoPei: Is Media Change\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UfsBlockIoPei: Is Media Change\n"));\r
return EFI_SUCCESS;\r
}\r
\r
if ((SenseData->Sense_Key == EFI_SCSI_SK_UNIT_ATTENTION) &&\r
(SenseData->Addnl_Sense_Code == EFI_SCSI_ASC_RESET)) {\r
*NeedRetry = TRUE;\r
- DEBUG ((EFI_D_VERBOSE, "UfsBlockIoPei: Was Reset Before\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UfsBlockIoPei: Was Reset Before\n"));\r
return EFI_SUCCESS;\r
}\r
\r
((SenseData->Sense_Key == EFI_SCSI_SK_NOT_READY) &&\r
(SenseData->Addnl_Sense_Code == EFI_SCSI_ASC_MEDIA_UPSIDE_DOWN))) {\r
*NeedRetry = FALSE;\r
- DEBUG ((EFI_D_VERBOSE, "UfsBlockIoPei: Media Error\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UfsBlockIoPei: Media Error\n"));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
if (SenseData->Sense_Key == EFI_SCSI_SK_HARDWARE_ERROR) {\r
*NeedRetry = FALSE;\r
- DEBUG ((EFI_D_VERBOSE, "UfsBlockIoPei: Hardware Error\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UfsBlockIoPei: Hardware Error\n"));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
(SenseData->Addnl_Sense_Code == EFI_SCSI_ASC_NOT_READY) &&\r
(SenseData->Addnl_Sense_Code_Qualifier == EFI_SCSI_ASCQ_IN_PROGRESS)) {\r
*NeedRetry = TRUE;\r
- DEBUG ((EFI_D_VERBOSE, "UfsBlockIoPei: Was Reset Before\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UfsBlockIoPei: Was Reset Before\n"));\r
return EFI_SUCCESS;\r
}\r
\r
*NeedRetry = FALSE;\r
- DEBUG ((EFI_D_VERBOSE, "UfsBlockIoPei: Sense Key = 0x%x ASC = 0x%x!\n", SenseData->Sense_Key, SenseData->Addnl_Sense_Code));\r
+ DEBUG ((DEBUG_VERBOSE, "UfsBlockIoPei: Sense Key = 0x%x ASC = 0x%x!\n", SenseData->Sense_Key, SenseData->Addnl_Sense_Code));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
//\r
Status = UfsControllerInit (Private);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UfsDevicePei: Host Controller Initialization Error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UfsDevicePei: Host Controller Initialization Error, Status = %r\n", Status));\r
Controller++;\r
continue;\r
}\r
//\r
Status = UfsExecNopCmds (Private);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ufs Sending NOP IN command Error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ufs Sending NOP IN command Error, Status = %r\n", Status));\r
Controller++;\r
continue;\r
}\r
//\r
Status = UfsSetFlag (Private, UfsFlagDevInit);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ufs Set fDeviceInit Flag Error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ufs Set fDeviceInit Flag Error, Status = %r\n", Status));\r
Controller++;\r
continue;\r
}\r
//\r
Status = UfsRwDeviceDesc (Private, TRUE, UfsConfigDesc, 0, 0, &Config, sizeof (UFS_CONFIG_DESC));\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ufs Get Configuration Descriptor Error, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ufs Get Configuration Descriptor Error, Status = %r\n", Status));\r
Controller++;\r
continue;\r
}\r
for (Index = 0; Index < UFS_PEIM_MAX_LUNS; Index++) {\r
if (Config.UnitDescConfParams[Index].LunEn != 0) {\r
Private->Luns.BitMask |= (BIT0 << Index);\r
- DEBUG ((EFI_D_INFO, "Ufs %d Lun %d is enabled\n", Controller, Index));\r
+ DEBUG ((DEBUG_INFO, "Ufs %d Lun %d is enabled\n", Controller, Index));\r
}\r
}\r
\r
case 0x00:\r
break;\r
case 0x01:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - INVALID_MIB_ATTRIBUTE\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - INVALID_MIB_ATTRIBUTE\n"));\r
break;\r
case 0x02:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - INVALID_MIB_ATTRIBUTE_VALUE\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - INVALID_MIB_ATTRIBUTE_VALUE\n"));\r
break;\r
case 0x03:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - READ_ONLY_MIB_ATTRIBUTE\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - READ_ONLY_MIB_ATTRIBUTE\n"));\r
break;\r
case 0x04:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - WRITE_ONLY_MIB_ATTRIBUTE\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - WRITE_ONLY_MIB_ATTRIBUTE\n"));\r
break;\r
case 0x05:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - BAD_INDEX\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - BAD_INDEX\n"));\r
break;\r
case 0x06:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - LOCKED_MIB_ATTRIBUTE\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - LOCKED_MIB_ATTRIBUTE\n"));\r
break;\r
case 0x07:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - BAD_TEST_FEATURE_INDEX\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - BAD_TEST_FEATURE_INDEX\n"));\r
break;\r
case 0x08:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - PEER_COMMUNICATION_FAILURE\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - PEER_COMMUNICATION_FAILURE\n"));\r
break;\r
case 0x09:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - BUSY\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - BUSY\n"));\r
break;\r
case 0x0A:\r
- DEBUG ((EFI_D_VERBOSE, "UIC configuration command fails - DME_FAILURE\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC configuration command fails - DME_FAILURE\n"));\r
break;\r
default :\r
ASSERT (FALSE);\r
case 0x00:\r
break;\r
case 0x01:\r
- DEBUG ((EFI_D_VERBOSE, "UIC control command fails - FAILURE\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "UIC control command fails - FAILURE\n"));\r
break;\r
default :\r
ASSERT (FALSE);\r
{\r
switch (Result) {\r
case 0xF6:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with Parameter Not Readable\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with Parameter Not Readable\n"));\r
break;\r
case 0xF7:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with Parameter Not Writeable\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with Parameter Not Writeable\n"));\r
break;\r
case 0xF8:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with Parameter Already Written\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with Parameter Already Written\n"));\r
break;\r
case 0xF9:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with Invalid Length\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with Invalid Length\n"));\r
break;\r
case 0xFA:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with Invalid Value\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with Invalid Value\n"));\r
break;\r
case 0xFB:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with Invalid Selector\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with Invalid Selector\n"));\r
break;\r
case 0xFC:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with Invalid Index\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with Invalid Index\n"));\r
break;\r
case 0xFD:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with Invalid Idn\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with Invalid Idn\n"));\r
break;\r
case 0xFE:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with Invalid Opcode\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with Invalid Opcode\n"));\r
break;\r
case 0xFF:\r
- DEBUG ((EFI_D_VERBOSE, "Query Response with General Failure\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "Query Response with General Failure\n"));\r
break;\r
default :\r
ASSERT (FALSE);\r
\r
if ((BufferSize & (BIT0 | BIT1)) != 0) {\r
BufferSize &= ~(BIT0 | BIT1);\r
- DEBUG ((EFI_D_WARN, "UfsInitUtpPrdt: The BufferSize [%d] is not dword-aligned!\n", BufferSize));\r
+ DEBUG ((DEBUG_WARN, "UfsInitUtpPrdt: The BufferSize [%d] is not dword-aligned!\n", BufferSize));\r
}\r
\r
if (BufferSize == 0) {\r
// Check the transfer request result.\r
//\r
if (Response->Response != 0) {\r
- DEBUG ((EFI_D_ERROR, "UfsExecScsiCmds() fails with Target Failure\n"));\r
+ DEBUG ((DEBUG_ERROR, "UfsExecScsiCmds() fails with Target Failure\n"));\r
Status = EFI_DEVICE_ERROR;\r
goto Exit;\r
}\r
return EFI_NOT_FOUND;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "UfsblockioPei: found a attached UFS device\n"));\r
+ DEBUG ((DEBUG_INFO, "UfsblockioPei: found a attached UFS device\n"));\r
\r
return EFI_SUCCESS;\r
}\r
\r
Status = UfsEnableHostController (Private);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UfsDevicePei: Enable Host Controller Fails, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UfsDevicePei: Enable Host Controller Fails, Status = %r\n", Status));\r
return Status;\r
}\r
\r
Status = UfsDeviceDetection (Private);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UfsDevicePei: Device Detection Fails, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UfsDevicePei: Device Detection Fails, Status = %r\n", Status));\r
return Status;\r
}\r
\r
Status = UfsInitTaskManagementRequestList (Private);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UfsDevicePei: Task management list initialization Fails, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UfsDevicePei: Task management list initialization Fails, Status = %r\n", Status));\r
return Status;\r
}\r
\r
Status = UfsInitTransferRequestList (Private);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UfsDevicePei: Transfer list initialization Fails, Status = %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UfsDevicePei: Transfer list initialization Fails, Status = %r\n", Status));\r
\r
if (Private->TmrlMapping != NULL) {\r
IoMmuFreeBuffer (\r
return Status;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "UfsDevicePei Finished\n"));\r
+ DEBUG ((DEBUG_INFO, "UfsDevicePei Finished\n"));\r
return EFI_SUCCESS;\r
}\r
\r
return EFI_DEVICE_ERROR;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "UfsDevicePei: Stop the UFS Host Controller\n"));\r
+ DEBUG ((DEBUG_INFO, "UfsDevicePei: Stop the UFS Host Controller\n"));\r
\r
return EFI_SUCCESS;\r
}\r
-\r
LastBlock = ((UINT32) Data.LastLba3 << 24) | (Data.LastLba2 << 16) | (Data.LastLba1 << 8) | Data.LastLba0;\r
\r
if (LastBlock == 0xFFFFFFFF) {\r
- DEBUG ((EFI_D_INFO, "The usb device LBA count is larger than 0xFFFFFFFF!\n"));\r
+ DEBUG ((DEBUG_INFO, "The usb device LBA count is larger than 0xFFFFFFFF!\n"));\r
}\r
\r
PeiBotDevice->Media.LastBlock = LastBlock;\r
} else {\r
LastBlock = ((UINT32) FormatData.LastLba3 << 24) | (FormatData.LastLba2 << 16) | (FormatData.LastLba1 << 8) | FormatData.LastLba0;\r
if (LastBlock == 0xFFFFFFFF) {\r
- DEBUG ((EFI_D_INFO, "The usb device LBA count is larger than 0xFFFFFFFF!\n"));\r
+ DEBUG ((DEBUG_INFO, "The usb device LBA count is larger than 0xFFFFFFFF!\n"));\r
}\r
\r
PeiBotDevice->Media.LastBlock = LastBlock;\r
\r
goto ON_EXIT;\r
}\r
- DEBUG ((EFI_D_INFO, "UsbIoControlTransfer: configure changed!!! Do NOT use old UsbIo!!!\n"));\r
+ DEBUG ((DEBUG_INFO, "UsbIoControlTransfer: configure changed!!! Do NOT use old UsbIo!!!\n"));\r
\r
if (Dev->ActiveConfig != NULL) {\r
UsbRemoveConfig (Dev);\r
Status = HubIf->HubApi->ResetPort (HubIf, Dev->ParentPort);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbIoPortReset: failed to reset hub port %d@hub %d, %r \n",\r
+ DEBUG (( DEBUG_ERROR, "UsbIoPortReset: failed to reset hub port %d@hub %d, %r \n",\r
Dev->ParentPort, Dev->ParentAddr, Status));\r
\r
goto ON_EXIT;\r
//\r
// It may fail due to device disconnection or other reasons.\r
//\r
- DEBUG (( EFI_D_ERROR, "UsbIoPortReset: failed to set address for device %d - %r\n",\r
+ DEBUG (( DEBUG_ERROR, "UsbIoPortReset: failed to set address for device %d - %r\n",\r
Dev->Address, Status));\r
\r
goto ON_EXIT;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbIoPortReset: device is now ADDRESSED at %d\n", Dev->Address));\r
+ DEBUG (( DEBUG_INFO, "UsbIoPortReset: device is now ADDRESSED at %d\n", Dev->Address));\r
\r
//\r
// Reset the current active configure, after this device\r
Status = UsbSetConfig (Dev, Dev->ActiveConfig->Desc.ConfigurationValue);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbIoPortReset: failed to set configure for device %d - %r\n",\r
+ DEBUG (( DEBUG_ERROR, "UsbIoPortReset: failed to set configure for device %d - %r\n",\r
Dev->Address, Status));\r
}\r
}\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBusStart: Failed to open device path %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBusStart: Failed to open device path %r\n", Status));\r
\r
FreePool (UsbBus);\r
return Status;\r
);\r
\r
if (EFI_ERROR (Status) && EFI_ERROR (Status2)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBusStart: Failed to open USB_HC/USB2_HC %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBusStart: Failed to open USB_HC/USB2_HC %r\n", Status));\r
\r
Status = EFI_DEVICE_ERROR;\r
goto CLOSE_HC;\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBusStart: Failed to install bus protocol %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBusStart: Failed to install bus protocol %r\n", Status));\r
goto CLOSE_HC;\r
}\r
\r
Status = mUsbRootHubApi.Init (RootIf);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBusStart: Failed to init root hub %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBusStart: Failed to init root hub %r\n", Status));\r
goto FREE_ROOTHUB;\r
}\r
\r
UsbBus->Devices[0] = RootHub;\r
\r
- DEBUG ((EFI_D_INFO, "UsbBusStart: usb bus started on %p, root hub %p\n", Controller, RootIf));\r
+ DEBUG ((DEBUG_INFO, "UsbBusStart: usb bus started on %p, root hub %p\n", Controller, RootIf));\r
return EFI_SUCCESS;\r
\r
FREE_ROOTHUB:\r
);\r
FreePool (UsbBus);\r
\r
- DEBUG ((EFI_D_ERROR, "UsbBusStart: Failed to start bus driver %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBusStart: Failed to start bus driver %r\n", Status));\r
return Status;\r
}\r
\r
return ReturnStatus;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbBusStop: usb bus stopped on %p\n", Controller));\r
+ DEBUG (( DEBUG_INFO, "UsbBusStop: usb bus stopped on %p\n", Controller));\r
\r
//\r
// Locate USB_BUS for the current host controller\r
Setting = UsbCreateDesc (DescBuf, Len, USB_DESC_TYPE_INTERFACE, &Used);\r
\r
if (Setting == NULL) {\r
- DEBUG (( EFI_D_ERROR, "UsbParseInterfaceDesc: failed to create interface descriptor\n"));\r
+ DEBUG (( DEBUG_ERROR, "UsbParseInterfaceDesc: failed to create interface descriptor\n"));\r
return NULL;\r
}\r
\r
//\r
NumEp = Setting->Desc.NumEndpoints;\r
\r
- DEBUG (( EFI_D_INFO, "UsbParseInterfaceDesc: interface %d(setting %d) has %d endpoints\n",\r
+ DEBUG (( DEBUG_INFO, "UsbParseInterfaceDesc: interface %d(setting %d) has %d endpoints\n",\r
Setting->Desc.InterfaceNumber, Setting->Desc.AlternateSetting, (UINT32)NumEp));\r
\r
if (NumEp == 0) {\r
Ep = UsbCreateDesc (DescBuf + Offset, Len - Offset, USB_DESC_TYPE_ENDPOINT, &Used);\r
\r
if (Ep == NULL) {\r
- DEBUG (( EFI_D_ERROR, "UsbParseInterfaceDesc: failed to create endpoint(index %d)\n", (UINT32)Index));\r
+ DEBUG (( DEBUG_ERROR, "UsbParseInterfaceDesc: failed to create endpoint(index %d)\n", (UINT32)Index));\r
goto ON_ERROR;\r
}\r
\r
goto ON_ERROR;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbParseConfigDesc: config %d has %d interfaces\n",\r
+ DEBUG (( DEBUG_INFO, "UsbParseConfigDesc: config %d has %d interfaces\n",\r
Config->Desc.ConfigurationValue, (UINT32)NumIf));\r
\r
for (Index = 0; Index < NumIf; Index++) {\r
Setting = UsbParseInterfaceDesc (DescBuf, Len, &Consumed);\r
\r
if (Setting == NULL) {\r
- DEBUG (( EFI_D_ERROR, "UsbParseConfigDesc: warning: failed to get interface setting, stop parsing now.\n"));\r
+ DEBUG (( DEBUG_ERROR, "UsbParseConfigDesc: warning: failed to get interface setting, stop parsing now.\n"));\r
break;\r
\r
} else if (Setting->Desc.InterfaceNumber >= NumIf) {\r
Status = UsbCtrlGetDesc (UsbDev, USB_DESC_TYPE_CONFIG, Index, 0, &Desc, 8);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbGetOneConfig: failed to get descript length(%d) %r\n",\r
+ DEBUG (( DEBUG_ERROR, "UsbGetOneConfig: failed to get descript length(%d) %r\n",\r
Desc.TotalLength, Status));\r
\r
return NULL;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbGetOneConfig: total length is %d\n", Desc.TotalLength));\r
+ DEBUG (( DEBUG_INFO, "UsbGetOneConfig: total length is %d\n", Desc.TotalLength));\r
\r
//\r
// Reject if TotalLength even cannot cover itself.\r
Status = UsbCtrlGetDesc (UsbDev, USB_DESC_TYPE_CONFIG, Index, 0, Buf, Desc.TotalLength);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbGetOneConfig: failed to get full descript %r\n", Status));\r
+ DEBUG (( DEBUG_ERROR, "UsbGetOneConfig: failed to get full descript %r\n", Status));\r
\r
FreePool (Buf);\r
return NULL;\r
Status = UsbGetDevDesc (UsbDev);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbBuildDescTable: failed to get device descriptor - %r\n", Status));\r
+ DEBUG (( DEBUG_ERROR, "UsbBuildDescTable: failed to get device descriptor - %r\n", Status));\r
return Status;\r
}\r
\r
return EFI_OUT_OF_RESOURCES;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbBuildDescTable: device has %d configures\n", NumConfig));\r
+ DEBUG (( DEBUG_INFO, "UsbBuildDescTable: device has %d configures\n", NumConfig));\r
\r
//\r
// Read each configurations, then parse them\r
Config = UsbGetOneConfig (UsbDev, Index);\r
\r
if (Config == NULL) {\r
- DEBUG (( EFI_D_ERROR, "UsbBuildDescTable: failed to get configure (index %d)\n", Index));\r
+ DEBUG (( DEBUG_ERROR, "UsbBuildDescTable: failed to get configure (index %d)\n", Index));\r
\r
//\r
// If we can get the default descriptor, it is likely that the\r
FreePool (Config);\r
\r
if (ConfigDesc == NULL) {\r
- DEBUG (( EFI_D_ERROR, "UsbBuildDescTable: failed to parse configure (index %d)\n", Index));\r
+ DEBUG (( DEBUG_ERROR, "UsbBuildDescTable: failed to parse configure (index %d)\n", Index));\r
\r
//\r
// If we can get the default descriptor, it is likely that the\r
Status = UsbBuildLangTable (UsbDev);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_INFO, "UsbBuildDescTable: get language ID table %r\n", Status));\r
+ DEBUG (( DEBUG_INFO, "UsbBuildDescTable: get language ID table %r\n", Status));\r
}\r
\r
return EFI_SUCCESS;\r
UsbIf->DevicePath = AppendDevicePathNode (HubIf->DevicePath, &UsbNode.Header);\r
\r
if (UsbIf->DevicePath == NULL) {\r
- DEBUG ((EFI_D_ERROR, "UsbCreateInterface: failed to create device path\n"));\r
+ DEBUG ((DEBUG_ERROR, "UsbCreateInterface: failed to create device path\n"));\r
\r
Status = EFI_OUT_OF_RESOURCES;\r
goto ON_ERROR;\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbCreateInterface: failed to install UsbIo - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbCreateInterface: failed to install UsbIo - %r\n", Status));\r
goto ON_ERROR;\r
}\r
\r
NULL\r
);\r
\r
- DEBUG ((EFI_D_ERROR, "UsbCreateInterface: failed to open host for child - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbCreateInterface: failed to open host for child - %r\n", Status));\r
goto ON_ERROR;\r
}\r
\r
// connect drivers with this interface\r
//\r
if (UsbIsHubInterface (UsbIf)) {\r
- DEBUG ((EFI_D_INFO, "UsbConnectDriver: found a hub device\n"));\r
+ DEBUG ((DEBUG_INFO, "UsbConnectDriver: found a hub device\n"));\r
Status = mUsbHubApi.Init (UsbIf);\r
\r
} else {\r
//\r
if (UsbBusIsWantedUsbIO (UsbIf->Device->Bus, UsbIf)) {\r
OldTpl = UsbGetCurrentTpl ();\r
- DEBUG ((EFI_D_INFO, "UsbConnectDriver: TPL before connect is %d, %p\n", (UINT32)OldTpl, UsbIf->Handle));\r
+ DEBUG ((DEBUG_INFO, "UsbConnectDriver: TPL before connect is %d, %p\n", (UINT32)OldTpl, UsbIf->Handle));\r
\r
gBS->RestoreTPL (TPL_CALLBACK);\r
\r
Status = gBS->ConnectController (UsbIf->Handle, NULL, NULL, TRUE);\r
UsbIf->IsManaged = (BOOLEAN)!EFI_ERROR (Status);\r
\r
- DEBUG ((EFI_D_INFO, "UsbConnectDriver: TPL after connect is %d\n", (UINT32)UsbGetCurrentTpl()));\r
+ DEBUG ((DEBUG_INFO, "UsbConnectDriver: TPL after connect is %d\n", (UINT32)UsbGetCurrentTpl()));\r
ASSERT (UsbGetCurrentTpl () == TPL_CALLBACK);\r
\r
gBS->RaiseTPL (OldTpl);\r
IfDesc->ActiveIndex = Index;\r
\r
ASSERT (Setting != NULL);\r
- DEBUG ((EFI_D_INFO, "UsbSelectSetting: setting %d selected for interface %d\n",\r
+ DEBUG ((DEBUG_INFO, "UsbSelectSetting: setting %d selected for interface %d\n",\r
Alternate, Setting->Desc.InterfaceNumber));\r
\r
//\r
\r
Device->ActiveConfig = ConfigDesc;\r
\r
- DEBUG ((EFI_D_INFO, "UsbSelectConfig: config %d selected for device %d\n",\r
+ DEBUG ((DEBUG_INFO, "UsbSelectConfig: config %d selected for device %d\n",\r
ConfigValue, Device->Address));\r
\r
//\r
// or disconnect at CALLBACK.\r
//\r
OldTpl = UsbGetCurrentTpl ();\r
- DEBUG ((EFI_D_INFO, "UsbDisconnectDriver: old TPL is %d, %p\n", (UINT32)OldTpl, UsbIf->Handle));\r
+ DEBUG ((DEBUG_INFO, "UsbDisconnectDriver: old TPL is %d, %p\n", (UINT32)OldTpl, UsbIf->Handle));\r
\r
gBS->RestoreTPL (TPL_CALLBACK);\r
\r
UsbIf->IsManaged = FALSE;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbDisconnectDriver: TPL after disconnect is %d, %d\n", (UINT32)UsbGetCurrentTpl(), Status));\r
+ DEBUG (( DEBUG_INFO, "UsbDisconnectDriver: TPL after disconnect is %d, %d\n", (UINT32)UsbGetCurrentTpl(), Status));\r
ASSERT (UsbGetCurrentTpl () == TPL_CALLBACK);\r
\r
gBS->RaiseTPL (OldTpl);\r
} else {\r
Bus->Devices[Index]->DisconnectFail = TRUE;\r
ReturnStatus = Status;\r
- DEBUG ((EFI_D_INFO, "UsbRemoveDevice: failed to remove child %p at parent %p\n", Child, Device));\r
+ DEBUG ((DEBUG_INFO, "UsbRemoveDevice: failed to remove child %p at parent %p\n", Child, Device));\r
}\r
}\r
\r
Status = UsbRemoveConfig (Device);\r
\r
if (!EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_INFO, "UsbRemoveDevice: device %d removed\n", Device->Address));\r
+ DEBUG (( DEBUG_INFO, "UsbRemoveDevice: device %d removed\n", Device->Address));\r
\r
ASSERT (Device->Address < Bus->MaxDevices);\r
Bus->Devices[Device->Address] = NULL;\r
if (ResetIsNeeded) {\r
Status = HubApi->ResetPort (HubIf, Port);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumerateNewDev: failed to reset port %d - %r\n", Port, Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumerateNewDev: failed to reset port %d - %r\n", Port, Status));\r
\r
return Status;\r
}\r
- DEBUG (( EFI_D_INFO, "UsbEnumerateNewDev: hub port %d is reset\n", Port));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumerateNewDev: hub port %d is reset\n", Port));\r
} else {\r
- DEBUG (( EFI_D_INFO, "UsbEnumerateNewDev: hub port %d reset is skipped\n", Port));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumerateNewDev: hub port %d reset is skipped\n", Port));\r
}\r
\r
Child = UsbCreateDevice (HubIf, Port);\r
Status = HubApi->GetPortStatus (HubIf, Port, &PortState);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumerateNewDev: failed to get speed of port %d\n", Port));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumerateNewDev: failed to get speed of port %d\n", Port));\r
goto ON_ERROR;\r
}\r
\r
if (!USB_BIT_IS_SET (PortState.PortStatus, USB_PORT_STAT_CONNECTION)) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumerateNewDev: No device present at port %d\n", Port));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumerateNewDev: No device present at port %d\n", Port));\r
Status = EFI_NOT_FOUND;\r
goto ON_ERROR;\r
} else if (USB_BIT_IS_SET (PortState.PortStatus, USB_PORT_STAT_SUPER_SPEED)){\r
Child->MaxPacket0 = 8;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbEnumerateNewDev: device is of %d speed\n", Child->Speed));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumerateNewDev: device is of %d speed\n", Child->Speed));\r
\r
if (((Child->Speed == EFI_USB_SPEED_LOW) || (Child->Speed == EFI_USB_SPEED_FULL)) &&\r
(Parent->Speed == EFI_USB_SPEED_HIGH)) {\r
} else {\r
Child->Translator = Parent->Translator;\r
}\r
- DEBUG (( EFI_D_INFO, "UsbEnumerateNewDev: device uses translator (%d, %d)\n",\r
+ DEBUG (( DEBUG_INFO, "UsbEnumerateNewDev: device uses translator (%d, %d)\n",\r
Child->Translator.TranslatorHubAddress,\r
Child->Translator.TranslatorPortNumber));\r
\r
}\r
\r
if (Address >= Bus->MaxDevices) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumerateNewDev: address pool is full for port %d\n", Port));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumerateNewDev: address pool is full for port %d\n", Port));\r
\r
Status = EFI_ACCESS_DENIED;\r
goto ON_ERROR;\r
Bus->Devices[Address] = Child;\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumerateNewDev: failed to set device address - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumerateNewDev: failed to set device address - %r\n", Status));\r
goto ON_ERROR;\r
}\r
\r
gBS->Stall (USB_SET_DEVICE_ADDRESS_STALL);\r
\r
- DEBUG ((EFI_D_INFO, "UsbEnumerateNewDev: device is now ADDRESSED at %d\n", Address));\r
+ DEBUG ((DEBUG_INFO, "UsbEnumerateNewDev: device is now ADDRESSED at %d\n", Address));\r
\r
//\r
// Host sends a Get_Descriptor request to learn the max packet\r
Status = UsbGetMaxPacketSize0 (Child);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumerateNewDev: failed to get max packet for EP 0 - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumerateNewDev: failed to get max packet for EP 0 - %r\n", Status));\r
goto ON_ERROR;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbEnumerateNewDev: max packet size for EP 0 is %d\n", Child->MaxPacket0));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumerateNewDev: max packet size for EP 0 is %d\n", Child->MaxPacket0));\r
\r
//\r
// Host learns about the device's abilities by requesting device's\r
Status = UsbBuildDescTable (Child);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumerateNewDev: failed to build descriptor table - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumerateNewDev: failed to build descriptor table - %r\n", Status));\r
goto ON_ERROR;\r
}\r
\r
Status = UsbSetConfig (Child, Config);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumerateNewDev: failed to set configure %d - %r\n", Config, Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumerateNewDev: failed to set configure %d - %r\n", Config, Status));\r
goto ON_ERROR;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbEnumerateNewDev: device %d is now in CONFIGED state\n", Address));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumerateNewDev: device %d is now in CONFIGED state\n", Address));\r
\r
//\r
// Host assigns and loads a device driver.\r
Status = UsbSelectConfig (Child, Config);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumerateNewDev: failed to create interfaces - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumerateNewDev: failed to create interfaces - %r\n", Status));\r
goto ON_ERROR;\r
}\r
\r
Status = HubApi->GetPortStatus (HubIf, Port, &PortState);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbEnumeratePort: failed to get state of port %d\n", Port));\r
+ DEBUG ((DEBUG_ERROR, "UsbEnumeratePort: failed to get state of port %d\n", Port));\r
return Status;\r
}\r
\r
return EFI_SUCCESS;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbEnumeratePort: port %d state - %02x, change - %02x on %p\n",\r
+ DEBUG (( DEBUG_INFO, "UsbEnumeratePort: port %d state - %02x, change - %02x on %p\n",\r
Port, PortState.PortStatus, PortState.PortChangeStatus, HubIf));\r
\r
//\r
// which probably is caused by short circuit. It has to wait system hardware\r
// to perform recovery.\r
//\r
- DEBUG (( EFI_D_ERROR, "UsbEnumeratePort: Critical Over Current\n", Port));\r
+ DEBUG (( DEBUG_ERROR, "UsbEnumeratePort: Critical Over Current\n", Port));\r
return EFI_DEVICE_ERROR;\r
\r
}\r
// over current. As a result, all ports are nearly power-off, so\r
// it's necessary to detach and enumerate all ports again.\r
//\r
- DEBUG (( EFI_D_ERROR, "UsbEnumeratePort: 2.0 device Recovery Over Current\n", Port));\r
+ DEBUG (( DEBUG_ERROR, "UsbEnumeratePort: 2.0 device Recovery Over Current\n", Port));\r
}\r
\r
if (USB_BIT_IS_SET (PortState.PortChangeStatus, USB_PORT_STAT_C_ENABLE)) {\r
// on 2.0 roothub does. When over-current has influence on 1.1 device, the port\r
// would be disabled, so it's also necessary to detach and enumerate again.\r
//\r
- DEBUG (( EFI_D_ERROR, "UsbEnumeratePort: 1.1 device Recovery Over Current\n", Port));\r
+ DEBUG (( DEBUG_ERROR, "UsbEnumeratePort: 1.1 device Recovery Over Current\n", Port));\r
}\r
\r
if (USB_BIT_IS_SET (PortState.PortChangeStatus, USB_PORT_STAT_C_CONNECTION)) {\r
// Case4:\r
// Device connected or disconnected normally.\r
//\r
- DEBUG ((EFI_D_INFO, "UsbEnumeratePort: Device Connect/Disconnect Normally\n", Port));\r
+ DEBUG ((DEBUG_INFO, "UsbEnumeratePort: Device Connect/Disconnect Normally\n", Port));\r
}\r
\r
//\r
Child = UsbFindChild (HubIf, Port);\r
\r
if (Child != NULL) {\r
- DEBUG (( EFI_D_INFO, "UsbEnumeratePort: device at port %d removed from root hub %p\n", Port, HubIf));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumeratePort: device at port %d removed from root hub %p\n", Port, HubIf));\r
UsbRemoveDevice (Child);\r
}\r
\r
//\r
// Now, new device connected, enumerate and configure the device\r
//\r
- DEBUG (( EFI_D_INFO, "UsbEnumeratePort: new device connected at port %d\n", Port));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumeratePort: new device connected at port %d\n", Port));\r
if (USB_BIT_IS_SET (PortState.PortChangeStatus, USB_PORT_STAT_C_RESET)) {\r
Status = UsbEnumerateNewDev (HubIf, Port, FALSE);\r
} else {\r
}\r
\r
} else {\r
- DEBUG (( EFI_D_INFO, "UsbEnumeratePort: device disconnected event on port %d\n", Port));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumeratePort: device disconnected event on port %d\n", Port));\r
}\r
\r
HubApi->ClearPortChange (HubIf, Port);\r
for (Index = 0; Index < HubIf->NumOfPort; Index++) {\r
Child = UsbFindChild (HubIf, Index);\r
if ((Child != NULL) && (Child->DisconnectFail == TRUE)) {\r
- DEBUG (( EFI_D_INFO, "UsbEnumeratePort: The device disconnect fails at port %d from hub %p, try again\n", Index, HubIf));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumeratePort: The device disconnect fails at port %d from hub %p, try again\n", Index, HubIf));\r
UsbRemoveDevice (Child);\r
}\r
}\r
for (Index = 0; Index < RootHub->NumOfPort; Index++) {\r
Child = UsbFindChild (RootHub, Index);\r
if ((Child != NULL) && (Child->DisconnectFail == TRUE)) {\r
- DEBUG (( EFI_D_INFO, "UsbEnumeratePort: The device disconnect fails at port %d from root hub %p, try again\n", Index, RootHub));\r
+ DEBUG (( DEBUG_INFO, "UsbEnumeratePort: The device disconnect fails at port %d from root hub %p, try again\n", Index, RootHub));\r
UsbRemoveDevice (Child);\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbOnHubInterrupt: failed to remove async transfer - %r\n", Status));\r
+ DEBUG (( DEBUG_ERROR, "UsbOnHubInterrupt: failed to remove async transfer - %r\n", Status));\r
return Status;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbOnHubInterrupt: failed to submit new async transfer - %r\n", Status));\r
+ DEBUG (( DEBUG_ERROR, "UsbOnHubInterrupt: failed to submit new async transfer - %r\n", Status));\r
}\r
\r
return Status;\r
}\r
\r
if (Index == NumEndpoints) {\r
- DEBUG (( EFI_D_ERROR, "UsbHubInit: no interrupt endpoint found for hub %d\n", HubDev->Address));\r
+ DEBUG (( DEBUG_ERROR, "UsbHubInit: no interrupt endpoint found for hub %d\n", HubDev->Address));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
Status = UsbHubReadDesc (HubDev, HubDesc);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbHubInit: failed to read HUB descriptor %r\n", Status));\r
+ DEBUG (( DEBUG_ERROR, "UsbHubInit: failed to read HUB descriptor %r\n", Status));\r
return Status;\r
}\r
\r
HubIf->NumOfPort = HubDesc->NumPorts;\r
\r
- DEBUG (( EFI_D_INFO, "UsbHubInit: hub %d has %d ports\n", HubDev->Address,HubIf->NumOfPort));\r
+ DEBUG (( DEBUG_INFO, "UsbHubInit: hub %d has %d ports\n", HubDev->Address,HubIf->NumOfPort));\r
\r
//\r
// OK, set IsHub to TRUE. Now usb bus can handle this device\r
\r
if (HubIf->Device->Speed == EFI_USB_SPEED_SUPER) {\r
Depth = (UINT16)(HubIf->Device->Tier - 1);\r
- DEBUG ((EFI_D_INFO, "UsbHubInit: Set Hub Depth as 0x%x\n", Depth));\r
+ DEBUG ((DEBUG_INFO, "UsbHubInit: Set Hub Depth as 0x%x\n", Depth));\r
UsbHubCtrlSetHubDepth (HubIf->Device, Depth);\r
\r
for (Index = 0; Index < HubDesc->NumPorts; Index++) {\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbHubInit: failed to create signal for hub %d - %r\n",\r
+ DEBUG (( DEBUG_ERROR, "UsbHubInit: failed to create signal for hub %d - %r\n",\r
HubDev->Address, Status));\r
\r
return Status;\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbHubInit: failed to queue interrupt transfer for hub %d - %r\n",\r
+ DEBUG (( DEBUG_ERROR, "UsbHubInit: failed to queue interrupt transfer for hub %d - %r\n",\r
HubDev->Address, Status));\r
\r
gBS->CloseEvent (HubIf->HubNotify);\r
return Status;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbHubInit: hub %d initialized\n", HubDev->Address));\r
+ DEBUG (( DEBUG_INFO, "UsbHubInit: hub %d initialized\n", HubDev->Address));\r
return Status;\r
}\r
\r
HubIf->HubEp = NULL;\r
HubIf->HubNotify = NULL;\r
\r
- DEBUG (( EFI_D_INFO, "UsbHubRelease: hub device %d released\n", HubIf->Device->Address));\r
+ DEBUG (( DEBUG_INFO, "UsbHubRelease: hub device %d released\n", HubIf->Device->Address));\r
return EFI_SUCCESS;\r
}\r
\r
return Status;\r
}\r
\r
- DEBUG (( EFI_D_INFO, "UsbRootHubInit: root hub %p - max speed %d, %d ports\n",\r
+ DEBUG (( DEBUG_INFO, "UsbRootHubInit: root hub %p - max speed %d, %d ports\n",\r
HubIf, MaxSpeed, NumOfPort));\r
\r
HubIf->IsHub = TRUE;\r
Status = UsbHcSetRootHubPortFeature (Bus, Port, EfiUsbPortReset);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbRootHubResetPort: failed to start reset on port %d\n", Port));\r
+ DEBUG (( DEBUG_ERROR, "UsbRootHubResetPort: failed to start reset on port %d\n", Port));\r
return Status;\r
}\r
\r
Status = UsbHcClearRootHubPortFeature (Bus, Port, EfiUsbPortReset);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbRootHubResetPort: failed to clear reset on port %d\n", Port));\r
+ DEBUG (( DEBUG_ERROR, "UsbRootHubResetPort: failed to clear reset on port %d\n", Port));\r
return Status;\r
}\r
\r
}\r
\r
if (Index == USB_WAIT_PORT_STS_CHANGE_LOOP) {\r
- DEBUG ((EFI_D_ERROR, "UsbRootHubResetPort: reset not finished in time on port %d\n", Port));\r
+ DEBUG ((DEBUG_ERROR, "UsbRootHubResetPort: reset not finished in time on port %d\n", Port));\r
return EFI_TIMEOUT;\r
}\r
\r
// automatically enable the port, we need to enable it manually.\r
//\r
if (RootIf->MaxSpeed == EFI_USB_SPEED_HIGH) {\r
- DEBUG (( EFI_D_ERROR, "UsbRootHubResetPort: release low/full speed device (%d) to UHCI\n", Port));\r
+ DEBUG (( DEBUG_ERROR, "UsbRootHubResetPort: release low/full speed device (%d) to UHCI\n", Port));\r
\r
UsbRootHubSetPortFeature (RootIf, Port, EfiUsbPortOwner);\r
return EFI_NOT_FOUND;\r
Status = UsbRootHubSetPortFeature (RootIf, Port, EfiUsbPortEnable);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "UsbRootHubResetPort: failed to enable port %d for UHCI\n", Port));\r
+ DEBUG (( DEBUG_ERROR, "UsbRootHubResetPort: failed to enable port %d for UHCI\n", Port));\r
return Status;\r
}\r
\r
IN USB_INTERFACE *HubIf\r
)\r
{\r
- DEBUG (( EFI_D_INFO, "UsbRootHubRelease: root hub released for hub %p\n", HubIf));\r
+ DEBUG (( DEBUG_INFO, "UsbRootHubRelease: root hub released for hub %p\n", HubIf));\r
\r
gBS->SetTimer (HubIf->HubNotify, TimerCancel, USB_ROOTHUB_POLL_INTERVAL);\r
gBS->CloseEvent (HubIf->HubNotify);\r
//\r
// Recursively connect the wanted Usb Io handle\r
//\r
- DEBUG ((EFI_D_INFO, "UsbBusRecursivelyConnectWantedUsbIo: TPL before connect is %d\n", (UINT32)UsbGetCurrentTpl ()));\r
+ DEBUG ((DEBUG_INFO, "UsbBusRecursivelyConnectWantedUsbIo: TPL before connect is %d\n", (UINT32)UsbGetCurrentTpl ()));\r
Status = gBS->ConnectController (UsbIf->Handle, NULL, NULL, TRUE);\r
UsbIf->IsManaged = (BOOLEAN)!EFI_ERROR (Status);\r
- DEBUG ((EFI_D_INFO, "UsbBusRecursivelyConnectWantedUsbIo: TPL after connect is %d\n", (UINT32)UsbGetCurrentTpl()));\r
+ DEBUG ((DEBUG_INFO, "UsbBusRecursivelyConnectWantedUsbIo: TPL after connect is %d\n", (UINT32)UsbGetCurrentTpl()));\r
}\r
}\r
}\r
\r
return EFI_SUCCESS;\r
}\r
-\r
PeiUsbDevice->DownStreamPortNo = HubDescriptor->NbrPorts;\r
\r
if (PeiUsbDevice->DeviceSpeed == EFI_USB_SPEED_SUPER) {\r
- DEBUG ((EFI_D_INFO, "PeiDoHubConfig: Set Hub Depth as 0x%x\n", PeiUsbDevice->Tier));\r
+ DEBUG ((DEBUG_INFO, "PeiDoHubConfig: Set Hub Depth as 0x%x\n", PeiUsbDevice->Tier));\r
PeiUsbHubCtrlSetHubDepth (\r
PeiServices,\r
PeiUsbDevice,\r
EfiUsbPortPower\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG (( EFI_D_ERROR, "PeiDoHubConfig: PeiHubSetPortFeature EfiUsbPortPower failed %x\n", Index));\r
+ DEBUG (( DEBUG_ERROR, "PeiDoHubConfig: PeiHubSetPortFeature EfiUsbPortPower failed %x\n", Index));\r
continue;\r
}\r
}\r
\r
- DEBUG (( EFI_D_INFO, "PeiDoHubConfig: HubDescriptor.PwrOn2PwrGood: 0x%x\n", HubDescriptor->PwrOn2PwrGood));\r
+ DEBUG (( DEBUG_INFO, "PeiDoHubConfig: HubDescriptor.PwrOn2PwrGood: 0x%x\n", HubDescriptor->PwrOn2PwrGood));\r
if (HubDescriptor->PwrOn2PwrGood > 0) {\r
MicroSecondDelay (HubDescriptor->PwrOn2PwrGood * USB_SET_PORT_POWER_STALL);\r
}\r
}\r
\r
if (Index == USB_WAIT_PORT_STS_CHANGE_LOOP) {\r
- DEBUG ((EFI_D_ERROR, "PeiResetHubPort: reset not finished in time on port %d\n", PortNum));\r
+ DEBUG ((DEBUG_ERROR, "PeiResetHubPort: reset not finished in time on port %d\n", PortNum));\r
return;\r
}\r
\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "PeiUsbControlTransfer: %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "PeiUsbControlTransfer: %r\n", Status));\r
return Status;\r
}\r
\r
PeiUsbDev->DataToggle = (UINT16) (PeiUsbDev->DataToggle ^ (1 << EndpointIndex));\r
}\r
\r
- DEBUG ((EFI_D_INFO, "PeiUsbBulkTransfer: %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "PeiUsbBulkTransfer: %r\n", Status));\r
return Status;\r
}\r
\r
\r
UsbIoPpi = &PeiUsbDevice->UsbIoPpi;\r
\r
- DEBUG ((EFI_D_INFO, "PeiHubEnumeration: DownStreamPortNo: %x\n", PeiUsbDevice->DownStreamPortNo));\r
+ DEBUG ((DEBUG_INFO, "PeiHubEnumeration: DownStreamPortNo: %x\n", PeiUsbDevice->DownStreamPortNo));\r
\r
for (Index = 0; Index < PeiUsbDevice->DownStreamPortNo; Index++) {\r
\r
continue;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "USB Status --- Port: %x ConnectChange[%04x] Status[%04x]\n", Index, PortStatus.PortChangeStatus, PortStatus.PortStatus));\r
+ DEBUG ((DEBUG_INFO, "USB Status --- Port: %x ConnectChange[%04x] Status[%04x]\n", Index, PortStatus.PortChangeStatus, PortStatus.PortStatus));\r
//\r
// Only handle connection/enable/overcurrent/reset change.\r
//\r
}\r
\r
NewPeiUsbDevice->DeviceSpeed = (UINT8) PeiUsbGetDeviceSpeed (PortStatus.PortStatus);\r
- DEBUG ((EFI_D_INFO, "Device Speed =%d\n", PeiUsbDevice->DeviceSpeed));\r
+ DEBUG ((DEBUG_INFO, "Device Speed =%d\n", PeiUsbDevice->DeviceSpeed));\r
\r
if (USB_BIT_IS_SET (PortStatus.PortStatus, USB_PORT_STAT_SUPER_SPEED)){\r
NewPeiUsbDevice->MaxPacketSize0 = 512;\r
if (EFI_ERROR (Status)) {\r
continue;\r
}\r
- DEBUG ((EFI_D_INFO, "PeiHubEnumeration: PeiConfigureUsbDevice Success\n"));\r
+ DEBUG ((DEBUG_INFO, "PeiHubEnumeration: PeiConfigureUsbDevice Success\n"));\r
\r
Status = PeiServicesInstallPpi (&NewPeiUsbDevice->UsbIoPpiList);\r
\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "PeiUsbEnumeration: NumOfRootPort: %x\n", NumOfRootPort));\r
+ DEBUG ((DEBUG_INFO, "PeiUsbEnumeration: NumOfRootPort: %x\n", NumOfRootPort));\r
\r
for (Index = 0; Index < NumOfRootPort; Index++) {\r
//\r
&PortStatus\r
);\r
}\r
- DEBUG ((EFI_D_INFO, "USB Status --- Port: %x ConnectChange[%04x] Status[%04x]\n", Index, PortStatus.PortChangeStatus, PortStatus.PortStatus));\r
+ DEBUG ((DEBUG_INFO, "USB Status --- Port: %x ConnectChange[%04x] Status[%04x]\n", Index, PortStatus.PortChangeStatus, PortStatus.PortStatus));\r
//\r
// Only handle connection/enable/overcurrent/reset change.\r
//\r
}\r
\r
PeiUsbDevice->DeviceSpeed = (UINT8) PeiUsbGetDeviceSpeed (PortStatus.PortStatus);\r
- DEBUG ((EFI_D_INFO, "Device Speed =%d\n", PeiUsbDevice->DeviceSpeed));\r
+ DEBUG ((DEBUG_INFO, "Device Speed =%d\n", PeiUsbDevice->DeviceSpeed));\r
\r
if (USB_BIT_IS_SET (PortStatus.PortStatus, USB_PORT_STAT_SUPER_SPEED)){\r
PeiUsbDevice->MaxPacketSize0 = 512;\r
if (EFI_ERROR (Status)) {\r
continue;\r
}\r
- DEBUG ((EFI_D_INFO, "PeiUsbEnumeration: PeiConfigureUsbDevice Success\n"));\r
+ DEBUG ((DEBUG_INFO, "PeiUsbEnumeration: PeiConfigureUsbDevice Success\n"));\r
\r
Status = PeiServicesInstallPpi (&PeiUsbDevice->UsbIoPpiList);\r
\r
);\r
\r
if (!EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "PeiUsbGet Device Descriptor the %d time Success\n", Retry));\r
+ DEBUG ((DEBUG_INFO, "PeiUsbGet Device Descriptor the %d time Success\n", Retry));\r
break;\r
}\r
}\r
\r
if (Retry == 3) {\r
- DEBUG ((EFI_D_ERROR, "PeiUsbGet Device Descriptor fail: %x %r\n", Retry, Status));\r
+ DEBUG ((DEBUG_ERROR, "PeiUsbGet Device Descriptor fail: %x %r\n", Retry, Status));\r
return Status;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "PeiUsbSetDeviceAddress Failed: %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "PeiUsbSetDeviceAddress Failed: %r\n", Status));\r
return Status;\r
}\r
MicroSecondDelay (USB_SET_DEVICE_ADDRESS_STALL);\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "PeiUsbGetDescriptor First Failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "PeiUsbGetDescriptor First Failed\n"));\r
return Status;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "PeiUsbGet Config Descriptor First Failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "PeiUsbGet Config Descriptor First Failed\n"));\r
return Status;\r
}\r
MicroSecondDelay (USB_GET_CONFIG_DESCRIPTOR_STALL);\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "PeiUsbGet Config Descriptor all Failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "PeiUsbGet Config Descriptor all Failed\n"));\r
return Status;\r
}\r
//\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SetRootHubPortFeature EfiUsbPortReset Failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "SetRootHubPortFeature EfiUsbPortReset Failed\n"));\r
return;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "ClearRootHubPortFeature EfiUsbPortReset Failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "ClearRootHubPortFeature EfiUsbPortReset Failed\n"));\r
return;\r
}\r
\r
}\r
\r
if (Index == USB_WAIT_PORT_STS_CHANGE_LOOP) {\r
- DEBUG ((EFI_D_ERROR, "ResetRootPort: reset not finished in time on port %d\n", PortNum));\r
+ DEBUG ((DEBUG_ERROR, "ResetRootPort: reset not finished in time on port %d\n", PortNum));\r
return;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SetRootHubPortFeature EfiUsbPortReset Failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "SetRootHubPortFeature EfiUsbPortReset Failed\n"));\r
return;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "ClearRootHubPortFeature EfiUsbPortReset Failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "ClearRootHubPortFeature EfiUsbPortReset Failed\n"));\r
return;\r
}\r
\r
}\r
\r
if (Index == USB_WAIT_PORT_STS_CHANGE_LOOP) {\r
- DEBUG ((EFI_D_ERROR, "ResetRootPort: reset not finished in time on port %d\n", PortNum));\r
+ DEBUG ((DEBUG_ERROR, "ResetRootPort: reset not finished in time on port %d\n", PortNum));\r
return;\r
}\r
\r
}\r
return;\r
}\r
-\r
-\r
&CmdResult\r
);\r
if (EFI_ERROR (Status) || CmdResult != USB_MASS_CMD_SUCCESS) {\r
- DEBUG ((EFI_D_ERROR, "UsbBootRequestSense: (%r) CmdResult=0x%x\n", Status, CmdResult));\r
+ DEBUG ((DEBUG_ERROR, "UsbBootRequestSense: (%r) CmdResult=0x%x\n", Status, CmdResult));\r
if (!EFI_ERROR (Status)) {\r
Status = EFI_DEVICE_ERROR;\r
}\r
break;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "UsbBootRequestSense: (%r) with error code (%x) sense key %x/%x/%x\n",\r
+ DEBUG ((DEBUG_INFO, "UsbBootRequestSense: (%r) with error code (%x) sense key %x/%x/%x\n",\r
Status,\r
SenseData.ErrorCode,\r
USB_BOOT_SENSE_KEY (SenseData.SenseKey),\r
);\r
\r
if (Status == EFI_TIMEOUT) {\r
- DEBUG ((EFI_D_ERROR, "UsbBootExecCmd: %r to Exec 0x%x Cmd\n", Status, *(UINT8 *)Cmd));\r
+ DEBUG ((DEBUG_ERROR, "UsbBootExecCmd: %r to Exec 0x%x Cmd\n", Status, *(UINT8 *)Cmd));\r
return EFI_TIMEOUT;\r
}\r
\r
//\r
// If command execution failed, then retrieve error info via sense request.\r
//\r
- DEBUG ((EFI_D_ERROR, "UsbBootExecCmd: %r to Exec 0x%x Cmd (Result = %x)\n", Status, *(UINT8 *)Cmd, CmdResult));\r
+ DEBUG ((DEBUG_ERROR, "UsbBootExecCmd: %r to Exec 0x%x Cmd (Result = %x)\n", Status, *(UINT8 *)Cmd, CmdResult));\r
return UsbBootRequestSense (UsbMass);\r
}\r
\r
\r
Status = UsbBootInquiry (UsbMass);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBootGetParams: UsbBootInquiry (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBootGetParams: UsbBootInquiry (%r)\n", Status));\r
return Status;\r
}\r
\r
(UsbMass->Pdt != USB_PDT_CDROM) &&\r
(UsbMass->Pdt != USB_PDT_OPTICAL) &&\r
(UsbMass->Pdt != USB_PDT_SIMPLE_DIRECT)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBootGetParams: Found an unsupported peripheral type[%d]\n", UsbMass->Pdt));\r
+ DEBUG ((DEBUG_ERROR, "UsbBootGetParams: Found an unsupported peripheral type[%d]\n", UsbMass->Pdt));\r
return EFI_UNSUPPORTED;\r
}\r
\r
\r
Status = UsbBootIsUnitReady (UsbMass);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBootDetectMedia: UsbBootIsUnitReady (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBootDetectMedia: UsbBootIsUnitReady (%r)\n", Status));\r
}\r
\r
//\r
\r
Status = UsbBootReadCapacity (UsbMass);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBootDetectMedia: UsbBootReadCapacity (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBootDetectMedia: UsbBootReadCapacity (%r)\n", Status));\r
}\r
}\r
\r
);\r
if (EFI_ERROR (Status)) {\r
if (USB_IS_ERROR (Result, EFI_USB_ERR_STALL)) {\r
- DEBUG ((EFI_D_INFO, "UsbBotDataTransfer: (%r)\n", Status));\r
- DEBUG ((EFI_D_INFO, "UsbBotDataTransfer: DataIn Stall\n"));\r
+ DEBUG ((DEBUG_INFO, "UsbBotDataTransfer: (%r)\n", Status));\r
+ DEBUG ((DEBUG_INFO, "UsbBotDataTransfer: DataIn Stall\n"));\r
UsbClearEndpointStall (UsbBot->UsbIo, Endpoint->EndpointAddress);\r
} else if (USB_IS_ERROR (Result, EFI_USB_ERR_NAK)) {\r
Status = EFI_NOT_READY;\r
} else {\r
- DEBUG ((EFI_D_ERROR, "UsbBotDataTransfer: (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBotDataTransfer: (%r)\n", Status));\r
}\r
if(Status == EFI_TIMEOUT){\r
UsbBotResetDevice(UsbBot, FALSE);\r
//\r
Status = UsbBotSendCommand (UsbBot, Cmd, CmdLen, DataDir, DataLen, Lun);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBotExecCommand: UsbBotSendCommand (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBotExecCommand: UsbBotSendCommand (%r)\n", Status));\r
return Status;\r
}\r
\r
//\r
Status = UsbBotGetStatus (UsbBot, DataLen, &Result);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbBotExecCommand: UsbBotGetStatus (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbBotExecCommand: UsbBotGetStatus (%r)\n", Status));\r
return Status;\r
}\r
\r
FreePool (Context);\r
return EFI_SUCCESS;\r
}\r
-\r
Status = UsbCbiSendCommand (UsbCbi, Cmd, CmdLen, Timeout);\r
if (EFI_ERROR (Status)) {\r
gBS->Stall(10 * USB_MASS_1_MILLISECOND);\r
- DEBUG ((EFI_D_ERROR, "UsbCbiExecCommand: UsbCbiSendCommand (%r)\n",Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbCbiExecCommand: UsbCbiSendCommand (%r)\n",Status));\r
return Status;\r
}\r
\r
\r
Status = UsbCbiDataTransfer (UsbCbi, DataDir, Data, &TransLen, Timeout);\r
if (UsbCbi->InterruptEndpoint == NULL) {\r
- DEBUG ((EFI_D_ERROR, "UsbCbiExecCommand: UsbCbiDataTransfer (%r)\n",Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbCbiExecCommand: UsbCbiDataTransfer (%r)\n",Status));\r
return Status;\r
}\r
\r
//\r
Status = UsbCbiGetStatus (UsbCbi, Timeout, &Result);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbCbiExecCommand: UsbCbiGetStatus (%r)\n",Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbCbiExecCommand: UsbCbiGetStatus (%r)\n",Status));\r
return Status;\r
}\r
\r
}\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbMassReadBlocks: UsbBootReadBlocks (%r) -> Reset\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbMassReadBlocks: UsbBootReadBlocks (%r) -> Reset\n", Status));\r
UsbMassReset (This, TRUE);\r
}\r
\r
}\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbMassWriteBlocks: UsbBootWriteBlocks (%r) -> Reset\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbMassWriteBlocks: UsbBootWriteBlocks (%r) -> Reset\n", Status));\r
UsbMassReset (This, TRUE);\r
}\r
\r
\r
for (Index = 0; Index <= MaxLun; Index++) {\r
\r
- DEBUG ((EFI_D_INFO, "UsbMassInitMultiLun: Start to initialize No.%d logic unit\n", Index));\r
+ DEBUG ((DEBUG_INFO, "UsbMassInitMultiLun: Start to initialize No.%d logic unit\n", Index));\r
\r
UsbIo = NULL;\r
UsbMass = AllocateZeroPool (sizeof (USB_MASS_DEVICE));\r
//\r
Status = UsbMassInitMedia (UsbMass);\r
if ((EFI_ERROR (Status)) && (Status != EFI_NO_MEDIA)) {\r
- DEBUG ((EFI_D_ERROR, "UsbMassInitMultiLun: UsbMassInitMedia (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbMassInitMultiLun: UsbMassInitMedia (%r)\n", Status));\r
FreePool (UsbMass);\r
continue;\r
}\r
UsbMass->DevicePath = AppendDevicePathNode (DevicePath, &LunNode.Header);\r
\r
if (UsbMass->DevicePath == NULL) {\r
- DEBUG ((EFI_D_ERROR, "UsbMassInitMultiLun: failed to create device logic unit device path\n"));\r
+ DEBUG ((DEBUG_ERROR, "UsbMassInitMultiLun: failed to create device logic unit device path\n"));\r
Status = EFI_OUT_OF_RESOURCES;\r
FreePool (UsbMass);\r
continue;\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbMassInitMultiLun: InstallMultipleProtocolInterfaces (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbMassInitMultiLun: InstallMultipleProtocolInterfaces (%r)\n", Status));\r
FreePool (UsbMass->DevicePath);\r
FreePool (UsbMass);\r
continue;\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbMassInitMultiLun: OpenUsbIoProtocol By Child (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbMassInitMultiLun: OpenUsbIoProtocol By Child (%r)\n", Status));\r
gBS->UninstallMultipleProtocolInterfaces (\r
UsbMass->Controller,\r
&gEfiDevicePathProtocolGuid,\r
continue;\r
}\r
ReturnStatus = EFI_SUCCESS;\r
- DEBUG ((EFI_D_INFO, "UsbMassInitMultiLun: Success to initialize No.%d logic unit\n", Index));\r
+ DEBUG ((DEBUG_INFO, "UsbMassInitMultiLun: Success to initialize No.%d logic unit\n", Index));\r
}\r
\r
return ReturnStatus;\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "UsbMassInitNonLun: OpenUsbIoProtocol By Driver (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbMassInitNonLun: OpenUsbIoProtocol By Driver (%r)\n", Status));\r
goto ON_ERROR;\r
}\r
\r
//\r
Status = UsbMassInitMedia (UsbMass);\r
if ((EFI_ERROR (Status)) && (Status != EFI_NO_MEDIA)) {\r
- DEBUG ((EFI_D_ERROR, "UsbMassInitNonLun: UsbMassInitMedia (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "UsbMassInitNonLun: UsbMassInitMedia (%r)\n", Status));\r
goto ON_ERROR;\r
}\r
\r
Status = UsbMassInitTransport (This, Controller, &Transport, &Context, &MaxLun);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "USBMassDriverBindingStart: UsbMassInitTransport (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "USBMassDriverBindingStart: UsbMassInitTransport (%r)\n", Status));\r
goto Exit;\r
}\r
if (MaxLun == 0) {\r
//\r
Status = UsbMassInitNonLun (This, Controller, Transport, Context);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "USBMassDriverBindingStart: UsbMassInitNonLun (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "USBMassDriverBindingStart: UsbMassInitNonLun (%r)\n", Status));\r
}\r
} else {\r
//\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "USBMassDriverBindingStart: OpenDevicePathProtocol By Driver (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "USBMassDriverBindingStart: OpenDevicePathProtocol By Driver (%r)\n", Status));\r
goto Exit;\r
}\r
\r
);\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "USBMassDriverBindingStart: OpenUsbIoProtocol By Driver (%r)\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "USBMassDriverBindingStart: OpenUsbIoProtocol By Driver (%r)\n", Status));\r
gBS->CloseProtocol (\r
Controller,\r
&gEfiDevicePathProtocolGuid,\r
This->DriverBindingHandle,\r
Controller\r
);\r
- DEBUG ((EFI_D_ERROR, "USBMassDriverBindingStart: UsbMassInitMultiLun (%r) with Maxlun=%d\n", Status, MaxLun));\r
+ DEBUG ((DEBUG_ERROR, "USBMassDriverBindingStart: UsbMassInitMultiLun (%r) with Maxlun=%d\n", Status, MaxLun));\r
}\r
}\r
Exit:\r
This->DriverBindingHandle,\r
Controller\r
);\r
- DEBUG ((EFI_D_INFO, "Success to stop multi-lun root handle\n"));\r
+ DEBUG ((DEBUG_INFO, "Success to stop multi-lun root handle\n"));\r
return EFI_SUCCESS;\r
}\r
\r
UsbMass->Transport->CleanUp (UsbMass->Context);\r
FreePool (UsbMass);\r
\r
- DEBUG ((EFI_D_INFO, "Success to stop non-multi-lun root handle\n"));\r
+ DEBUG ((DEBUG_INFO, "Success to stop non-multi-lun root handle\n"));\r
return EFI_SUCCESS;\r
}\r
\r
);\r
if (EFI_ERROR (Status)) {\r
AllChildrenStopped = FALSE;\r
- DEBUG ((EFI_D_ERROR, "Fail to stop No.%d multi-lun child handle when opening blockio\n", (UINT32)Index));\r
+ DEBUG ((DEBUG_ERROR, "Fail to stop No.%d multi-lun child handle when opening blockio\n", (UINT32)Index));\r
continue;\r
}\r
\r
// Fail to uninstall Block I/O Protocol and Device Path Protocol, so re-open USB I/O Protocol by child.\r
//\r
AllChildrenStopped = FALSE;\r
- DEBUG ((EFI_D_ERROR, "Fail to stop No.%d multi-lun child handle when uninstalling blockio and devicepath\n", (UINT32)Index));\r
+ DEBUG ((DEBUG_ERROR, "Fail to stop No.%d multi-lun child handle when uninstalling blockio and devicepath\n", (UINT32)Index));\r
\r
gBS->OpenProtocol (\r
Controller,\r
return EFI_DEVICE_ERROR;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Success to stop all %d multi-lun children handles\n", (UINT32) NumberOfChildren));\r
+ DEBUG ((DEBUG_INFO, "Success to stop all %d multi-lun children handles\n", (UINT32) NumberOfChildren));\r
return EFI_SUCCESS;\r
}\r
\r
for (Link = mFvHandleList.ForwardLink; Link != &mFvHandleList; Link = Link->ForwardLink) {\r
KnownHandle = CR(Link, KNOWN_HANDLE, Link, KNOWN_HANDLE_SIGNATURE);\r
if (CompareGuid (&FvNameGuid, &KnownHandle->FvNameGuid)) {\r
- DEBUG ((EFI_D_ERROR, "FvImage on FvHandle %p and %p has the same FvNameGuid %g.\n", FvHandle, KnownHandle->Handle, &FvNameGuid));\r
+ DEBUG ((DEBUG_ERROR, "FvImage on FvHandle %p and %p has the same FvNameGuid %g.\n", FvHandle, KnownHandle->Handle, &FvNameGuid));\r
return NULL;\r
}\r
}\r
\r
OldTpl = gEfiCurrentTpl;\r
if (OldTpl > NewTpl) {\r
- DEBUG ((EFI_D_ERROR, "FATAL ERROR - RaiseTpl with OldTpl(0x%x) > NewTpl(0x%x)\n", OldTpl, NewTpl));\r
+ DEBUG ((DEBUG_ERROR, "FATAL ERROR - RaiseTpl with OldTpl(0x%x) > NewTpl(0x%x)\n", OldTpl, NewTpl));\r
ASSERT (FALSE);\r
}\r
ASSERT (VALID_TPL (NewTpl));\r
\r
OldTpl = gEfiCurrentTpl;\r
if (NewTpl > OldTpl) {\r
- DEBUG ((EFI_D_ERROR, "FATAL ERROR - RestoreTpl with NewTpl(0x%x) > OldTpl(0x%x)\n", NewTpl, OldTpl));\r
+ DEBUG ((DEBUG_ERROR, "FATAL ERROR - RestoreTpl with NewTpl(0x%x) > OldTpl(0x%x)\n", NewTpl, OldTpl));\r
ASSERT (FALSE);\r
}\r
ASSERT (VALID_TPL (NewTpl));\r
(FileState == EFI_FILE_HEADER_CONSTRUCTION)) {\r
if (IS_FFS_FILE2 (FfsHeader)) {\r
if (!FvDevice->IsFfs3Fv) {\r
- DEBUG ((EFI_D_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsHeader->Name));\r
+ DEBUG ((DEBUG_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsHeader->Name));\r
}\r
FfsHeader = (EFI_FFS_FILE_HEADER *) ((UINT8 *) FfsHeader + sizeof (EFI_FFS_FILE_HEADER2));\r
} else {\r
if (IS_FFS_FILE2 (CacheFfsHeader)) {\r
ASSERT (FFS_FILE2_SIZE (CacheFfsHeader) > 0x00FFFFFF);\r
if (!FvDevice->IsFfs3Fv) {\r
- DEBUG ((EFI_D_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &CacheFfsHeader->Name));\r
+ DEBUG ((DEBUG_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &CacheFfsHeader->Name));\r
FfsHeader = (EFI_FFS_FILE_HEADER *) ((UINT8 *) FfsHeader + FFS_FILE2_SIZE (CacheFfsHeader));\r
//\r
// Adjust pointer to the next 8-byte aligned boundary.\r
);\r
return EFI_SUCCESS;\r
}\r
-\r
-\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "CoreInitializeMemoryServices:\n"));\r
- DEBUG ((EFI_D_INFO, " BaseAddress - 0x%lx Length - 0x%lx MinimalMemorySizeNeeded - 0x%lx\n", BaseAddress, Length, MinimalMemorySizeNeeded));\r
+ DEBUG ((DEBUG_INFO, "CoreInitializeMemoryServices:\n"));\r
+ DEBUG ((DEBUG_INFO, " BaseAddress - 0x%lx Length - 0x%lx MinimalMemorySizeNeeded - 0x%lx\n", BaseAddress, Length, MinimalMemorySizeNeeded));\r
\r
//\r
// If no memory regions are found that are big enough to initialize the DXE core, then ASSERT().\r
}\r
SectionHeaderOffset += sizeof (EFI_IMAGE_SECTION_HEADER);\r
}\r
- DEBUG ((EFI_D_INFO|EFI_D_LOAD, "LOADING MODULE FIXED INFO: Loading module at fixed address 0x%11p. Status = %r \n", (VOID *)(UINTN)(ImageContext->ImageAddress), Status));\r
+ DEBUG ((DEBUG_INFO|DEBUG_LOAD, "LOADING MODULE FIXED INFO: Loading module at fixed address 0x%11p. Status = %r \n", (VOID *)(UINTN)(ImageContext->ImageAddress), Status));\r
return Status;\r
}\r
\r
//\r
// If the code memory is not ready, invoke CoreAllocatePage with AllocateAnyPages to load the driver.\r
//\r
- DEBUG ((EFI_D_INFO|EFI_D_LOAD, "LOADING MODULE FIXED ERROR: Loading module at fixed address failed since specified memory is not available.\n"));\r
+ DEBUG ((DEBUG_INFO|DEBUG_LOAD, "LOADING MODULE FIXED ERROR: Loading module at fixed address failed since specified memory is not available.\n"));\r
\r
Status = CoreAllocatePages (\r
AllocateAnyPages,\r
// Do not ASSERT here, because image might be loaded via EFI_IMAGE_MACHINE_CROSS_TYPE_SUPPORTED\r
// But it can not be started.\r
//\r
- DEBUG ((EFI_D_ERROR, "Image type %s can't be started ", GetMachineTypeName(Image->Machine)));\r
- DEBUG ((EFI_D_ERROR, "on %s UEFI system.\n", GetMachineTypeName(mDxeCoreImageMachineType)));\r
+ DEBUG ((DEBUG_ERROR, "Image type %s can't be started ", GetMachineTypeName(Image->Machine)));\r
+ DEBUG ((DEBUG_ERROR, "on %s UEFI system.\n", GetMachineTypeName(mDxeCoreImageMachineType)));\r
return EFI_UNSUPPORTED;\r
}\r
\r
\r
RegisterDxeCore (HobStart, &mMemoryProfileContext);\r
\r
- DEBUG ((EFI_D_INFO, "MemoryProfileInit MemoryProfileContext - 0x%x\n", &mMemoryProfileContext));\r
+ DEBUG ((DEBUG_INFO, "MemoryProfileInit MemoryProfileContext - 0x%x\n", &mMemoryProfileContext));\r
}\r
\r
/**\r
);\r
if (EFI_ERROR (Status)) {\r
if (PcdGet64 (PcdMaxEfiSystemTablePointerAddress) != 0) {\r
- DEBUG ((EFI_D_INFO, "Allocate memory for EFI_SYSTEM_TABLE_POINTER below PcdMaxEfiSystemTablePointerAddress failed. \\r
+ DEBUG ((DEBUG_INFO, "Allocate memory for EFI_SYSTEM_TABLE_POINTER below PcdMaxEfiSystemTablePointerAddress failed. \\r
Retry to allocate memroy as close to the top of memory as feasible.\n"));\r
}\r
//\r
}\r
mDebugInfoTableHeader.UpdateStatus &= ~EFI_DEBUG_IMAGE_INFO_UPDATE_IN_PROGRESS;\r
}\r
-\r
-\r
\r
if (!mMemoryAttributesTableEnable) {\r
DEBUG ((DEBUG_VERBOSE, "Cannot install Memory Attributes Table "));\r
- DEBUG ((EFI_D_VERBOSE, "because Runtime Driver Section Alignment is not %dK.\n", RUNTIME_PAGE_ALLOCATION_GRANULARITY >> 10));\r
+ DEBUG ((DEBUG_VERBOSE, "because Runtime Driver Section Alignment is not %dK.\n", RUNTIME_PAGE_ALLOCATION_GRANULARITY >> 10));\r
return ;\r
}\r
\r
MemoryAttributesTable->NumberOfEntries = RuntimeEntryCount;\r
MemoryAttributesTable->DescriptorSize = (UINT32)DescriptorSize;\r
MemoryAttributesTable->Reserved = 0;\r
- DEBUG ((EFI_D_VERBOSE, "MemoryAttributesTable:\n"));\r
- DEBUG ((EFI_D_VERBOSE, " Version - 0x%08x\n", MemoryAttributesTable->Version));\r
- DEBUG ((EFI_D_VERBOSE, " NumberOfEntries - 0x%08x\n", MemoryAttributesTable->NumberOfEntries));\r
- DEBUG ((EFI_D_VERBOSE, " DescriptorSize - 0x%08x\n", MemoryAttributesTable->DescriptorSize));\r
+ DEBUG ((DEBUG_VERBOSE, "MemoryAttributesTable:\n"));\r
+ DEBUG ((DEBUG_VERBOSE, " Version - 0x%08x\n", MemoryAttributesTable->Version));\r
+ DEBUG ((DEBUG_VERBOSE, " NumberOfEntries - 0x%08x\n", MemoryAttributesTable->NumberOfEntries));\r
+ DEBUG ((DEBUG_VERBOSE, " DescriptorSize - 0x%08x\n", MemoryAttributesTable->DescriptorSize));\r
MemoryAttributesEntry = (EFI_MEMORY_DESCRIPTOR *)(MemoryAttributesTable + 1);\r
MemoryMap = MemoryMapStart;\r
for (Index = 0; Index < MemoryMapSize/DescriptorSize; Index++) {\r
case EfiRuntimeServicesData:\r
CopyMem (MemoryAttributesEntry, MemoryMap, DescriptorSize);\r
MemoryAttributesEntry->Attribute &= (EFI_MEMORY_RO|EFI_MEMORY_XP|EFI_MEMORY_RUNTIME);\r
- DEBUG ((EFI_D_VERBOSE, "Entry (0x%x)\n", MemoryAttributesEntry));\r
- DEBUG ((EFI_D_VERBOSE, " Type - 0x%x\n", MemoryAttributesEntry->Type));\r
- DEBUG ((EFI_D_VERBOSE, " PhysicalStart - 0x%016lx\n", MemoryAttributesEntry->PhysicalStart));\r
- DEBUG ((EFI_D_VERBOSE, " VirtualStart - 0x%016lx\n", MemoryAttributesEntry->VirtualStart));\r
- DEBUG ((EFI_D_VERBOSE, " NumberOfPages - 0x%016lx\n", MemoryAttributesEntry->NumberOfPages));\r
- DEBUG ((EFI_D_VERBOSE, " Attribute - 0x%016lx\n", MemoryAttributesEntry->Attribute));\r
+ DEBUG ((DEBUG_VERBOSE, "Entry (0x%x)\n", MemoryAttributesEntry));\r
+ DEBUG ((DEBUG_VERBOSE, " Type - 0x%x\n", MemoryAttributesEntry->Type));\r
+ DEBUG ((DEBUG_VERBOSE, " PhysicalStart - 0x%016lx\n", MemoryAttributesEntry->PhysicalStart));\r
+ DEBUG ((DEBUG_VERBOSE, " VirtualStart - 0x%016lx\n", MemoryAttributesEntry->VirtualStart));\r
+ DEBUG ((DEBUG_VERBOSE, " NumberOfPages - 0x%016lx\n", MemoryAttributesEntry->NumberOfPages));\r
+ DEBUG ((DEBUG_VERBOSE, " Attribute - 0x%016lx\n", MemoryAttributesEntry->Attribute));\r
MemoryAttributesEntry = NEXT_MEMORY_DESCRIPTOR(MemoryAttributesEntry, DescriptorSize);\r
break;\r
}\r
(VOID **)&VectorHandoffInfoPpi\r
);\r
if (Status == EFI_SUCCESS) {\r
- DEBUG ((EFI_D_INFO, "Vector Hand-off Info PPI is gotten, GUIDed HOB is created!\n"));\r
+ DEBUG ((DEBUG_INFO, "Vector Hand-off Info PPI is gotten, GUIDed HOB is created!\n"));\r
VectorInfo = VectorHandoffInfoPpi->Info;\r
Index = 1;\r
while (VectorInfo->Attribute != EFI_VECTOR_HANDOFF_LAST_ENTRY) {\r
}\r
}\r
}\r
-\r
(VOID **)&VectorHandoffInfoPpi\r
);\r
if (Status == EFI_SUCCESS) {\r
- DEBUG ((EFI_D_INFO, "Vector Hand-off Info PPI is gotten, GUIDed HOB is created!\n"));\r
+ DEBUG ((DEBUG_INFO, "Vector Hand-off Info PPI is gotten, GUIDed HOB is created!\n"));\r
VectorInfo = VectorHandoffInfoPpi->Info;\r
Index = 1;\r
while (VectorInfo->Attribute != EFI_VECTOR_HANDOFF_LAST_ENTRY) {\r
//\r
TotalReservedMemorySize += PeiMemorySize;\r
\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED INFO: PcdLoadFixAddressRuntimeCodePageNumber= 0x%x.\n", PcdGet32(PcdLoadFixAddressRuntimeCodePageNumber)));\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED INFO: PcdLoadFixAddressBootTimeCodePageNumber= 0x%x.\n", PcdGet32(PcdLoadFixAddressBootTimeCodePageNumber)));\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED INFO: PcdLoadFixAddressPeiCodePageNumber= 0x%x.\n", PcdGet32(PcdLoadFixAddressPeiCodePageNumber)));\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED INFO: Total Reserved Memory Size = 0x%lx.\n", TotalReservedMemorySize));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED INFO: PcdLoadFixAddressRuntimeCodePageNumber= 0x%x.\n", PcdGet32(PcdLoadFixAddressRuntimeCodePageNumber)));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED INFO: PcdLoadFixAddressBootTimeCodePageNumber= 0x%x.\n", PcdGet32(PcdLoadFixAddressBootTimeCodePageNumber)));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED INFO: PcdLoadFixAddressPeiCodePageNumber= 0x%x.\n", PcdGet32(PcdLoadFixAddressPeiCodePageNumber)));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED INFO: Total Reserved Memory Size = 0x%lx.\n", TotalReservedMemorySize));\r
//\r
// Loop through the system memory typed HOB to merge the adjacent memory range\r
//\r
// The LMFA feature is enabled as load module at fixed absolute address.\r
//\r
TopLoadingAddress = (EFI_PHYSICAL_ADDRESS)PcdGet64(PcdLoadModuleAtFixAddressEnable);\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED INFO: Loading module at fixed absolute address.\n"));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED INFO: Loading module at fixed absolute address.\n"));\r
//\r
// validate the Address. Loop the resource descriptor HOB to make sure the address is in valid memory range\r
//\r
if ((TopLoadingAddress & EFI_PAGE_MASK) != 0) {\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED ERROR:Top Address 0x%lx is invalid since top address should be page align. \n", TopLoadingAddress));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED ERROR:Top Address 0x%lx is invalid since top address should be page align. \n", TopLoadingAddress));\r
ASSERT (FALSE);\r
}\r
//\r
}\r
}\r
if (CurrentResourceHob != NULL) {\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED INFO:Top Address 0x%lx is valid \n", TopLoadingAddress));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED INFO:Top Address 0x%lx is valid \n", TopLoadingAddress));\r
TopLoadingAddress += MINIMUM_INITIAL_MEMORY_SIZE;\r
} else {\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED ERROR:Top Address 0x%lx is invalid \n", TopLoadingAddress));\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED ERROR:The recommended Top Address for the platform is: \n"));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED ERROR:Top Address 0x%lx is invalid \n", TopLoadingAddress));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED ERROR:The recommended Top Address for the platform is: \n"));\r
//\r
// Print the recommended Top address range.\r
//\r
// See if Top address specified by user is valid.\r
//\r
if (ResourceHob->ResourceLength > TotalReservedMemorySize && PeiLoadFixAddressIsMemoryRangeAvailable(PrivateData, ResourceHob)) {\r
- DEBUG ((EFI_D_INFO, "(0x%lx, 0x%lx)\n",\r
+ DEBUG ((DEBUG_INFO, "(0x%lx, 0x%lx)\n",\r
(ResourceHob->PhysicalStart + TotalReservedMemorySize -MINIMUM_INITIAL_MEMORY_SIZE),\r
(ResourceHob->PhysicalStart + ResourceHob->ResourceLength -MINIMUM_INITIAL_MEMORY_SIZE)\r
));\r
}\r
}\r
if (CurrentResourceHob == NULL) {\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED ERROR:The System Memory is too small\n"));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED ERROR:The System Memory is too small\n"));\r
//\r
// Assert here\r
//\r
// Cache the top address for Loading Module at Fixed Address feature\r
//\r
PrivateData->LoadModuleAtFixAddressTopAddress = TopLoadingAddress - MINIMUM_INITIAL_MEMORY_SIZE;\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED INFO: Top address = 0x%lx\n", PrivateData->LoadModuleAtFixAddressTopAddress));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED INFO: Top address = 0x%lx\n", PrivateData->LoadModuleAtFixAddressTopAddress));\r
//\r
// reinstall the PEI memory relative to TopLoadingAddress\r
//\r
// If Loading Module at Fixed Address is enabled, Allocating memory range for Pei code range.\r
//\r
LoadFixPeiCodeBegin = AllocatePages((UINTN)PcdGet32(PcdLoadFixAddressPeiCodePageNumber));\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED INFO: PeiCodeBegin = 0x%lX, PeiCodeTop= 0x%lX\n", (UINT64)(UINTN)LoadFixPeiCodeBegin, (UINT64)((UINTN)LoadFixPeiCodeBegin + PcdGet32(PcdLoadFixAddressPeiCodePageNumber) * EFI_PAGE_SIZE)));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED INFO: PeiCodeBegin = 0x%lX, PeiCodeTop= 0x%lX\n", (UINT64)(UINTN)LoadFixPeiCodeBegin, (UINT64)((UINTN)LoadFixPeiCodeBegin + PcdGet32(PcdLoadFixAddressPeiCodePageNumber) * EFI_PAGE_SIZE)));\r
}\r
\r
//\r
NewStackSize = RShiftU64 (Private->PhysicalMemoryLength, 1);\r
NewStackSize = ALIGN_VALUE (NewStackSize, EFI_PAGE_SIZE);\r
NewStackSize = MIN (PcdGet32(PcdPeiCoreMaxPeiStackSize), NewStackSize);\r
- DEBUG ((EFI_D_INFO, "Old Stack size %d, New stack size %d\n", (UINT32)SecCoreData->StackSize, (UINT32)NewStackSize));\r
+ DEBUG ((DEBUG_INFO, "Old Stack size %d, New stack size %d\n", (UINT32)SecCoreData->StackSize, (UINT32)NewStackSize));\r
ASSERT (NewStackSize >= SecCoreData->StackSize);\r
\r
//\r
//\r
// Build Stack HOB that describes the permanent memory stack\r
//\r
- DEBUG ((EFI_D_INFO, "Stack Hob: BaseAddress=0x%lX Length=0x%lX\n", TopOfNewStack - NewStackSize, NewStackSize));\r
+ DEBUG ((DEBUG_INFO, "Stack Hob: BaseAddress=0x%lX Length=0x%lX\n", TopOfNewStack - NewStackSize, NewStackSize));\r
BuildStackHob (TopOfNewStack - NewStackSize, NewStackSize);\r
\r
//\r
Private->HeapOffset = (UINTN)((UINTN)SecCoreData->PeiTemporaryRamBase - BaseOfNewHeap);\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Heap Offset = 0x%lX Stack Offset = 0x%lX\n", (UINT64) Private->HeapOffset, (UINT64) Private->StackOffset));\r
+ DEBUG ((DEBUG_INFO, "Heap Offset = 0x%lX Stack Offset = 0x%lX\n", (UINT64) Private->HeapOffset, (UINT64) Private->StackOffset));\r
\r
//\r
// Calculate new HandOffTable and PrivateData address in permanent memory's stack\r
Private->HeapOffset = (UINTN)((UINTN)SecCoreData->PeiTemporaryRamBase - BaseOfNewHeap);\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Heap Offset = 0x%lX Stack Offset = 0x%lX\n", (UINT64) Private->HeapOffset, (UINT64) Private->StackOffset));\r
+ DEBUG ((DEBUG_INFO, "Heap Offset = 0x%lX Stack Offset = 0x%lX\n", (UINT64) Private->HeapOffset, (UINT64) Private->StackOffset));\r
\r
//\r
// Migrate Heap\r
\r
return EFI_SUCCESS;\r
}\r
-\r
-\r
-\r
} else {\r
if (IS_FFS_FILE2 (*FileHeader)) {\r
if (!IsFfs3Fv) {\r
- DEBUG ((EFI_D_ERROR, "It is a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &(*FileHeader)->Name));\r
+ DEBUG ((DEBUG_ERROR, "It is a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &(*FileHeader)->Name));\r
}\r
FileLength = FFS_FILE2_SIZE (*FileHeader);\r
ASSERT (FileLength > 0x00FFFFFF);\r
case EFI_FILE_HEADER_INVALID:\r
if (IS_FFS_FILE2 (FfsFileHeader)) {\r
if (!IsFfs3Fv) {\r
- DEBUG ((EFI_D_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsFileHeader->Name));\r
+ DEBUG ((DEBUG_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsFileHeader->Name));\r
}\r
FileOffset += sizeof (EFI_FFS_FILE_HEADER2);\r
FfsFileHeader = (EFI_FFS_FILE_HEADER *) ((UINT8 *) FfsFileHeader + sizeof (EFI_FFS_FILE_HEADER2));\r
ASSERT (FileLength > 0x00FFFFFF);\r
FileOccupiedSize = GET_OCCUPIED_SIZE (FileLength, 8);\r
if (!IsFfs3Fv) {\r
- DEBUG ((EFI_D_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsFileHeader->Name));\r
+ DEBUG ((DEBUG_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsFileHeader->Name));\r
FileOffset += FileOccupiedSize;\r
FfsFileHeader = (EFI_FFS_FILE_HEADER *) ((UINT8 *) FfsFileHeader + FileOccupiedSize);\r
break;\r
case EFI_FILE_DELETED:\r
if (IS_FFS_FILE2 (FfsFileHeader)) {\r
if (!IsFfs3Fv) {\r
- DEBUG ((EFI_D_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsFileHeader->Name));\r
+ DEBUG ((DEBUG_ERROR, "Found a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsFileHeader->Name));\r
}\r
FileLength = FFS_FILE2_SIZE (FfsFileHeader);\r
ASSERT (FileLength > 0x00FFFFFF);\r
PrivateData->Fv[PrivateData->FvCount].FvHandle = FvHandle;\r
PrivateData->Fv[PrivateData->FvCount].AuthenticationStatus = 0;\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"The %dth FV start address is 0x%11p, size is 0x%08x, handle is 0x%p\n",\r
(UINT32) PrivateData->FvCount,\r
(VOID *) BfvHeader,\r
//\r
Status = FvPpi->ProcessVolume (FvPpi, FvInfo2Ppi.FvInfo, FvInfo2Ppi.FvInfoSize, &FvHandle);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Fail to process new found FV, FV may be corrupted!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Fail to process new found FV, FV may be corrupted!\n"));\r
return Status;\r
}\r
\r
if (PrivateData->Fv[FvIndex].FvHandle == FvHandle) {\r
if (IsFvInfo2 && (FvInfo2Ppi.AuthenticationStatus != PrivateData->Fv[FvIndex].AuthenticationStatus)) {\r
PrivateData->Fv[FvIndex].AuthenticationStatus = FvInfo2Ppi.AuthenticationStatus;\r
- DEBUG ((EFI_D_INFO, "Update AuthenticationStatus of the %dth FV to 0x%x!\n", FvIndex, FvInfo2Ppi.AuthenticationStatus));\r
+ DEBUG ((DEBUG_INFO, "Update AuthenticationStatus of the %dth FV to 0x%x!\n", FvIndex, FvInfo2Ppi.AuthenticationStatus));\r
}\r
DEBUG ((DEBUG_INFO, "The FV %p has already been processed!\n", FvInfo2Ppi.FvInfo));\r
return EFI_SUCCESS;\r
PrivateData->Fv[PrivateData->FvCount].AuthenticationStatus = FvInfo2Ppi.AuthenticationStatus;\r
CurFvCount = PrivateData->FvCount;\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"The %dth FV start address is 0x%11p, size is 0x%08x, handle is 0x%p\n",\r
(UINT32) CurFvCount,\r
(VOID *) FvInfo2Ppi.FvInfo,\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Found firmware volume Image File %p in FV[%d] %p\n", FileHandle, CurFvCount, FvHandle));\r
+ DEBUG ((DEBUG_INFO, "Found firmware volume Image File %p in FV[%d] %p\n", FileHandle, CurFvCount, FvHandle));\r
ProcessFvFile (PrivateData, &PrivateData->Fv[CurFvCount], FileHandle);\r
}\r
} while (FileHandle != NULL);\r
} else {\r
- DEBUG ((EFI_D_ERROR, "Fail to process FV %p because no corresponding EFI_FIRMWARE_VOLUME_PPI is found!\n", FvInfo2Ppi.FvInfo));\r
+ DEBUG ((DEBUG_ERROR, "Fail to process FV %p because no corresponding EFI_FIRMWARE_VOLUME_PPI is found!\n", FvInfo2Ppi.FvInfo));\r
\r
AddUnknownFormatFvInfo (PrivateData, &FvInfo2Ppi);\r
}\r
if (IS_SECTION2 (Section)) {\r
ASSERT (SECTION2_SIZE (Section) > 0x00FFFFFF);\r
if (!IsFfs3Fv) {\r
- DEBUG ((EFI_D_ERROR, "Found a FFS3 formatted section in a non-FFS3 formatted FV.\n"));\r
+ DEBUG ((DEBUG_ERROR, "Found a FFS3 formatted section in a non-FFS3 formatted FV.\n"));\r
SectionLength = SECTION2_SIZE (Section);\r
//\r
// SectionLength is adjusted it is 4 byte aligned.\r
//\r
// this FILE has been dispatched, it will not be dispatched again.\r
//\r
- DEBUG ((EFI_D_INFO, "FV file %p has been dispatched!\r\n", ParentFvFileHandle));\r
+ DEBUG ((DEBUG_INFO, "FV file %p has been dispatched!\r\n", ParentFvFileHandle));\r
return EFI_SUCCESS;\r
}\r
HobPtr.Raw = GET_NEXT_HOB (HobPtr);\r
//\r
Status = VerifyFv ((EFI_FIRMWARE_VOLUME_HEADER*) Buffer);\r
if (EFI_ERROR(Status)) {\r
- DEBUG ((EFI_D_ERROR, "Fail to verify FV which address is 0x%11p", Buffer));\r
+ DEBUG ((DEBUG_ERROR, "Fail to verify FV which address is 0x%11p", Buffer));\r
return EFI_VOLUME_CORRUPTED;\r
}\r
\r
if (IS_FFS_FILE2 (FileHeader)) {\r
ASSERT (FFS_FILE2_SIZE (FileHeader) > 0x00FFFFFF);\r
if (!FwVolInstance->IsFfs3Fv) {\r
- DEBUG ((EFI_D_ERROR, "It is a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FileHeader->Name));\r
+ DEBUG ((DEBUG_ERROR, "It is a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FileHeader->Name));\r
return EFI_INVALID_PARAMETER;\r
}\r
FileInfo->BufferSize = FFS_FILE2_SIZE (FileHeader) - sizeof (EFI_FFS_FILE_HEADER2);\r
if (IS_FFS_FILE2 (FfsFileHeader)) {\r
ASSERT (FFS_FILE2_SIZE (FfsFileHeader) > 0x00FFFFFF);\r
if (!FwVolInstance->IsFfs3Fv) {\r
- DEBUG ((EFI_D_ERROR, "It is a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsFileHeader->Name));\r
+ DEBUG ((DEBUG_ERROR, "It is a FFS3 formatted file: %g in a non-FFS3 formatted FV.\n", &FfsFileHeader->Name));\r
return EFI_NOT_FOUND;\r
}\r
Section = (EFI_COMMON_SECTION_HEADER *) ((UINT8 *) FfsFileHeader + sizeof (EFI_FFS_FILE_HEADER2));\r
//\r
Status = FvPpi->ProcessVolume (FvPpi, FvInfo, FvInfoSize, &FvHandle);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Fail to process the FV 0x%p, FV may be corrupted!\n", FvInfo));\r
+ DEBUG ((DEBUG_ERROR, "Fail to process the FV 0x%p, FV may be corrupted!\n", FvInfo));\r
continue;\r
}\r
\r
PrivateData->Fv[PrivateData->FvCount].AuthenticationStatus = AuthenticationStatus;\r
CurFvCount = PrivateData->FvCount;\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"The %dth FV start address is 0x%11p, size is 0x%08x, handle is 0x%p\n",\r
(UINT32) CurFvCount,\r
(VOID *) FvInfo,\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Found firmware volume Image File %p in FV[%d] %p\n", FileHandle, CurFvCount, FvHandle));\r
+ DEBUG ((DEBUG_INFO, "Found firmware volume Image File %p in FV[%d] %p\n", FileHandle, CurFvCount, FvHandle));\r
ProcessFvFile (PrivateData, &PrivateData->Fv[CurFvCount], FileHandle);\r
}\r
} while (FileHandle != NULL);\r
HandOffHob->EfiFreeMemoryBottom;\r
\r
if (FreeMemory < Length) {\r
- DEBUG ((EFI_D_ERROR, "PeiCreateHob fail: Length - 0x%08x\n", (UINTN)Length));\r
- DEBUG ((EFI_D_ERROR, " FreeMemoryTop - 0x%08x\n", (UINTN)HandOffHob->EfiFreeMemoryTop));\r
- DEBUG ((EFI_D_ERROR, " FreeMemoryBottom - 0x%08x\n", (UINTN)HandOffHob->EfiFreeMemoryBottom));\r
+ DEBUG ((DEBUG_ERROR, "PeiCreateHob fail: Length - 0x%08x\n", (UINTN)Length));\r
+ DEBUG ((DEBUG_ERROR, " FreeMemoryTop - 0x%08x\n", (UINTN)HandOffHob->EfiFreeMemoryTop));\r
+ DEBUG ((DEBUG_ERROR, " FreeMemoryBottom - 0x%08x\n", (UINTN)HandOffHob->EfiFreeMemoryBottom));\r
return EFI_OUT_OF_RESOURCES;\r
}\r
\r
}\r
SectionHeaderOffset += sizeof (EFI_IMAGE_SECTION_HEADER);\r
}\r
- DEBUG ((EFI_D_INFO|EFI_D_LOAD, "LOADING MODULE FIXED INFO: Loading module at fixed address 0x%11p. Status= %r \n", (VOID *)(UINTN)FixLoadingAddress, Status));\r
+ DEBUG ((DEBUG_INFO|DEBUG_LOAD, "LOADING MODULE FIXED INFO: Loading module at fixed address 0x%11p. Status= %r \n", (VOID *)(UINTN)FixLoadingAddress, Status));\r
return Status;\r
}\r
/**\r
(!IsS3Boot && (PcdGetBool (PcdShadowPeimOnBoot) || IsRegisterForShadow)) ||\r
(IsS3Boot && PcdGetBool (PcdShadowPeimOnS3Boot)))\r
) {\r
- DEBUG ((EFI_D_INFO|EFI_D_LOAD, "The image at 0x%08x without reloc section can't be loaded into memory\n", (UINTN) Pe32Data));\r
+ DEBUG ((DEBUG_INFO|DEBUG_LOAD, "The image at 0x%08x without reloc section can't be loaded into memory\n", (UINTN) Pe32Data));\r
}\r
\r
//\r
if (PcdGet64(PcdLoadModuleAtFixAddressEnable) != 0 && (Private->HobList.HandoffInformationTable->BootMode != BOOT_ON_S3_RESUME)) {\r
Status = GetPeCoffImageFixLoadingAssignedAddress(&ImageContext, Private);\r
if (EFI_ERROR (Status)){\r
- DEBUG ((EFI_D_INFO|EFI_D_LOAD, "LOADING MODULE FIXED ERROR: Failed to load module at fixed address. \n"));\r
+ DEBUG ((DEBUG_INFO|DEBUG_LOAD, "LOADING MODULE FIXED ERROR: Failed to load module at fixed address. \n"));\r
//\r
// The PEIM is not assigned valid address, try to allocate page to load it.\r
//\r
// Print debug message: Loading PEIM at 0x12345678 EntryPoint=0x12345688 Driver.efi\r
//\r
if (Machine != EFI_IMAGE_MACHINE_IA64) {\r
- DEBUG ((EFI_D_INFO | EFI_D_LOAD, "Loading PEIM at 0x%11p EntryPoint=0x%11p ", (VOID *)(UINTN)ImageAddress, (VOID *)(UINTN)*EntryPoint));\r
+ DEBUG ((DEBUG_INFO | DEBUG_LOAD, "Loading PEIM at 0x%11p EntryPoint=0x%11p ", (VOID *)(UINTN)ImageAddress, (VOID *)(UINTN)*EntryPoint));\r
} else {\r
//\r
// For IPF Image, the real entry point should be print.\r
//\r
- DEBUG ((EFI_D_INFO | EFI_D_LOAD, "Loading PEIM at 0x%11p EntryPoint=0x%11p ", (VOID *)(UINTN)ImageAddress, (VOID *)(UINTN)(*(UINT64 *)(UINTN)*EntryPoint)));\r
+ DEBUG ((DEBUG_INFO | DEBUG_LOAD, "Loading PEIM at 0x%11p EntryPoint=0x%11p ", (VOID *)(UINTN)ImageAddress, (VOID *)(UINTN)(*(UINT64 *)(UINTN)*EntryPoint)));\r
}\r
\r
//\r
EfiFileName[Index] = 0;\r
}\r
\r
- DEBUG ((EFI_D_INFO | EFI_D_LOAD, "%a", EfiFileName));\r
+ DEBUG ((DEBUG_INFO | DEBUG_LOAD, "%a", EfiFileName));\r
}\r
\r
DEBUG_CODE_END ();\r
\r
- DEBUG ((EFI_D_INFO | EFI_D_LOAD, "\n"));\r
+ DEBUG ((DEBUG_INFO | DEBUG_LOAD, "\n"));\r
\r
return EFI_SUCCESS;\r
\r
PeiServicesReInstallPpi (PrivateData->XipLoadFile, &gPpiLoadFilePpiList);\r
}\r
}\r
-\r
-\r
-\r
-\r
{\r
PEI_CORE_INSTANCE *PrivateData;\r
\r
- DEBUG ((EFI_D_INFO, "PeiInstallPeiMemory MemoryBegin 0x%LX, MemoryLength 0x%LX\n", MemoryBegin, MemoryLength));\r
+ DEBUG ((DEBUG_INFO, "PeiInstallPeiMemory MemoryBegin 0x%LX, MemoryLength 0x%LX\n", MemoryBegin, MemoryLength));\r
PrivateData = PEI_CORE_INSTANCE_FROM_PS_THIS (PeiServices);\r
\r
//\r
// simply return EFI_SUCCESS in release tip to ignore it.\r
//\r
if (PrivateData->PeiMemoryInstalled) {\r
- DEBUG ((EFI_D_ERROR, "ERROR: PeiInstallPeiMemory is called more than once!\n"));\r
+ DEBUG ((DEBUG_ERROR, "ERROR: PeiInstallPeiMemory is called more than once!\n"));\r
ASSERT (FALSE);\r
return EFI_SUCCESS;\r
}\r
if (!EFI_ERROR (Status)) {\r
return Status;\r
}\r
- DEBUG ((EFI_D_ERROR, "AllocatePages failed: No 0x%lx Pages is available.\n", (UINT64) Pages));\r
- DEBUG ((EFI_D_ERROR, "There is only left 0x%lx pages memory resource to be allocated.\n", (UINT64) RemainingPages));\r
+ DEBUG ((DEBUG_ERROR, "AllocatePages failed: No 0x%lx Pages is available.\n", (UINT64) Pages));\r
+ DEBUG ((DEBUG_ERROR, "There is only left 0x%lx pages memory resource to be allocated.\n", (UINT64) RemainingPages));\r
return EFI_OUT_OF_RESOURCES;\r
} else {\r
//\r
//\r
// Enter DxeIpl to load Dxe core.\r
//\r
- DEBUG ((EFI_D_INFO, "DXE IPL Entry\n"));\r
+ DEBUG ((DEBUG_INFO, "DXE IPL Entry\n"));\r
Status = TempPtr.DxeIpl->Entry (\r
TempPtr.DxeIpl,\r
&PrivateData.Ps,\r
//\r
if ((PpiList->Flags & EFI_PEI_PPI_DESCRIPTOR_PPI) == 0) {\r
PpiListPointer->CurrentCount = LastCount;\r
- DEBUG((EFI_D_ERROR, "ERROR -> InstallPpi: %g %p\n", PpiList->Guid, PpiList->Ppi));\r
+ DEBUG((DEBUG_ERROR, "ERROR -> InstallPpi: %g %p\n", PpiList->Guid, PpiList->Ppi));\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
PpiListPointer->MaxCount = PpiListPointer->MaxCount + PPI_GROWTH_STEP;\r
}\r
\r
- DEBUG((EFI_D_INFO, "Install PPI: %g\n", PpiList->Guid));\r
+ DEBUG((DEBUG_INFO, "Install PPI: %g\n", PpiList->Guid));\r
PpiListPointer->PpiPtrs[Index].Ppi = (EFI_PEI_PPI_DESCRIPTOR *) PpiList;\r
Index++;\r
PpiListPointer->CurrentCount++;\r
//\r
// Replace the old PPI with the new one.\r
//\r
- DEBUG((EFI_D_INFO, "Reinstall PPI: %g\n", NewPpi->Guid));\r
+ DEBUG((DEBUG_INFO, "Reinstall PPI: %g\n", NewPpi->Guid));\r
PrivateData->PpiData.PpiList.PpiPtrs[Index].Ppi = (EFI_PEI_PPI_DESCRIPTOR *) NewPpi;\r
\r
//\r
DispatchNotifyListPointer->CurrentCount++;\r
}\r
\r
- DEBUG((EFI_D_INFO, "Register PPI Notify: %g\n", NotifyList->Guid));\r
+ DEBUG((DEBUG_INFO, "Register PPI Notify: %g\n", NotifyList->Guid));\r
\r
if (Single) {\r
//\r
(((INT32 *)SearchGuid)[1] == ((INT32 *)CheckGuid)[1]) &&\r
(((INT32 *)SearchGuid)[2] == ((INT32 *)CheckGuid)[2]) &&\r
(((INT32 *)SearchGuid)[3] == ((INT32 *)CheckGuid)[3])) {\r
- DEBUG ((EFI_D_INFO, "Notify: PPI Guid: %g, Peim notify entry point: %p\n",\r
+ DEBUG ((DEBUG_INFO, "Notify: PPI Guid: %g, Peim notify entry point: %p\n",\r
SearchGuid,\r
NotifyDescriptor->Notify\r
));\r
ConvertPpiPointersFv (PrivateData, (UINTN) OrgImageBase, (UINTN) MigratedImageBase, PeiCoreModuleSize);\r
}\r
}\r
-\r
}\r
SectionHeaderOffset += sizeof (EFI_IMAGE_SECTION_HEADER);\r
}\r
- DEBUG ((EFI_D_INFO|EFI_D_LOAD, "LOADING MODULE FIXED INFO: Loading module at fixed address %x, Status = %r\n", FixLoadingAddress, Status));\r
+ DEBUG ((DEBUG_INFO|DEBUG_LOAD, "LOADING MODULE FIXED INFO: Loading module at fixed address %x, Status = %r\n", FixLoadingAddress, Status));\r
return Status;\r
}\r
/**\r
PageCount = 0;\r
DstBuffer = (UINTN)gLoadModuleAtFixAddressSmramBase;\r
} else {\r
- DEBUG ((EFI_D_INFO|EFI_D_LOAD, "LOADING MODULE FIXED ERROR: Failed to load module at fixed address. \n"));\r
+ DEBUG ((DEBUG_INFO|DEBUG_LOAD, "LOADING MODULE FIXED ERROR: Failed to load module at fixed address. \n"));\r
//\r
// allocate the memory to load the SMM driver\r
//\r
EFI_SMM_SX_REGISTER_CONTEXT EntryRegisterContext;\r
EFI_HANDLE S3EntryHandle;\r
\r
- DEBUG ((EFI_D_INFO, "SmmEndOfDxeHandler\n"));\r
+ DEBUG ((DEBUG_INFO, "SmmEndOfDxeHandler\n"));\r
\r
//\r
// Install SMM EndOfDxe protocol\r
}\r
SectionHeaderOffset += sizeof (EFI_IMAGE_SECTION_HEADER);\r
}\r
- DEBUG ((EFI_D_INFO|EFI_D_LOAD, "LOADING MODULE FIXED INFO: Loading module at fixed address %x, Status = %r \n", FixLoadingAddress, Status));\r
+ DEBUG ((DEBUG_INFO|DEBUG_LOAD, "LOADING MODULE FIXED INFO: Loading module at fixed address %x, Status = %r \n", FixLoadingAddress, Status));\r
return Status;\r
}\r
/**\r
//\r
gSmmCorePrivate->SmramRangeCount --;\r
} else {\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED ERROR: Loading module at fixed address at address failed\n"));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED ERROR: Loading module at fixed address at address failed\n"));\r
//\r
// Allocate memory for the image being loaded from the EFI_SRAM_DESCRIPTOR\r
// specified by SmramRange\r
//\r
// Print the SMRAM base\r
//\r
- DEBUG ((EFI_D_INFO, "LOADING MODULE FIXED INFO: TSEG BASE is %x. \n", mLMFAConfigurationTable->SmramBase));\r
+ DEBUG ((DEBUG_INFO, "LOADING MODULE FIXED INFO: TSEG BASE is %x. \n", mLMFAConfigurationTable->SmramBase));\r
}\r
\r
//\r
\r
RegisterSmmCore (&mSmramProfileContext);\r
\r
- DEBUG ((EFI_D_INFO, "SmramProfileInit SmramProfileContext - 0x%x\n", &mSmramProfileContext));\r
+ DEBUG ((DEBUG_INFO, "SmramProfileInit SmramProfileContext - 0x%x\n", &mSmramProfileContext));\r
}\r
\r
/**\r
return;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "SmramProfileReadyToLock\n"));\r
+ DEBUG ((DEBUG_INFO, "SmramProfileReadyToLock\n"));\r
mSmramReadyToLock = TRUE;\r
}\r
\r
// Sanity check\r
//\r
if (!SmmIsBufferOutsideSmmValid ((UINTN) SmramProfileGetData.ProfileBuffer, (UINTN) ProfileSize)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandlerGetData: SMM ProfileBuffer in SMRAM or overflow!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandlerGetData: SMM ProfileBuffer in SMRAM or overflow!\n"));\r
SmramProfileParameterGetData->ProfileSize = ProfileSize;\r
SmramProfileParameterGetData->Header.ReturnStatus = (UINT64) (INT64) (INTN) EFI_ACCESS_DENIED;\r
goto Done;\r
// Sanity check\r
//\r
if (!SmmIsBufferOutsideSmmValid ((UINTN) SmramProfileGetDataByOffset.ProfileBuffer, (UINTN) SmramProfileGetDataByOffset.ProfileSize)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandlerGetDataByOffset: SMM ProfileBuffer in SMRAM or overflow!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandlerGetDataByOffset: SMM ProfileBuffer in SMRAM or overflow!\n"));\r
SmramProfileParameterGetDataByOffset->Header.ReturnStatus = (UINT64) (INT64) (INTN) EFI_ACCESS_DENIED;\r
goto Done;\r
}\r
UINTN TempCommBufferSize;\r
SMRAM_PROFILE_PARAMETER_RECORDING_STATE *ParameterRecordingState;\r
\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandler Enter\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandler Enter\n"));\r
\r
//\r
// If input is invalid, stop processing this SMI\r
TempCommBufferSize = *CommBufferSize;\r
\r
if (TempCommBufferSize < sizeof (SMRAM_PROFILE_PARAMETER_HEADER)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
\r
if (mSmramReadyToLock && !SmmIsBufferOutsideSmmValid ((UINTN)CommBuffer, TempCommBufferSize)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandler: SMM communication buffer in SMRAM or overflow!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandler: SMM communication buffer in SMRAM or overflow!\n"));\r
return EFI_SUCCESS;\r
}\r
\r
\r
switch (SmramProfileParameterHeader->Command) {\r
case SMRAM_PROFILE_COMMAND_GET_PROFILE_INFO:\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandlerGetInfo\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandlerGetInfo\n"));\r
if (TempCommBufferSize != sizeof (SMRAM_PROFILE_PARAMETER_GET_PROFILE_INFO)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
SmramProfileHandlerGetInfo ((SMRAM_PROFILE_PARAMETER_GET_PROFILE_INFO *) (UINTN) CommBuffer);\r
break;\r
case SMRAM_PROFILE_COMMAND_GET_PROFILE_DATA:\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandlerGetData\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandlerGetData\n"));\r
if (TempCommBufferSize != sizeof (SMRAM_PROFILE_PARAMETER_GET_PROFILE_DATA)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
SmramProfileHandlerGetData ((SMRAM_PROFILE_PARAMETER_GET_PROFILE_DATA *) (UINTN) CommBuffer);\r
break;\r
case SMRAM_PROFILE_COMMAND_GET_PROFILE_DATA_BY_OFFSET:\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandlerGetDataByOffset\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandlerGetDataByOffset\n"));\r
if (TempCommBufferSize != sizeof (SMRAM_PROFILE_PARAMETER_GET_PROFILE_DATA_BY_OFFSET)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
SmramProfileHandlerGetDataByOffset ((SMRAM_PROFILE_PARAMETER_GET_PROFILE_DATA_BY_OFFSET *) (UINTN) CommBuffer);\r
break;\r
case SMRAM_PROFILE_COMMAND_GET_RECORDING_STATE:\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandlerGetRecordingState\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandlerGetRecordingState\n"));\r
if (TempCommBufferSize != sizeof (SMRAM_PROFILE_PARAMETER_RECORDING_STATE)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
ParameterRecordingState = (SMRAM_PROFILE_PARAMETER_RECORDING_STATE *) (UINTN) CommBuffer;\r
ParameterRecordingState->Header.ReturnStatus = 0;\r
break;\r
case SMRAM_PROFILE_COMMAND_SET_RECORDING_STATE:\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandlerSetRecordingState\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandlerSetRecordingState\n"));\r
if (TempCommBufferSize != sizeof (SMRAM_PROFILE_PARAMETER_RECORDING_STATE)) {\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandler: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
ParameterRecordingState = (SMRAM_PROFILE_PARAMETER_RECORDING_STATE *) (UINTN) CommBuffer;\r
break;\r
}\r
\r
- DEBUG ((EFI_D_ERROR, "SmramProfileHandler Exit\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmramProfileHandler Exit\n"));\r
\r
return EFI_SUCCESS;\r
}\r
SmramProfileGettingStatus = mSmramProfileGettingStatus;\r
mSmramProfileGettingStatus = TRUE;\r
\r
- DEBUG ((EFI_D_INFO, "FullSmramRange address - 0x%08x\n", mFullSmramRanges));\r
+ DEBUG ((DEBUG_INFO, "FullSmramRange address - 0x%08x\n", mFullSmramRanges));\r
\r
- DEBUG ((EFI_D_INFO, "======= SmramProfile begin =======\n"));\r
+ DEBUG ((DEBUG_INFO, "======= SmramProfile begin =======\n"));\r
\r
- DEBUG ((EFI_D_INFO, "FullSmramRange:\n"));\r
+ DEBUG ((DEBUG_INFO, "FullSmramRange:\n"));\r
for (Index = 0; Index < mFullSmramRangeCount; Index++) {\r
- DEBUG ((EFI_D_INFO, " FullSmramRange (0x%x)\n", Index));\r
- DEBUG ((EFI_D_INFO, " PhysicalStart - 0x%016lx\n", mFullSmramRanges[Index].PhysicalStart));\r
- DEBUG ((EFI_D_INFO, " CpuStart - 0x%016lx\n", mFullSmramRanges[Index].CpuStart));\r
- DEBUG ((EFI_D_INFO, " PhysicalSize - 0x%016lx\n", mFullSmramRanges[Index].PhysicalSize));\r
- DEBUG ((EFI_D_INFO, " RegionState - 0x%016lx\n", mFullSmramRanges[Index].RegionState));\r
+ DEBUG ((DEBUG_INFO, " FullSmramRange (0x%x)\n", Index));\r
+ DEBUG ((DEBUG_INFO, " PhysicalStart - 0x%016lx\n", mFullSmramRanges[Index].PhysicalStart));\r
+ DEBUG ((DEBUG_INFO, " CpuStart - 0x%016lx\n", mFullSmramRanges[Index].CpuStart));\r
+ DEBUG ((DEBUG_INFO, " PhysicalSize - 0x%016lx\n", mFullSmramRanges[Index].PhysicalSize));\r
+ DEBUG ((DEBUG_INFO, " RegionState - 0x%016lx\n", mFullSmramRanges[Index].RegionState));\r
}\r
\r
- DEBUG ((EFI_D_INFO, "======= SmramProfile end =======\n"));\r
+ DEBUG ((DEBUG_INFO, "======= SmramProfile end =======\n"));\r
\r
mSmramProfileGettingStatus = SmramProfileGettingStatus;\r
}\r
SmramProfileGettingStatus = mSmramProfileGettingStatus;\r
mSmramProfileGettingStatus = TRUE;\r
\r
- DEBUG ((EFI_D_INFO, "======= SmramProfile begin =======\n"));\r
+ DEBUG ((DEBUG_INFO, "======= SmramProfile begin =======\n"));\r
\r
- DEBUG ((EFI_D_INFO, "FreePagesList:\n"));\r
+ DEBUG ((DEBUG_INFO, "FreePagesList:\n"));\r
FreePageList = &mSmmMemoryMap;\r
for (Node = FreePageList->BackLink, Index = 0;\r
Node != FreePageList;\r
Node = Node->BackLink, Index++) {\r
Pages = BASE_CR (Node, FREE_PAGE_LIST, Link);\r
- DEBUG ((EFI_D_INFO, " Index - 0x%x\n", Index));\r
- DEBUG ((EFI_D_INFO, " PhysicalStart - 0x%016lx\n", (PHYSICAL_ADDRESS) (UINTN) Pages));\r
- DEBUG ((EFI_D_INFO, " NumberOfPages - 0x%08x\n", Pages->NumberOfPages));\r
+ DEBUG ((DEBUG_INFO, " Index - 0x%x\n", Index));\r
+ DEBUG ((DEBUG_INFO, " PhysicalStart - 0x%016lx\n", (PHYSICAL_ADDRESS) (UINTN) Pages));\r
+ DEBUG ((DEBUG_INFO, " NumberOfPages - 0x%08x\n", Pages->NumberOfPages));\r
}\r
\r
- DEBUG ((EFI_D_INFO, "======= SmramProfile end =======\n"));\r
+ DEBUG ((DEBUG_INFO, "======= SmramProfile end =======\n"));\r
\r
mSmramProfileGettingStatus = SmramProfileGettingStatus;\r
}\r
mSmramProfileGettingStatus = TRUE;\r
\r
Context = &ContextData->Context;\r
- DEBUG ((EFI_D_INFO, "======= SmramProfile begin =======\n"));\r
- DEBUG ((EFI_D_INFO, "MEMORY_PROFILE_CONTEXT\n"));\r
+ DEBUG ((DEBUG_INFO, "======= SmramProfile begin =======\n"));\r
+ DEBUG ((DEBUG_INFO, "MEMORY_PROFILE_CONTEXT\n"));\r
\r
- DEBUG ((EFI_D_INFO, " CurrentTotalUsage - 0x%016lx\n", Context->CurrentTotalUsage));\r
- DEBUG ((EFI_D_INFO, " PeakTotalUsage - 0x%016lx\n", Context->PeakTotalUsage));\r
+ DEBUG ((DEBUG_INFO, " CurrentTotalUsage - 0x%016lx\n", Context->CurrentTotalUsage));\r
+ DEBUG ((DEBUG_INFO, " PeakTotalUsage - 0x%016lx\n", Context->PeakTotalUsage));\r
for (TypeIndex = 0; TypeIndex < sizeof (Context->CurrentTotalUsageByType) / sizeof (Context->CurrentTotalUsageByType[0]); TypeIndex++) {\r
if ((Context->CurrentTotalUsageByType[TypeIndex] != 0) ||\r
(Context->PeakTotalUsageByType[TypeIndex] != 0)) {\r
- DEBUG ((EFI_D_INFO, " CurrentTotalUsage[0x%02x] - 0x%016lx (%a)\n", TypeIndex, Context->CurrentTotalUsageByType[TypeIndex], ProfileMemoryTypeToStr (TypeIndex)));\r
- DEBUG ((EFI_D_INFO, " PeakTotalUsage[0x%02x] - 0x%016lx (%a)\n", TypeIndex, Context->PeakTotalUsageByType[TypeIndex], ProfileMemoryTypeToStr (TypeIndex)));\r
+ DEBUG ((DEBUG_INFO, " CurrentTotalUsage[0x%02x] - 0x%016lx (%a)\n", TypeIndex, Context->CurrentTotalUsageByType[TypeIndex], ProfileMemoryTypeToStr (TypeIndex)));\r
+ DEBUG ((DEBUG_INFO, " PeakTotalUsage[0x%02x] - 0x%016lx (%a)\n", TypeIndex, Context->PeakTotalUsageByType[TypeIndex], ProfileMemoryTypeToStr (TypeIndex)));\r
}\r
}\r
- DEBUG ((EFI_D_INFO, " TotalImageSize - 0x%016lx\n", Context->TotalImageSize));\r
- DEBUG ((EFI_D_INFO, " ImageCount - 0x%08x\n", Context->ImageCount));\r
- DEBUG ((EFI_D_INFO, " SequenceCount - 0x%08x\n", Context->SequenceCount));\r
+ DEBUG ((DEBUG_INFO, " TotalImageSize - 0x%016lx\n", Context->TotalImageSize));\r
+ DEBUG ((DEBUG_INFO, " ImageCount - 0x%08x\n", Context->ImageCount));\r
+ DEBUG ((DEBUG_INFO, " SequenceCount - 0x%08x\n", Context->SequenceCount));\r
\r
SmramDriverInfoList = ContextData->DriverInfoList;\r
for (DriverLink = SmramDriverInfoList->ForwardLink, DriverIndex = 0;\r
MEMORY_PROFILE_DRIVER_INFO_SIGNATURE\r
);\r
DriverInfo = &DriverInfoData->DriverInfo;\r
- DEBUG ((EFI_D_INFO, " MEMORY_PROFILE_DRIVER_INFO (0x%x)\n", DriverIndex));\r
- DEBUG ((EFI_D_INFO, " FileName - %g\n", &DriverInfo->FileName));\r
- DEBUG ((EFI_D_INFO, " ImageBase - 0x%016lx\n", DriverInfo->ImageBase));\r
- DEBUG ((EFI_D_INFO, " ImageSize - 0x%016lx\n", DriverInfo->ImageSize));\r
- DEBUG ((EFI_D_INFO, " EntryPoint - 0x%016lx\n", DriverInfo->EntryPoint));\r
- DEBUG ((EFI_D_INFO, " ImageSubsystem - 0x%04x\n", DriverInfo->ImageSubsystem));\r
- DEBUG ((EFI_D_INFO, " FileType - 0x%02x\n", DriverInfo->FileType));\r
- DEBUG ((EFI_D_INFO, " CurrentUsage - 0x%016lx\n", DriverInfo->CurrentUsage));\r
- DEBUG ((EFI_D_INFO, " PeakUsage - 0x%016lx\n", DriverInfo->PeakUsage));\r
+ DEBUG ((DEBUG_INFO, " MEMORY_PROFILE_DRIVER_INFO (0x%x)\n", DriverIndex));\r
+ DEBUG ((DEBUG_INFO, " FileName - %g\n", &DriverInfo->FileName));\r
+ DEBUG ((DEBUG_INFO, " ImageBase - 0x%016lx\n", DriverInfo->ImageBase));\r
+ DEBUG ((DEBUG_INFO, " ImageSize - 0x%016lx\n", DriverInfo->ImageSize));\r
+ DEBUG ((DEBUG_INFO, " EntryPoint - 0x%016lx\n", DriverInfo->EntryPoint));\r
+ DEBUG ((DEBUG_INFO, " ImageSubsystem - 0x%04x\n", DriverInfo->ImageSubsystem));\r
+ DEBUG ((DEBUG_INFO, " FileType - 0x%02x\n", DriverInfo->FileType));\r
+ DEBUG ((DEBUG_INFO, " CurrentUsage - 0x%016lx\n", DriverInfo->CurrentUsage));\r
+ DEBUG ((DEBUG_INFO, " PeakUsage - 0x%016lx\n", DriverInfo->PeakUsage));\r
for (TypeIndex = 0; TypeIndex < sizeof (DriverInfo->CurrentUsageByType) / sizeof (DriverInfo->CurrentUsageByType[0]); TypeIndex++) {\r
if ((DriverInfo->CurrentUsageByType[TypeIndex] != 0) ||\r
(DriverInfo->PeakUsageByType[TypeIndex] != 0)) {\r
- DEBUG ((EFI_D_INFO, " CurrentUsage[0x%02x] - 0x%016lx (%a)\n", TypeIndex, DriverInfo->CurrentUsageByType[TypeIndex], ProfileMemoryTypeToStr (TypeIndex)));\r
- DEBUG ((EFI_D_INFO, " PeakUsage[0x%02x] - 0x%016lx (%a)\n", TypeIndex, DriverInfo->PeakUsageByType[TypeIndex], ProfileMemoryTypeToStr (TypeIndex)));\r
+ DEBUG ((DEBUG_INFO, " CurrentUsage[0x%02x] - 0x%016lx (%a)\n", TypeIndex, DriverInfo->CurrentUsageByType[TypeIndex], ProfileMemoryTypeToStr (TypeIndex)));\r
+ DEBUG ((DEBUG_INFO, " PeakUsage[0x%02x] - 0x%016lx (%a)\n", TypeIndex, DriverInfo->PeakUsageByType[TypeIndex], ProfileMemoryTypeToStr (TypeIndex)));\r
}\r
}\r
- DEBUG ((EFI_D_INFO, " AllocRecordCount - 0x%08x\n", DriverInfo->AllocRecordCount));\r
+ DEBUG ((DEBUG_INFO, " AllocRecordCount - 0x%08x\n", DriverInfo->AllocRecordCount));\r
\r
AllocInfoList = DriverInfoData->AllocInfoList;\r
for (AllocLink = AllocInfoList->ForwardLink, AllocIndex = 0;\r
MEMORY_PROFILE_ALLOC_INFO_SIGNATURE\r
);\r
AllocInfo = &AllocInfoData->AllocInfo;\r
- DEBUG ((EFI_D_INFO, " MEMORY_PROFILE_ALLOC_INFO (0x%x)\n", AllocIndex));\r
- DEBUG ((EFI_D_INFO, " CallerAddress - 0x%016lx (Offset: 0x%08x)\n", AllocInfo->CallerAddress, AllocInfo->CallerAddress - DriverInfo->ImageBase));\r
- DEBUG ((EFI_D_INFO, " SequenceId - 0x%08x\n", AllocInfo->SequenceId));\r
+ DEBUG ((DEBUG_INFO, " MEMORY_PROFILE_ALLOC_INFO (0x%x)\n", AllocIndex));\r
+ DEBUG ((DEBUG_INFO, " CallerAddress - 0x%016lx (Offset: 0x%08x)\n", AllocInfo->CallerAddress, AllocInfo->CallerAddress - DriverInfo->ImageBase));\r
+ DEBUG ((DEBUG_INFO, " SequenceId - 0x%08x\n", AllocInfo->SequenceId));\r
if ((AllocInfo->Action & MEMORY_PROFILE_ACTION_USER_DEFINED_MASK) != 0) {\r
if (AllocInfoData->ActionString != NULL) {\r
- DEBUG ((EFI_D_INFO, " Action - 0x%08x (%a)\n", AllocInfo->Action, AllocInfoData->ActionString));\r
+ DEBUG ((DEBUG_INFO, " Action - 0x%08x (%a)\n", AllocInfo->Action, AllocInfoData->ActionString));\r
} else {\r
- DEBUG ((EFI_D_INFO, " Action - 0x%08x (UserDefined-0x%08x)\n", AllocInfo->Action, AllocInfo->Action));\r
+ DEBUG ((DEBUG_INFO, " Action - 0x%08x (UserDefined-0x%08x)\n", AllocInfo->Action, AllocInfo->Action));\r
}\r
} else {\r
- DEBUG ((EFI_D_INFO, " Action - 0x%08x (%a)\n", AllocInfo->Action, ProfileActionToStr (AllocInfo->Action)));\r
+ DEBUG ((DEBUG_INFO, " Action - 0x%08x (%a)\n", AllocInfo->Action, ProfileActionToStr (AllocInfo->Action)));\r
}\r
- DEBUG ((EFI_D_INFO, " MemoryType - 0x%08x (%a)\n", AllocInfo->MemoryType, ProfileMemoryTypeToStr (AllocInfo->MemoryType)));\r
- DEBUG ((EFI_D_INFO, " Buffer - 0x%016lx\n", AllocInfo->Buffer));\r
- DEBUG ((EFI_D_INFO, " Size - 0x%016lx\n", AllocInfo->Size));\r
+ DEBUG ((DEBUG_INFO, " MemoryType - 0x%08x (%a)\n", AllocInfo->MemoryType, ProfileMemoryTypeToStr (AllocInfo->MemoryType)));\r
+ DEBUG ((DEBUG_INFO, " Buffer - 0x%016lx\n", AllocInfo->Buffer));\r
+ DEBUG ((DEBUG_INFO, " Size - 0x%016lx\n", AllocInfo->Size));\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "======= SmramProfile end =======\n"));\r
+ DEBUG ((DEBUG_INFO, "======= SmramProfile end =======\n"));\r
\r
mSmramProfileGettingStatus = SmramProfileGettingStatus;\r
}\r
}\r
);\r
}\r
-\r
continue;\r
}\r
UnicodeSPrint (StrTemp, sizeof (StrTemp), L"%s%04x", Type, (UINTN) OptionNumber);\r
- DEBUG((EFI_D_ERROR,"Option = %s\n", StrTemp));\r
+ DEBUG((DEBUG_ERROR,"Option = %s\n", StrTemp));\r
GetEfiGlobalVariable2 (StrTemp, (VOID **) &OptionBuffer, &OptionSize);\r
if (NULL == OptionBuffer) {\r
//\r
{\r
return ReSendForm(FilePath, FORM_DRV_ADD_FILE_ID);\r
}\r
-\r
//\r
// Legacy Boot Option\r
//\r
- DEBUG ((EFI_D_ERROR, "[BootManagerDxe] ==== Find Legacy Boot Option 0x%x! ==== \n", Index));\r
+ DEBUG ((DEBUG_ERROR, "[BootManagerDxe] ==== Find Legacy Boot Option 0x%x! ==== \n", Index));\r
ASSERT ((((BBS_BBS_DEVICE_PATH *) BootOption.FilePath)->DeviceType & 0xF) < ARRAY_SIZE (DeviceTypeIndex));\r
NextIndex = &DeviceTypeIndex[((BBS_BBS_DEVICE_PATH *) BootOption.FilePath)->DeviceType & 0xF];\r
\r
\r
return EFI_SUCCESS;\r
}\r
-\r
//\r
// Dxe Ipmi Protocol is not installed. So, IPMI device is not present.\r
//\r
- DEBUG ((EFI_D_ERROR, "IpmiSubmitCommand in Dxe Phase under SMS Status - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "IpmiSubmitCommand in Dxe Phase under SMS Status - %r\n", Status));\r
return EFI_NOT_FOUND;\r
}\r
}\r
// BltBuffer to Video: Source is BltBuffer, destination is Video\r
//\r
if (DestinationY + Height > Configure->Height) {\r
- DEBUG ((EFI_D_VERBOSE, "VideoFill: Past screen (Y)\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "VideoFill: Past screen (Y)\n"));\r
return RETURN_INVALID_PARAMETER;\r
}\r
\r
if (DestinationX + Width > Configure->Width) {\r
- DEBUG ((EFI_D_VERBOSE, "VideoFill: Past screen (X)\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "VideoFill: Past screen (X)\n"));\r
return RETURN_INVALID_PARAMETER;\r
}\r
\r
if (Width == 0 || Height == 0) {\r
- DEBUG ((EFI_D_VERBOSE, "VideoFill: Width or Height is 0\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "VideoFill: Width or Height is 0\n"));\r
return RETURN_INVALID_PARAMETER;\r
}\r
\r
(((Uint32 << Configure->PixelShl[2]) >> Configure->PixelShr[2]) &\r
Configure->PixelMasks.BlueMask)\r
);\r
- DEBUG ((EFI_D_VERBOSE, "VideoFill: color=0x%x, wide-fill=0x%x\n",\r
+ DEBUG ((DEBUG_VERBOSE, "VideoFill: color=0x%x, wide-fill=0x%x\n",\r
Uint32, WideFill));\r
\r
//\r
}\r
\r
if (UseWideFill && (DestinationX == 0) && (Width == Configure->PixelsPerScanLine)) {\r
- DEBUG ((EFI_D_VERBOSE, "VideoFill (wide, one-shot)\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "VideoFill (wide, one-shot)\n"));\r
Offset = DestinationY * Configure->PixelsPerScanLine;\r
Offset = Configure->BytesPerPixel * Offset;\r
Destination = Configure->FrameBuffer + Offset;\r
Destination = Configure->FrameBuffer + Offset;\r
\r
if (UseWideFill && (((UINTN) Destination & 7) == 0)) {\r
- DEBUG ((EFI_D_VERBOSE, "VideoFill (wide)\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "VideoFill (wide)\n"));\r
SizeInBytes = WidthInBytes;\r
if (SizeInBytes >= 8) {\r
SetMem64 (Destination, SizeInBytes & ~7, WideFill);\r
CopyMem (Destination, &WideFill, SizeInBytes);\r
}\r
} else {\r
- DEBUG ((EFI_D_VERBOSE, "VideoFill (not wide)\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "VideoFill (not wide)\n"));\r
if (!LineBufferReady) {\r
CopyMem (Configure->LineBuffer, &WideFill, Configure->BytesPerPixel);\r
for (IndexX = 1; IndexX < Width; ) {\r
{\r
EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR *Descriptor;\r
UINTN RootBridgeIndex;\r
- DEBUG ((EFI_D_ERROR, "PciHostBridge: Resource conflict happens!\n"));\r
+ DEBUG ((DEBUG_ERROR, "PciHostBridge: Resource conflict happens!\n"));\r
\r
RootBridgeIndex = 0;\r
Descriptor = (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR *) Configuration;\r
while (Descriptor->Desc == ACPI_ADDRESS_SPACE_DESCRIPTOR) {\r
- DEBUG ((EFI_D_ERROR, "RootBridge[%d]:\n", RootBridgeIndex++));\r
+ DEBUG ((DEBUG_ERROR, "RootBridge[%d]:\n", RootBridgeIndex++));\r
for (; Descriptor->Desc == ACPI_ADDRESS_SPACE_DESCRIPTOR; Descriptor++) {\r
ASSERT (Descriptor->ResType <\r
(sizeof (mPciHostBridgeLibAcpiAddressSpaceTypeStr) /\r
sizeof (mPciHostBridgeLibAcpiAddressSpaceTypeStr[0])\r
)\r
);\r
- DEBUG ((EFI_D_ERROR, " %s: Length/Alignment = 0x%lx / 0x%lx\n",\r
+ DEBUG ((DEBUG_ERROR, " %s: Length/Alignment = 0x%lx / 0x%lx\n",\r
mPciHostBridgeLibAcpiAddressSpaceTypeStr[Descriptor->ResType],\r
Descriptor->AddrLen, Descriptor->AddrRangeMax\r
));\r
if (Descriptor->ResType == ACPI_ADDRESS_SPACE_TYPE_MEM) {\r
- DEBUG ((EFI_D_ERROR, " Granularity/SpecificFlag = %ld / %02x%s\n",\r
+ DEBUG ((DEBUG_ERROR, " Granularity/SpecificFlag = %ld / %02x%s\n",\r
Descriptor->AddrSpaceGranularity, Descriptor->SpecificFlag,\r
((Descriptor->SpecificFlag &\r
EFI_ACPI_MEMORY_RESOURCE_SPECIFIC_FLAG_CACHEABLE_PREFETCHABLE\r
//\r
// Ipmi Ppi is not installed. So, IPMI device is not present.\r
//\r
- DEBUG ((EFI_D_ERROR, "IpmiSubmitCommand in Pei Phase under SMS Status - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "IpmiSubmitCommand in Pei Phase under SMS Status - %r\n", Status));\r
return EFI_NOT_FOUND;\r
}\r
\r
// The local variable Buffer not large enough to hold the extended data associated\r
// with the status code being reported.\r
//\r
- DEBUG ((EFI_D_ERROR, "Status code extended data is too large to be reported!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Status code extended data is too large to be reported!\n"));\r
return EFI_OUT_OF_RESOURCES;\r
}\r
StatusCodeData = (EFI_STATUS_CODE_DATA *) Buffer;\r
\r
switch (Operation) {\r
case EfiSmbusQuickRead:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusQuickRead - 0x%08x\n", SmbusAddress));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusQuickRead - 0x%08x\n", SmbusAddress));\r
SmBusQuickRead (SmbusAddress, &Status);\r
break;\r
case EfiSmbusQuickWrite:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusQuickWrite - 0x%08x\n", SmbusAddress));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusQuickWrite - 0x%08x\n", SmbusAddress));\r
SmBusQuickWrite (SmbusAddress, &Status);\r
break;\r
case EfiSmbusReceiveByte:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusReceiveByte - 0x%08x\n", SmbusAddress));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusReceiveByte - 0x%08x\n", SmbusAddress));\r
SmBusReceiveByte (SmbusAddress, &Status);\r
break;\r
case EfiSmbusSendByte:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusSendByte - 0x%08x (0x%02x)\n", SmbusAddress, (UINTN)*(UINT8 *) Buffer));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusSendByte - 0x%08x (0x%02x)\n", SmbusAddress, (UINTN)*(UINT8 *) Buffer));\r
SmBusSendByte (SmbusAddress, *(UINT8 *) Buffer, &Status);\r
break;\r
case EfiSmbusReadByte:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusReadByte - 0x%08x\n", SmbusAddress));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusReadByte - 0x%08x\n", SmbusAddress));\r
SmBusReadDataByte (SmbusAddress, &Status);\r
break;\r
case EfiSmbusWriteByte:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusWriteByte - 0x%08x (0x%02x)\n", SmbusAddress, (UINTN)*(UINT8 *) Buffer));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusWriteByte - 0x%08x (0x%02x)\n", SmbusAddress, (UINTN)*(UINT8 *) Buffer));\r
SmBusWriteDataByte (SmbusAddress, *(UINT8 *) Buffer, &Status);\r
break;\r
case EfiSmbusReadWord:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusReadWord - 0x%08x\n", SmbusAddress));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusReadWord - 0x%08x\n", SmbusAddress));\r
SmBusReadDataWord (SmbusAddress, &Status);\r
break;\r
case EfiSmbusWriteWord:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusWriteWord - 0x%08x (0x%04x)\n", SmbusAddress, (UINTN)*(UINT16 *) Buffer));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusWriteWord - 0x%08x (0x%04x)\n", SmbusAddress, (UINTN)*(UINT16 *) Buffer));\r
SmBusWriteDataWord (SmbusAddress, *(UINT16 *) Buffer, &Status);\r
break;\r
case EfiSmbusProcessCall:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusProcessCall - 0x%08x (0x%04x)\n", SmbusAddress, (UINTN)*(UINT16 *) Buffer));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusProcessCall - 0x%08x (0x%04x)\n", SmbusAddress, (UINTN)*(UINT16 *) Buffer));\r
SmBusProcessCall (SmbusAddress, *(UINT16 *) Buffer, &Status);\r
break;\r
case EfiSmbusReadBlock:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusReadBlock - 0x%08x\n", SmbusAddress));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusReadBlock - 0x%08x\n", SmbusAddress));\r
SmBusReadBlock (SmbusAddress, WorkBuffer, &Status);\r
break;\r
case EfiSmbusWriteBlock:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusWriteBlock - 0x%08x\n", SmbusAddress));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusWriteBlock - 0x%08x\n", SmbusAddress));\r
SmBusWriteBlock ((SmbusAddress + SMBUS_LIB_ADDRESS (0, 0, (*Length), FALSE)), Buffer, &Status);\r
break;\r
case EfiSmbusBWBRProcessCall:\r
- DEBUG ((EFI_D_INFO, "EfiSmbusBWBRProcessCall - 0x%08x\n", SmbusAddress));\r
+ DEBUG ((DEBUG_INFO, "EfiSmbusBWBRProcessCall - 0x%08x\n", SmbusAddress));\r
SmBusBlockProcessCall ((SmbusAddress + SMBUS_LIB_ADDRESS (0, 0, (*Length), FALSE)), Buffer, WorkBuffer, &Status);\r
break;\r
default:\r
switch (Width) {\r
\r
case S3BootScriptWidthUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint8 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint8 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint8 = IoRead8 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFifoUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint8 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint8 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint8 = IoRead8 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFillUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint8 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint8 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint8 = IoRead8 ((UINTN) Address);\r
break;\r
\r
case S3BootScriptWidthUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint16 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint16 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint16 = IoRead16 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFifoUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint16 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint16 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint16 = IoRead16 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFillUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint16 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint16 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint16 = IoRead16 ((UINTN) Address);\r
break;\r
\r
case S3BootScriptWidthUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint32 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint32 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint32 = IoRead32 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFifoUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint32 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint32 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint32 = IoRead32 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFillUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint32 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint32 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint32 = IoRead32 ((UINTN) Address);\r
break;\r
\r
case S3BootScriptWidthUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint64 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint64 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint64 = IoRead64 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFifoUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint64 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint64 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint64 = IoRead64 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFillUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint64 - 0x%08x\n", (UINTN) Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint64 - 0x%08x\n", (UINTN) Address));\r
*Out.Uint64 = IoRead64 ((UINTN) Address);\r
break;\r
\r
for (; Count > 0; Count--, Address += AddressStride, In.Buf += BufferStride) {\r
switch (Width) {\r
case S3BootScriptWidthUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint8 - 0x%08x (0x%02x)\n", (UINTN)Address, (UINTN)*In.Uint8));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint8 - 0x%08x (0x%02x)\n", (UINTN)Address, (UINTN)*In.Uint8));\r
IoWrite8 ((UINTN) Address, *In.Uint8);\r
break;\r
case S3BootScriptWidthFifoUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint8 - 0x%08x (0x%02x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint8));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint8 - 0x%08x (0x%02x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint8));\r
IoWrite8 ((UINTN) OriginalAddress, *In.Uint8);\r
break;\r
case S3BootScriptWidthFillUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint8 - 0x%08x (0x%02x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint8));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint8 - 0x%08x (0x%02x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint8));\r
IoWrite8 ((UINTN) Address, *OriginalIn.Uint8);\r
break;\r
case S3BootScriptWidthUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint16 - 0x%08x (0x%04x)\n", (UINTN)Address, (UINTN)*In.Uint16));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint16 - 0x%08x (0x%04x)\n", (UINTN)Address, (UINTN)*In.Uint16));\r
IoWrite16 ((UINTN) Address, *In.Uint16);\r
break;\r
case S3BootScriptWidthFifoUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint16 - 0x%08x (0x%04x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint16));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint16 - 0x%08x (0x%04x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint16));\r
IoWrite16 ((UINTN) OriginalAddress, *In.Uint16);\r
break;\r
case S3BootScriptWidthFillUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint16 - 0x%08x (0x%04x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint16));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint16 - 0x%08x (0x%04x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint16));\r
IoWrite16 ((UINTN) Address, *OriginalIn.Uint16);\r
break;\r
case S3BootScriptWidthUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint32 - 0x%08x (0x%08x)\n", (UINTN)Address, (UINTN)*In.Uint32));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint32 - 0x%08x (0x%08x)\n", (UINTN)Address, (UINTN)*In.Uint32));\r
IoWrite32 ((UINTN) Address, *In.Uint32);\r
break;\r
case S3BootScriptWidthFifoUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint32 - 0x%08x (0x%08x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint32));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint32 - 0x%08x (0x%08x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint32));\r
IoWrite32 ((UINTN) OriginalAddress, *In.Uint32);\r
break;\r
case S3BootScriptWidthFillUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint32 - 0x%08x (0x%08x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint32));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint32 - 0x%08x (0x%08x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint32));\r
IoWrite32 ((UINTN) Address, *OriginalIn.Uint32);\r
break;\r
case S3BootScriptWidthUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint64 - 0x%08x (0x%016lx)\n", (UINTN)Address, *In.Uint64));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint64 - 0x%08x (0x%016lx)\n", (UINTN)Address, *In.Uint64));\r
IoWrite64 ((UINTN) Address, *In.Uint64);\r
break;\r
case S3BootScriptWidthFifoUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint64 - 0x%08x (0x%016lx)\n", (UINTN)OriginalAddress, *In.Uint64));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint64 - 0x%08x (0x%016lx)\n", (UINTN)OriginalAddress, *In.Uint64));\r
IoWrite64 ((UINTN) OriginalAddress, *In.Uint64);\r
break;\r
case S3BootScriptWidthFillUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint64 - 0x%08x (0x%016lx)\n", (UINTN)Address, *OriginalIn.Uint64));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint64 - 0x%08x (0x%016lx)\n", (UINTN)Address, *OriginalIn.Uint64));\r
IoWrite64 ((UINTN) Address, *OriginalIn.Uint64);\r
break;\r
default:\r
Count = IoWrite.Count;\r
Buffer = Script + sizeof (EFI_BOOT_SCRIPT_IO_WRITE);\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteIoWrite - 0x%08x, 0x%08x, 0x%08x\n", (UINTN)Address, Count, (UINTN)Width));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteIoWrite - 0x%08x, 0x%08x, 0x%08x\n", (UINTN)Address, Count, (UINTN)Width));\r
return ScriptIoWrite(Width, Address, Count, Buffer);\r
}\r
/**\r
for (; Count > 0; Count--, Address += AddressStride, Out.Buf += BufferStride) {\r
switch (Width) {\r
case S3BootScriptWidthUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint8 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint8 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint8 = MmioRead8 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFifoUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint8 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint8 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint8 = MmioRead8 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFillUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint8 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint8 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint8 = MmioRead8 ((UINTN) Address);\r
break;\r
\r
case S3BootScriptWidthUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint16 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint16 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint16 = MmioRead16 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFifoUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint16 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint16 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint16 = MmioRead16 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFillUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint16 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint16 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint16 = MmioRead16 ((UINTN) Address);\r
break;\r
\r
case S3BootScriptWidthUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint32 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint32 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint32 = MmioRead32 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFifoUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint32 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint32 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint32 = MmioRead32 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFillUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint32 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint32 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint32 = MmioRead32 ((UINTN) Address);\r
break;\r
\r
case S3BootScriptWidthUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint64 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint64 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint64 = MmioRead64 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFifoUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint64 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint64 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint64 = MmioRead64 ((UINTN) Address);\r
break;\r
case S3BootScriptWidthFillUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint64 - 0x%08x\n", (UINTN)Address));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint64 - 0x%08x\n", (UINTN)Address));\r
*Out.Uint64 = MmioRead64 ((UINTN) Address);\r
break;\r
\r
for (; Count > 0; Count--, Address += AddressStride, In.Buf += BufferStride) {\r
switch (Width) {\r
case S3BootScriptWidthUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint8 - 0x%08x (0x%02x)\n", (UINTN)Address, (UINTN)*In.Uint8));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint8 - 0x%08x (0x%02x)\n", (UINTN)Address, (UINTN)*In.Uint8));\r
MmioWrite8 ((UINTN) Address, *In.Uint8);\r
break;\r
case S3BootScriptWidthFifoUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint8 - 0x%08x (0x%02x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint8));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint8 - 0x%08x (0x%02x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint8));\r
MmioWrite8 ((UINTN) OriginalAddress, *In.Uint8);\r
break;\r
case S3BootScriptWidthFillUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint8 - 0x%08x (0x%02x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint8));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint8 - 0x%08x (0x%02x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint8));\r
MmioWrite8 ((UINTN) Address, *OriginalIn.Uint8);\r
break;\r
case S3BootScriptWidthUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint16 - 0x%08x (0x%04x)\n", (UINTN)Address, (UINTN)*In.Uint16));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint16 - 0x%08x (0x%04x)\n", (UINTN)Address, (UINTN)*In.Uint16));\r
MmioWrite16 ((UINTN) Address, *In.Uint16);\r
break;\r
case S3BootScriptWidthFifoUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint16 - 0x%08x (0x%04x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint16));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint16 - 0x%08x (0x%04x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint16));\r
MmioWrite16 ((UINTN) OriginalAddress, *In.Uint16);\r
break;\r
case S3BootScriptWidthFillUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint16 - 0x%08x (0x%04x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint16));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint16 - 0x%08x (0x%04x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint16));\r
MmioWrite16 ((UINTN) Address, *OriginalIn.Uint16);\r
break;\r
case S3BootScriptWidthUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint32 - 0x%08x (0x%08x)\n", (UINTN)Address, (UINTN)*In.Uint32));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint32 - 0x%08x (0x%08x)\n", (UINTN)Address, (UINTN)*In.Uint32));\r
MmioWrite32 ((UINTN) Address, *In.Uint32);\r
break;\r
case S3BootScriptWidthFifoUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint32 - 0x%08x (0x%08x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint32));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint32 - 0x%08x (0x%08x)\n", (UINTN)OriginalAddress, (UINTN)*In.Uint32));\r
MmioWrite32 ((UINTN) OriginalAddress, *In.Uint32);\r
break;\r
case S3BootScriptWidthFillUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint32 - 0x%08x (0x%08x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint32));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint32 - 0x%08x (0x%08x)\n", (UINTN)Address, (UINTN)*OriginalIn.Uint32));\r
MmioWrite32 ((UINTN) Address, *OriginalIn.Uint32);\r
break;\r
case S3BootScriptWidthUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint64 - 0x%08x (0x%016lx)\n", (UINTN)Address, *In.Uint64));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint64 - 0x%08x (0x%016lx)\n", (UINTN)Address, *In.Uint64));\r
MmioWrite64 ((UINTN) Address, *In.Uint64);\r
break;\r
case S3BootScriptWidthFifoUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint64 - 0x%08x (0x%016lx)\n", (UINTN)OriginalAddress, *In.Uint64));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint64 - 0x%08x (0x%016lx)\n", (UINTN)OriginalAddress, *In.Uint64));\r
MmioWrite64 ((UINTN) OriginalAddress, *In.Uint64);\r
break;\r
case S3BootScriptWidthFillUint64:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint64 - 0x%08x (0x%016lx)\n", (UINTN)Address, *OriginalIn.Uint64));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint64 - 0x%08x (0x%016lx)\n", (UINTN)Address, *OriginalIn.Uint64));\r
MmioWrite64 ((UINTN) Address, *OriginalIn.Uint64);\r
break;\r
default:\r
Count = MemWrite.Count;\r
Buffer = Script + sizeof(EFI_BOOT_SCRIPT_MEM_WRITE);\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteMemoryWrite - 0x%08x, 0x%08x, 0x%08x\n", (UINTN)Address, Count, (UINTN)Width));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteMemoryWrite - 0x%08x, 0x%08x, 0x%08x\n", (UINTN)Address, Count, (UINTN)Width));\r
return ScriptMemoryWrite (Width,Address, Count, Buffer);\r
\r
}\r
for (; Count > 0; Count--, PciAddress += AddressStride, Out.Buf += BufferStride) {\r
switch (Width) {\r
case S3BootScriptWidthUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint8 - 0x%016lx\n", PciAddress));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint8 - 0x%016lx\n", PciAddress));\r
*Out.Uint8 = PciSegmentRead8 (PciAddress);\r
break;\r
case S3BootScriptWidthFifoUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint8 - 0x%016lx\n", PciAddress));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint8 - 0x%016lx\n", PciAddress));\r
*Out.Uint8 = PciSegmentRead8 (PciAddress);\r
break;\r
case S3BootScriptWidthFillUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint8 - 0x%016lx\n", PciAddress));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint8 - 0x%016lx\n", PciAddress));\r
*Out.Uint8 = PciSegmentRead8 (PciAddress);\r
break;\r
\r
case S3BootScriptWidthUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint16 - 0x%016lx\n", PciAddress));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint16 - 0x%016lx\n", PciAddress));\r
*Out.Uint16 = PciSegmentRead16 (PciAddress);\r
break;\r
case S3BootScriptWidthFifoUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint16 - 0x%016lx\n", PciAddress));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint16 - 0x%016lx\n", PciAddress));\r
*Out.Uint16 = PciSegmentRead16 (PciAddress);\r
break;\r
case S3BootScriptWidthFillUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint16 - 0x%016lx\n", PciAddress));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint16 - 0x%016lx\n", PciAddress));\r
*Out.Uint16 = PciSegmentRead16 (PciAddress);\r
break;\r
\r
case S3BootScriptWidthUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint32 - 0x%016lx\n", PciAddress));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint32 - 0x%016lx\n", PciAddress));\r
*Out.Uint32 = PciSegmentRead32 (PciAddress);\r
break;\r
case S3BootScriptWidthFifoUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint32 - 0x%016lx\n", PciAddress));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint32 - 0x%016lx\n", PciAddress));\r
*Out.Uint32 = PciSegmentRead32 (PciAddress);\r
break;\r
case S3BootScriptWidthFillUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint32 - 0x%016lx\n", PciAddress));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint32 - 0x%016lx\n", PciAddress));\r
*Out.Uint32 = PciSegmentRead32 (PciAddress);\r
break;\r
\r
for (; Count > 0; Count--, PciAddress += AddressStride, In.Buf += BufferStride) {\r
switch (Width) {\r
case S3BootScriptWidthUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint8 - 0x%016lx (0x%02x)\n", PciAddress, (UINTN)*In.Uint8));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint8 - 0x%016lx (0x%02x)\n", PciAddress, (UINTN)*In.Uint8));\r
PciSegmentWrite8 (PciAddress, *In.Uint8);\r
break;\r
case S3BootScriptWidthFifoUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint8 - 0x%016lx (0x%02x)\n", OriginalPciAddress, (UINTN)*In.Uint8));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint8 - 0x%016lx (0x%02x)\n", OriginalPciAddress, (UINTN)*In.Uint8));\r
PciSegmentWrite8 (OriginalPciAddress, *In.Uint8);\r
break;\r
case S3BootScriptWidthFillUint8:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint8 - 0x%016lx (0x%02x)\n", PciAddress, (UINTN)*OriginalIn.Uint8));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint8 - 0x%016lx (0x%02x)\n", PciAddress, (UINTN)*OriginalIn.Uint8));\r
PciSegmentWrite8 (PciAddress, *OriginalIn.Uint8);\r
break;\r
case S3BootScriptWidthUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint16 - 0x%016lx (0x%04x)\n", PciAddress, (UINTN)*In.Uint16));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint16 - 0x%016lx (0x%04x)\n", PciAddress, (UINTN)*In.Uint16));\r
PciSegmentWrite16 (PciAddress, *In.Uint16);\r
break;\r
case S3BootScriptWidthFifoUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint16 - 0x%016lx (0x%04x)\n", OriginalPciAddress, (UINTN)*In.Uint16));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint16 - 0x%016lx (0x%04x)\n", OriginalPciAddress, (UINTN)*In.Uint16));\r
PciSegmentWrite16 (OriginalPciAddress, *In.Uint16);\r
break;\r
case S3BootScriptWidthFillUint16:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint16 - 0x%016lx (0x%04x)\n", PciAddress, (UINTN)*OriginalIn.Uint16));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint16 - 0x%016lx (0x%04x)\n", PciAddress, (UINTN)*OriginalIn.Uint16));\r
PciSegmentWrite16 (PciAddress, *OriginalIn.Uint16);\r
break;\r
case S3BootScriptWidthUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthUint32 - 0x%016lx (0x%08x)\n", PciAddress, (UINTN)*In.Uint32));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthUint32 - 0x%016lx (0x%08x)\n", PciAddress, (UINTN)*In.Uint32));\r
PciSegmentWrite32 (PciAddress, *In.Uint32);\r
break;\r
case S3BootScriptWidthFifoUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFifoUint32 - 0x%016lx (0x%08x)\n", OriginalPciAddress, (UINTN)*In.Uint32));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFifoUint32 - 0x%016lx (0x%08x)\n", OriginalPciAddress, (UINTN)*In.Uint32));\r
PciSegmentWrite32 (OriginalPciAddress, *In.Uint32);\r
break;\r
case S3BootScriptWidthFillUint32:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptWidthFillUint32 - 0x%016lx (0x%08x)\n", (UINTN)PciAddress, (UINTN)*OriginalIn.Uint32));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptWidthFillUint32 - 0x%016lx (0x%08x)\n", (UINTN)PciAddress, (UINTN)*OriginalIn.Uint32));\r
PciSegmentWrite32 (PciAddress, *OriginalIn.Uint32);\r
break;\r
default:\r
Count = PciCfgWrite.Count;\r
Buffer = Script + sizeof(EFI_BOOT_SCRIPT_PCI_CONFIG_WRITE);\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecutePciCfgWrite - 0x%016lx, 0x%08x, 0x%08x\n", PCI_ADDRESS_ENCODE (0, Address), Count, (UINTN)Width));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecutePciCfgWrite - 0x%016lx, 0x%08x, 0x%08x\n", PCI_ADDRESS_ENCODE (0, Address), Count, (UINTN)Width));\r
return ScriptPciCfgWrite (Width, Address, Count, Buffer);\r
}\r
/**\r
\r
CopyMem((VOID*)&IoReadWrite, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_IO_READ_WRITE));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteIoReadWrite - 0x%08x, 0x%016lx, 0x%016lx\n", (UINTN)IoReadWrite.Address, AndMask, OrMask));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteIoReadWrite - 0x%08x, 0x%016lx, 0x%016lx\n", (UINTN)IoReadWrite.Address, AndMask, OrMask));\r
\r
Status = ScriptIoRead (\r
(S3_BOOT_SCRIPT_LIB_WIDTH) IoReadWrite.Width,\r
\r
CopyMem((VOID*)&MemReadWrite, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_MEM_READ_WRITE));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteMemoryReadWrite - 0x%08x, 0x%016lx, 0x%016lx\n", (UINTN)MemReadWrite.Address, AndMask, OrMask));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteMemoryReadWrite - 0x%08x, 0x%016lx, 0x%016lx\n", (UINTN)MemReadWrite.Address, AndMask, OrMask));\r
\r
Status = ScriptMemoryRead (\r
(S3_BOOT_SCRIPT_LIB_WIDTH) MemReadWrite.Width,\r
\r
CopyMem((VOID*)&PciCfgReadWrite, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_PCI_CONFIG_READ_WRITE));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecutePciCfgReadWrite - 0x%016lx, 0x%016lx, 0x%016lx\n", PCI_ADDRESS_ENCODE (0, PciCfgReadWrite.Address), AndMask, OrMask));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecutePciCfgReadWrite - 0x%016lx, 0x%016lx, 0x%016lx\n", PCI_ADDRESS_ENCODE (0, PciCfgReadWrite.Address), AndMask, OrMask));\r
\r
Status = ScriptPciCfgRead (\r
(S3_BOOT_SCRIPT_LIB_WIDTH) PciCfgReadWrite.Width,\r
\r
CopyMem ((VOID*)&SmbusExecuteEntry, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_SMBUS_EXECUTE ));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteSmbusExecute - 0x%08x, 0x%08x\n", (UINTN)SmbusExecuteEntry.SmBusAddress, (UINTN)SmbusExecuteEntry.Operation));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteSmbusExecute - 0x%08x, 0x%08x\n", (UINTN)SmbusExecuteEntry.SmBusAddress, (UINTN)SmbusExecuteEntry.Operation));\r
\r
SmBusAddress = (UINTN)SmbusExecuteEntry.SmBusAddress;\r
DataSize = (UINTN) SmbusExecuteEntry.DataSize;\r
\r
CopyMem ((VOID*)&Stall, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_STALL));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteStall - 0x%08x\n", (UINTN)Stall.Duration));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteStall - 0x%08x\n", (UINTN)Stall.Duration));\r
\r
MicroSecondDelay ((UINTN) Stall.Duration);\r
return EFI_SUCCESS;\r
CopyMem ((VOID*)&ScriptDispatch, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_DISPATCH));\r
EntryFunc = (DISPATCH_ENTRYPOINT_FUNC) (UINTN) (ScriptDispatch.EntryPoint);\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteDispatch - 0x%08x\n", (UINTN)ScriptDispatch.EntryPoint));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteDispatch - 0x%08x\n", (UINTN)ScriptDispatch.EntryPoint));\r
\r
Status = EntryFunc (NULL, NULL);\r
\r
\r
CopyMem ((VOID*)&ScriptDispatch2, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_DISPATCH_2));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteDispatch2 - 0x%08x(0x%08x)\n", (UINTN)ScriptDispatch2.EntryPoint, (UINTN)ScriptDispatch2.Context));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteDispatch2 - 0x%08x(0x%08x)\n", (UINTN)ScriptDispatch2.EntryPoint, (UINTN)ScriptDispatch2.Context));\r
\r
EntryFunc = (DISPATCH_ENTRYPOINT_FUNC) (UINTN) (ScriptDispatch2.EntryPoint);\r
\r
\r
CopyMem ((VOID*)&MemPoll, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_MEM_POLL));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteMemPoll - 0x%08x, 0x%016lx, 0x%016lx\n", (UINTN)MemPoll.Address, AndMask, OrMask));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteMemPoll - 0x%08x, 0x%016lx, 0x%016lx\n", (UINTN)MemPoll.Address, AndMask, OrMask));\r
\r
Data = 0;\r
Status = ScriptMemoryRead (\r
CopyMem ((VOID*)&Information, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_INFORMATION));\r
\r
InformationData = Script + sizeof (EFI_BOOT_SCRIPT_INFORMATION);\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteInformation - 0x%08x\n", (UINTN) InformationData));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteInformation - 0x%08x\n", (UINTN) InformationData));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptInformation: "));\r
+ DEBUG ((DEBUG_INFO, "BootScriptInformation: "));\r
for (Index = 0; Index < Information.InformationLength; Index++) {\r
- DEBUG ((EFI_D_INFO, "%02x ", InformationData[Index]));\r
+ DEBUG ((DEBUG_INFO, "%02x ", InformationData[Index]));\r
}\r
- DEBUG ((EFI_D_INFO, "\n"));\r
+ DEBUG ((DEBUG_INFO, "\n"));\r
}\r
\r
/**\r
CopyMem ((VOID*)&Information, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_INFORMATION));\r
\r
InformationData = Script + sizeof (EFI_BOOT_SCRIPT_INFORMATION);\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteLabel - 0x%08x\n", (UINTN) InformationData));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteLabel - 0x%08x\n", (UINTN) InformationData));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptLabel: "));\r
+ DEBUG ((DEBUG_INFO, "BootScriptLabel: "));\r
for (Index = 0; Index < Information.InformationLength; Index++) {\r
- DEBUG ((EFI_D_INFO, "%02x ", InformationData[Index]));\r
+ DEBUG ((DEBUG_INFO, "%02x ", InformationData[Index]));\r
}\r
- DEBUG ((EFI_D_INFO, "\n"));\r
+ DEBUG ((DEBUG_INFO, "\n"));\r
}\r
\r
/**\r
\r
CopyMem ((VOID*)&IoPoll, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_IO_POLL));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecuteIoPoll - 0x%08x, 0x%016lx, 0x%016lx\n", (UINTN)IoPoll.Address, AndMask, OrMask));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecuteIoPoll - 0x%08x, 0x%016lx, 0x%016lx\n", (UINTN)IoPoll.Address, AndMask, OrMask));\r
\r
Data = 0;\r
Status = ScriptIoRead (\r
Count = PciCfg2Write.Count;\r
Buffer = Script + sizeof(EFI_BOOT_SCRIPT_PCI_CONFIG2_WRITE);\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecutePciCfg2Write - 0x%016lx, 0x%08x, 0x%08x\n", PCI_ADDRESS_ENCODE (Segment, Address), Count, (UINTN)Width));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecutePciCfg2Write - 0x%016lx, 0x%08x, 0x%08x\n", PCI_ADDRESS_ENCODE (Segment, Address), Count, (UINTN)Width));\r
return ScriptPciCfg2Write (Width, Segment, Address, Count, Buffer);\r
}\r
\r
\r
CopyMem ((VOID*)&PciCfg2ReadWrite, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_PCI_CONFIG2_READ_WRITE));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptExecutePciCfg2ReadWrite - 0x%016lx, 0x%016lx, 0x%016lx\n", PCI_ADDRESS_ENCODE (PciCfg2ReadWrite.Segment, PciCfg2ReadWrite.Address), AndMask, OrMask));\r
+ DEBUG ((DEBUG_INFO, "BootScriptExecutePciCfg2ReadWrite - 0x%016lx, 0x%016lx, 0x%016lx\n", PCI_ADDRESS_ENCODE (PciCfg2ReadWrite.Segment, PciCfg2ReadWrite.Address), AndMask, OrMask));\r
\r
Status = ScriptPciCfg2Read (\r
(S3_BOOT_SCRIPT_LIB_WIDTH) PciCfg2ReadWrite.Width,\r
EFI_BOOT_SCRIPT_PCI_CONFIG_POLL PciCfgPoll;\r
CopyMem ((VOID*)&PciCfgPoll, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_PCI_CONFIG_POLL));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptPciCfgPoll - 0x%016lx, 0x%016lx, 0x%016lx\n", PCI_ADDRESS_ENCODE (0, PciCfgPoll.Address), AndMask, OrMask));\r
+ DEBUG ((DEBUG_INFO, "BootScriptPciCfgPoll - 0x%016lx, 0x%016lx, 0x%016lx\n", PCI_ADDRESS_ENCODE (0, PciCfgPoll.Address), AndMask, OrMask));\r
\r
Data = 0;\r
Status = ScriptPciCfgRead (\r
Data = 0;\r
CopyMem ((VOID*)&PciCfg2Poll, (VOID*)Script, sizeof(EFI_BOOT_SCRIPT_PCI_CONFIG2_POLL));\r
\r
- DEBUG ((EFI_D_INFO, "BootScriptPciCfg2Poll - 0x%016lx, 0x%016lx, 0x%016lx\n", PCI_ADDRESS_ENCODE (PciCfg2Poll.Segment, PciCfg2Poll.Address), AndMask, OrMask));\r
+ DEBUG ((DEBUG_INFO, "BootScriptPciCfg2Poll - 0x%016lx, 0x%016lx, 0x%016lx\n", PCI_ADDRESS_ENCODE (PciCfg2Poll.Segment, PciCfg2Poll.Address), AndMask, OrMask));\r
\r
Status = ScriptPciCfg2Read (\r
(S3_BOOT_SCRIPT_LIB_WIDTH) PciCfg2Poll.Width,\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "S3BootScriptExecute:\n"));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptExecute:\n"));\r
if (TableHeader.OpCode != S3_BOOT_SCRIPT_LIB_TABLE_OPCODE) {\r
return EFI_UNSUPPORTED;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "TableHeader - 0x%08x\n", Script));\r
+ DEBUG ((DEBUG_INFO, "TableHeader - 0x%08x\n", Script));\r
\r
StartAddress = (UINTN) Script;\r
TableLength = TableHeader.TableLength;\r
AndMask = 0;\r
OrMask = 0;\r
\r
- DEBUG ((EFI_D_INFO, "TableHeader.Version - 0x%04x\n", (UINTN)TableHeader.Version));\r
- DEBUG ((EFI_D_INFO, "TableHeader.TableLength - 0x%08x\n", (UINTN)TableLength));\r
+ DEBUG ((DEBUG_INFO, "TableHeader.Version - 0x%04x\n", (UINTN)TableHeader.Version));\r
+ DEBUG ((DEBUG_INFO, "TableHeader.TableLength - 0x%08x\n", (UINTN)TableLength));\r
\r
while ((UINTN) Script < (UINTN) (StartAddress + TableLength)) {\r
- DEBUG ((EFI_D_INFO, "ExecuteBootScript - %08x\n", (UINTN)Script));\r
+ DEBUG ((DEBUG_INFO, "ExecuteBootScript - %08x\n", (UINTN)Script));\r
\r
CopyMem ((VOID*)&ScriptHeader, Script, sizeof(EFI_BOOT_SCRIPT_COMMON_HEADER));\r
switch (ScriptHeader.OpCode) {\r
\r
case EFI_BOOT_SCRIPT_MEM_WRITE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_MEM_WRITE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_MEM_WRITE_OPCODE\n"));\r
Status = BootScriptExecuteMemoryWrite (Script);\r
break;\r
\r
case EFI_BOOT_SCRIPT_MEM_READ_WRITE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_MEM_READ_WRITE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_MEM_READ_WRITE_OPCODE\n"));\r
CheckAndOrMask (&ScriptHeader, &AndMask, &OrMask, Script);\r
Status = BootScriptExecuteMemoryReadWrite (\r
Script,\r
break;\r
\r
case EFI_BOOT_SCRIPT_IO_WRITE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_IO_WRITE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_IO_WRITE_OPCODE\n"));\r
Status = BootScriptExecuteIoWrite (Script);\r
break;\r
\r
case EFI_BOOT_SCRIPT_PCI_CONFIG_WRITE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG_WRITE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG_WRITE_OPCODE\n"));\r
Status = BootScriptExecutePciCfgWrite (Script);\r
break;\r
\r
case EFI_BOOT_SCRIPT_PCI_CONFIG_READ_WRITE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG_READ_WRITE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG_READ_WRITE_OPCODE\n"));\r
CheckAndOrMask (&ScriptHeader, &AndMask, &OrMask, Script);\r
Status = BootScriptExecutePciCfgReadWrite (\r
Script,\r
);\r
break;\r
case EFI_BOOT_SCRIPT_PCI_CONFIG2_WRITE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG2_WRITE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG2_WRITE_OPCODE\n"));\r
Status = BootScriptExecutePciCfg2Write (Script);\r
break;\r
\r
case EFI_BOOT_SCRIPT_PCI_CONFIG2_READ_WRITE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG2_READ_WRITE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG2_READ_WRITE_OPCODE\n"));\r
CheckAndOrMask (&ScriptHeader, &AndMask, &OrMask, Script);\r
Status = BootScriptExecutePciCfg2ReadWrite (\r
Script,\r
);\r
break;\r
case EFI_BOOT_SCRIPT_DISPATCH_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_DISPATCH_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_DISPATCH_OPCODE\n"));\r
Status = BootScriptExecuteDispatch (Script);\r
break;\r
\r
case EFI_BOOT_SCRIPT_DISPATCH_2_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_DISPATCH_2_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_DISPATCH_2_OPCODE\n"));\r
Status = BootScriptExecuteDispatch2 (Script);\r
break;\r
\r
case EFI_BOOT_SCRIPT_INFORMATION_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_INFORMATION_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_INFORMATION_OPCODE\n"));\r
BootScriptExecuteInformation (Script);\r
break;\r
\r
case S3_BOOT_SCRIPT_LIB_TERMINATE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "S3_BOOT_SCRIPT_LIB_TERMINATE_OPCODE\n"));\r
- DEBUG ((EFI_D_INFO, "S3BootScriptDone - %r\n", EFI_SUCCESS));\r
+ DEBUG ((DEBUG_INFO, "S3_BOOT_SCRIPT_LIB_TERMINATE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptDone - %r\n", EFI_SUCCESS));\r
return EFI_SUCCESS;\r
\r
case EFI_BOOT_SCRIPT_IO_READ_WRITE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_IO_READ_WRITE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_IO_READ_WRITE_OPCODE\n"));\r
CheckAndOrMask (&ScriptHeader, &AndMask, &OrMask, Script);\r
Status = BootScriptExecuteIoReadWrite (\r
Script,\r
break;\r
\r
case EFI_BOOT_SCRIPT_SMBUS_EXECUTE_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_SMBUS_EXECUTE_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_SMBUS_EXECUTE_OPCODE\n"));\r
Status = BootScriptExecuteSmbusExecute (Script);\r
break;\r
\r
case EFI_BOOT_SCRIPT_STALL_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_STALL_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_STALL_OPCODE\n"));\r
Status = BootScriptExecuteStall (Script);\r
break;\r
\r
case EFI_BOOT_SCRIPT_MEM_POLL_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_MEM_POLL_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_MEM_POLL_OPCODE\n"));\r
CheckAndOrMask (&ScriptHeader, &AndMask, &OrMask, Script);\r
Status = BootScriptExecuteMemPoll (Script, AndMask, OrMask);\r
\r
break;\r
\r
case EFI_BOOT_SCRIPT_IO_POLL_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_IO_POLL_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_IO_POLL_OPCODE\n"));\r
CheckAndOrMask (&ScriptHeader, &AndMask, &OrMask, Script);\r
Status = BootScriptExecuteIoPoll (Script, AndMask, OrMask);\r
break;\r
\r
case EFI_BOOT_SCRIPT_PCI_CONFIG_POLL_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG_POLL_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG_POLL_OPCODE\n"));\r
CheckAndOrMask (&ScriptHeader, &AndMask, &OrMask, Script);\r
Status = BootScriptPciCfgPoll (Script, AndMask, OrMask);\r
break;\r
\r
case EFI_BOOT_SCRIPT_PCI_CONFIG2_POLL_OPCODE:\r
- DEBUG ((EFI_D_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG2_POLL_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "EFI_BOOT_SCRIPT_PCI_CONFIG2_POLL_OPCODE\n"));\r
CheckAndOrMask (&ScriptHeader, &AndMask, &OrMask, Script);\r
Status = BootScriptPciCfg2Poll (Script, AndMask, OrMask);\r
break;\r
//\r
// For label\r
//\r
- DEBUG ((EFI_D_INFO, "S3_BOOT_SCRIPT_LIB_LABEL_OPCODE\n"));\r
+ DEBUG ((DEBUG_INFO, "S3_BOOT_SCRIPT_LIB_LABEL_OPCODE\n"));\r
BootScriptExecuteLabel (Script);\r
break;\r
default:\r
- DEBUG ((EFI_D_INFO, "S3BootScriptDone - %r\n", EFI_UNSUPPORTED));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptDone - %r\n", EFI_UNSUPPORTED));\r
return EFI_UNSUPPORTED;\r
}\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "S3BootScriptDone - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptDone - %r\n", Status));\r
return Status;\r
}\r
\r
Script = Script + ScriptHeader.Length;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "S3BootScriptDone - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "S3BootScriptDone - %r\n", Status));\r
\r
return Status;\r
}\r
-\r
return RETURN_SUCCESS;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "%a() in %a module\n", __FUNCTION__, gEfiCallerBaseName));\r
+ DEBUG ((DEBUG_INFO, "%a() in %a module\n", __FUNCTION__, gEfiCallerBaseName));\r
\r
if (mEventDxeSmmReadyToLock != NULL) {\r
//\r
// Add DEBUG ERROR, so that we can find it after SmmReadyToLock.\r
// Do not use ASSERT, because we may have test to invoke this interface.\r
//\r
- DEBUG ((EFI_D_ERROR, "FATAL ERROR: Set boot script outside SMM after SmmReadyToLock!!!\n"));\r
+ DEBUG ((DEBUG_ERROR, "FATAL ERROR: Set boot script outside SMM after SmmReadyToLock!!!\n"));\r
return NULL;\r
}\r
\r
&ErrorFlag\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "%s - not found\n", VAR_ERROR_FLAG_NAME));\r
+ DEBUG ((DEBUG_INFO, "%s - not found\n", VAR_ERROR_FLAG_NAME));\r
return VAR_ERROR_FLAG_NO_ERROR;\r
}\r
return ErrorFlag;\r
//\r
// No property, it is user variable.\r
//\r
- DEBUG ((EFI_D_INFO, "PlatformVarCleanup - User variable: %g:%s\n", Guid, Name));\r
+ DEBUG ((DEBUG_INFO, "PlatformVarCleanup - User variable: %g:%s\n", Guid, Name));\r
return TRUE;\r
}\r
\r
-// DEBUG ((EFI_D_INFO, "PlatformVarCleanup - Variable Property: %g:%s\n", Guid, Name));\r
-// DEBUG ((EFI_D_INFO, " Revision - 0x%04x\n", Property.Revision));\r
-// DEBUG ((EFI_D_INFO, " Property - 0x%04x\n", Property.Property));\r
-// DEBUG ((EFI_D_INFO, " Attribute - 0x%08x\n", Property.Attributes));\r
-// DEBUG ((EFI_D_INFO, " MinSize - 0x%x\n", Property.MinSize));\r
-// DEBUG ((EFI_D_INFO, " MaxSize - 0x%x\n", Property.MaxSize));\r
+// DEBUG ((DEBUG_INFO, "PlatformVarCleanup - Variable Property: %g:%s\n", Guid, Name));\r
+// DEBUG ((DEBUG_INFO, " Revision - 0x%04x\n", Property.Revision));\r
+// DEBUG ((DEBUG_INFO, " Property - 0x%04x\n", Property.Property));\r
+// DEBUG ((DEBUG_INFO, " Attribute - 0x%08x\n", Property.Attributes));\r
+// DEBUG ((DEBUG_INFO, " MinSize - 0x%x\n", Property.MinSize));\r
+// DEBUG ((DEBUG_INFO, " MaxSize - 0x%x\n", Property.MaxSize));\r
\r
return FALSE;\r
}\r
\r
mUserVariableCount = Index;\r
ASSERT (mUserVariableCount <= MAX_USER_VARIABLE_COUNT);\r
- DEBUG ((EFI_D_INFO, "PlatformVarCleanup - User variable count: 0x%04x\n", mUserVariableCount));\r
+ DEBUG ((DEBUG_INFO, "PlatformVarCleanup - User variable count: 0x%04x\n", mUserVariableCount));\r
\r
FreePool (VarName);\r
FreePool (Data);\r
UserVariableNameNode = USER_VARIABLE_NAME_FROM_LINK (NameLink);\r
\r
if (!UserVariableNameNode->Deleted && (DeleteAll || ((VariableCleanupData != NULL) && (VariableCleanupData->UserVariable[UserVariableNameNode->Index] == TRUE)))) {\r
- DEBUG ((EFI_D_INFO, "PlatformVarCleanup - Delete variable: %g:%s\n", &UserVariableNode->Guid, UserVariableNameNode->Name));\r
+ DEBUG ((DEBUG_INFO, "PlatformVarCleanup - Delete variable: %g:%s\n", &UserVariableNode->Guid, UserVariableNameNode->Name));\r
if ((UserVariableNameNode->Attributes & EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS) != 0) {\r
DataSize = 0;\r
Data = NULL;\r
if (!EFI_ERROR (Status)) {\r
UserVariableNameNode->Deleted = TRUE;\r
} else {\r
- DEBUG ((EFI_D_INFO, "PlatformVarCleanup - Delete variable fail: %g:%s\n", &UserVariableNode->Guid, UserVariableNameNode->Name));\r
+ DEBUG ((DEBUG_INFO, "PlatformVarCleanup - Delete variable fail: %g:%s\n", &UserVariableNode->Guid, UserVariableNameNode->Name));\r
}\r
}\r
}\r
//\r
// This sample does not support system variables cleanup.\r
//\r
- DEBUG ((EFI_D_ERROR, "NOTICE - VAR_ERROR_FLAG_SYSTEM_ERROR\n"));\r
- DEBUG ((EFI_D_ERROR, "Platform should have mechanism to reset system to manufacture mode\n"));\r
+ DEBUG ((DEBUG_ERROR, "NOTICE - VAR_ERROR_FLAG_SYSTEM_ERROR\n"));\r
+ DEBUG ((DEBUG_ERROR, "Platform should have mechanism to reset system to manufacture mode\n"));\r
return EFI_UNSUPPORTED;\r
}\r
\r
EFI_STATUS Status;\r
\r
mLastVarErrorFlag = InternalGetVarErrorFlag ();\r
- DEBUG ((EFI_D_INFO, "mLastVarErrorFlag - 0x%02x\n", mLastVarErrorFlag));\r
+ DEBUG ((DEBUG_INFO, "mLastVarErrorFlag - 0x%02x\n", mLastVarErrorFlag));\r
\r
//\r
// Register EFI_END_OF_DXE_EVENT_GROUP_GUID event.\r
//\r
// Smm Ipmi Protocol is not installed. So, IPMI device is not present.\r
//\r
- DEBUG ((EFI_D_ERROR, "IpmiSubmitCommand for SMM Status - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "IpmiSubmitCommand for SMM Status - %r\n", Status));\r
return EFI_NOT_FOUND;\r
}\r
}\r
}\r
\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "[Bds] Failed to create Boot#### for a temporary boot - %r!\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "[Bds] Failed to create Boot#### for a temporary boot - %r!\n", Status));\r
BootOption->Status = Status;\r
return ;\r
}\r
// the boot option.\r
//\r
if (BmIsBootManagerMenuFilePath (BootOption->FilePath)) {\r
- DEBUG ((EFI_D_INFO, "[Bds] Booting Boot Manager Menu.\n"));\r
+ DEBUG ((DEBUG_INFO, "[Bds] Booting Boot Manager Menu.\n"));\r
BmStopHotkeyService (NULL, NULL);\r
} else {\r
EfiSignalEventReadyToBoot();\r
&DevicePath\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_WARN, "[Bds]BootManagerMenu FFS section can not be found, skip its boot option registration\n"));\r
+ DEBUG ((DEBUG_WARN, "[Bds]BootManagerMenu FFS section can not be found, skip its boot option registration\n"));\r
return EFI_NOT_FOUND;\r
}\r
ASSERT (DevicePath != NULL);\r
//\r
// Recursively look for GOP child in this frame buffer handle\r
//\r
- DEBUG ((EFI_D_INFO, "[Bds] Looking for GOP child deeper ... \n"));\r
+ DEBUG ((DEBUG_INFO, "[Bds] Looking for GOP child deeper ... \n"));\r
TempDevicePath = GopPool;\r
ReturnDevicePath = EfiBootManagerGetGopDevicePath (OpenInfoBuffer[Index].ControllerHandle);\r
GopPool = AppendDevicePathInstance (GopPool, ReturnDevicePath);\r
//\r
Instance = GetNextDevicePathInstance (&VarConsole, &DevicePathSize);\r
if (Instance == NULL) {\r
- DEBUG ((EFI_D_ERROR, "[Bds] No valid console instance is found for %s!\n", VarName));\r
+ DEBUG ((DEBUG_ERROR, "[Bds] No valid console instance is found for %s!\n", VarName));\r
// We should not ASSERT when all the console devices are removed.\r
// ASSERT_EFI_ERROR (EFI_NOT_FOUND);\r
FreePool (FullDevicePath);\r
DriverHealthInfo->ChildHandle\r
);\r
\r
- DEBUG ((EFI_D_INFO, "Controller: %s\n", ControllerName));\r
+ DEBUG ((DEBUG_INFO, "Controller: %s\n", ControllerName));\r
Print (L"Controller: %s\n", ControllerName);\r
for (Index = 0; DriverHealthInfo->MessageList[Index].HiiHandle != NULL; Index++) {\r
String = HiiGetString (\r
);\r
if (String != NULL) {\r
Print (L" %s\n", String);\r
- DEBUG ((EFI_D_INFO, " %s\n", String));\r
+ DEBUG ((DEBUG_INFO, " %s\n", String));\r
FreePool (String);\r
}\r
}\r
IN UINTN Limit\r
)\r
{\r
- DEBUG ((EFI_D_INFO, "[BDS]RepairNotify: %d/%d\n", Value, Limit));\r
+ DEBUG ((DEBUG_INFO, "[BDS]RepairNotify: %d/%d\n", Value, Limit));\r
Print (L"[BDS]RepairNotify: %d/%d\n", Value, Limit);\r
\r
return EFI_SUCCESS;\r
DriverHealthInfo[Index].ChildHandle\r
);\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"%02d: %s - %s\n",\r
Index,\r
ControllerName,\r
}\r
\r
if (RebootRequired) {\r
- DEBUG ((EFI_D_INFO, "[BDS] One of the Driver Health instances requires rebooting.\n"));\r
+ DEBUG ((DEBUG_INFO, "[BDS] One of the Driver Health instances requires rebooting.\n"));\r
gRT->ResetSystem (EfiResetWarm, EFI_SUCCESS, 0, NULL);\r
}\r
}\r
return EFI_SUCCESS;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "[Bds]BmHotkeyCallback: %04x:%04x\n", KeyData->Key.ScanCode, KeyData->Key.UnicodeChar));\r
+ DEBUG ((DEBUG_INFO, "[Bds]BmHotkeyCallback: %04x:%04x\n", KeyData->Key.ScanCode, KeyData->Key.UnicodeChar));\r
\r
EfiAcquireLock (&mBmHotkeyLock);\r
for ( Link = GetFirstNode (&mBmHotkeyList)\r
mBmLoadOptionName[LoadOptionTypeBoot], Hotkey->BootOption\r
);\r
Status = EfiBootManagerVariableToLoadOption (OptionName, &mBmHotkeyBootOption);\r
- DEBUG ((EFI_D_INFO, "[Bds]Hotkey for %s pressed - %r\n", OptionName, Status));\r
+ DEBUG ((DEBUG_INFO, "[Bds]Hotkey for %s pressed - %r\n", OptionName, Status));\r
if (EFI_ERROR (Status)) {\r
mBmHotkeyBootOption.OptionNumber = LoadOptionNumberUnassigned;\r
}\r
} else {\r
- DEBUG ((EFI_D_INFO, "[Bds]Continue key pressed!\n"));\r
+ DEBUG ((DEBUG_INFO, "[Bds]Continue key pressed!\n"));\r
}\r
}\r
} else {\r
);\r
if (!EFI_ERROR (Status)) {\r
Status = TxtInEx->UnregisterKeyNotify (TxtInEx, NotifyHandle);\r
- DEBUG ((EFI_D_INFO, "[Bds]UnregisterKeyNotify: %04x/%04x %r\n", Hotkey->KeyData[KeyIndex].Key.ScanCode, Hotkey->KeyData[KeyIndex].Key.UnicodeChar, Status));\r
+ DEBUG ((DEBUG_INFO, "[Bds]UnregisterKeyNotify: %04x/%04x %r\n", Hotkey->KeyData[KeyIndex].Key.ScanCode, Hotkey->KeyData[KeyIndex].Key.UnicodeChar, Status));\r
}\r
}\r
}\r
&NotifyHandle\r
);\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"[Bds]RegisterKeyNotify: %04x/%04x %08x/%02x %r\n",\r
Hotkey->KeyData[Index].Key.ScanCode,\r
Hotkey->KeyData[Index].Key.UnicodeChar,\r
LIST_ENTRY *Link;\r
BM_HOTKEY *Hotkey;\r
\r
- DEBUG ((EFI_D_INFO, "[Bds]Stop Hotkey Service!\n"));\r
+ DEBUG ((DEBUG_INFO, "[Bds]Stop Hotkey Service!\n"));\r
gBS->CloseEvent (Event);\r
\r
EfiAcquireLock (&mBmHotkeyLock);\r
}\r
\r
if (mBmHotkeySupportCount == 0) {\r
- DEBUG ((EFI_D_INFO, "Bds: BootOptionSupport NV variable forbids starting the hotkey service.\n"));\r
+ DEBUG ((DEBUG_INFO, "Bds: BootOptionSupport NV variable forbids starting the hotkey service.\n"));\r
return EFI_UNSUPPORTED;\r
}\r
\r
\r
Status = EfiBootManagerVariableToLoadOption (OptionName, &Options[OptionIndex]);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "[Bds] %s doesn't exist - Update ****Order variable to remove the reference!!", OptionName));\r
+ DEBUG ((DEBUG_INFO, "[Bds] %s doesn't exist - Update ****Order variable to remove the reference!!", OptionName));\r
EfiBootManagerDeleteLoadOptionVariable (OptionNumber, LoadOptionType);\r
} else {\r
ASSERT (Options[OptionIndex].OptionNumber == OptionNumber);\r
//\r
// Use a heuristic to adjust the Memory Type Information for the next boot\r
//\r
- DEBUG ((EFI_D_INFO, "Memory Previous Current Next \n"));\r
- DEBUG ((EFI_D_INFO, " Type Pages Pages Pages \n"));\r
- DEBUG ((EFI_D_INFO, "====== ======== ======== ========\n"));\r
+ DEBUG ((DEBUG_INFO, "Memory Previous Current Next \n"));\r
+ DEBUG ((DEBUG_INFO, " Type Pages Pages Pages \n"));\r
+ DEBUG ((DEBUG_INFO, "====== ======== ======== ========\n"));\r
\r
for (Index = 0; PreviousMemoryTypeInformation[Index].Type != EfiMaxMemoryType; Index++) {\r
\r
MemoryTypeInformationModified = TRUE;\r
}\r
\r
- DEBUG ((EFI_D_INFO, " %02x %08x %08x %08x\n", PreviousMemoryTypeInformation[Index].Type, Previous, Current, Next));\r
+ DEBUG ((DEBUG_INFO, " %02x %08x %08x %08x\n", PreviousMemoryTypeInformation[Index].Type, Previous, Current, Next));\r
}\r
\r
//\r
// entry/resume cycle will not fail.\r
//\r
if (MemoryTypeInformationModified) {\r
- DEBUG ((EFI_D_INFO, "Memory Type Information settings change.\n"));\r
+ DEBUG ((DEBUG_INFO, "Memory Type Information settings change.\n"));\r
if (Boot && PcdGetBool (PcdResetOnMemoryTypeInformationChange)) {\r
- DEBUG ((EFI_D_INFO, "...Warm Reset!!!\n"));\r
+ DEBUG ((DEBUG_INFO, "...Warm Reset!!!\n"));\r
gRT->ResetSystem (EfiResetWarm, EFI_SUCCESS, 0, NULL);\r
}\r
}\r
} else {\r
- DEBUG ((EFI_D_ERROR, "Memory Type Information settings cannot be saved. OS S4 may fail!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Memory Type Information settings cannot be saved. OS S4 may fail!\n"));\r
}\r
}\r
FreePool (PreviousMemoryTypeInformation);\r
CHAR16 *Str;\r
\r
Str = ConvertDevicePathToText (DevicePath, FALSE, FALSE);\r
- DEBUG ((EFI_D_INFO, "%s", Str));\r
+ DEBUG ((DEBUG_INFO, "%s", Str));\r
if (Str != NULL) {\r
FreePool (Str);\r
}\r
(UINTN) Callback\r
);\r
\r
- DEBUG ((EFI_D_INFO, "VarCheckLibRegisterEndOfDxeCallback - 0x%x %r\n", Callback, Status));\r
+ DEBUG ((DEBUG_INFO, "VarCheckLibRegisterEndOfDxeCallback - 0x%x %r\n", Callback, Status));\r
\r
return Status;\r
}\r
(UINTN) AddressPointer\r
);\r
\r
- DEBUG ((EFI_D_INFO, "VarCheckLibRegisterAddressPointer - 0x%x %r\n", AddressPointer, Status));\r
+ DEBUG ((DEBUG_INFO, "VarCheckLibRegisterAddressPointer - 0x%x %r\n", AddressPointer, Status));\r
\r
return Status;\r
}\r
(UINTN) Handler\r
);\r
\r
- DEBUG ((EFI_D_INFO, "VarCheckLibRegisterSetVariableCheckHandler - 0x%x %r\n", Handler, Status));\r
+ DEBUG ((DEBUG_INFO, "VarCheckLibRegisterSetVariableCheckHandler - 0x%x %r\n", Handler, Status));\r
\r
return Status;\r
}\r
//\r
if ((Property != NULL) && (Property->Revision == VAR_CHECK_VARIABLE_PROPERTY_REVISION)) {\r
if ((RequestSource != VarCheckFromTrusted) && ((Property->Property & VAR_CHECK_VARIABLE_PROPERTY_READ_ONLY) != 0)) {\r
- DEBUG ((EFI_D_INFO, "Variable Check ReadOnly variable fail %r - %g:%s\n", EFI_WRITE_PROTECTED, VendorGuid, VariableName));\r
+ DEBUG ((DEBUG_INFO, "Variable Check ReadOnly variable fail %r - %g:%s\n", EFI_WRITE_PROTECTED, VendorGuid, VariableName));\r
return EFI_WRITE_PROTECTED;\r
}\r
if (!((((Attributes & EFI_VARIABLE_APPEND_WRITE) == 0) && (DataSize == 0)) || (Attributes == 0))) {\r
// Not to delete variable.\r
//\r
if ((Property->Attributes != 0) && ((Attributes & (~EFI_VARIABLE_APPEND_WRITE)) != Property->Attributes)) {\r
- DEBUG ((EFI_D_INFO, "Variable Check Attributes(0x%08x to 0x%08x) fail %r - %g:%s\n", Property->Attributes, Attributes, EFI_INVALID_PARAMETER, VendorGuid, VariableName));\r
+ DEBUG ((DEBUG_INFO, "Variable Check Attributes(0x%08x to 0x%08x) fail %r - %g:%s\n", Property->Attributes, Attributes, EFI_INVALID_PARAMETER, VendorGuid, VariableName));\r
return EFI_INVALID_PARAMETER;\r
}\r
if (DataSize != 0) {\r
if ((DataSize < Property->MinSize) || (DataSize > Property->MaxSize)) {\r
- DEBUG ((EFI_D_INFO, "Variable Check DataSize fail(0x%x not in 0x%x - 0x%x) %r - %g:%s\n", DataSize, Property->MinSize, Property->MaxSize, EFI_INVALID_PARAMETER, VendorGuid, VariableName));\r
+ DEBUG ((DEBUG_INFO, "Variable Check DataSize fail(0x%x not in 0x%x - 0x%x) %r - %g:%s\n", DataSize, Property->MinSize, Property->MaxSize, EFI_INVALID_PARAMETER, VendorGuid, VariableName));\r
return EFI_INVALID_PARAMETER;\r
}\r
}\r
continue;\r
}\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "Variable Check handler fail %r - %g:%s\n", Status, VendorGuid, VariableName));\r
+ DEBUG ((DEBUG_INFO, "Variable Check handler fail %r - %g:%s\n", Status, VendorGuid, VariableName));\r
return Status;\r
}\r
}\r
\r
Val[Index * 3] = 0;\r
Str[Index] = 0;\r
- DEBUG ((EFI_D_INFO, "%*a%08X: %-48a *%a*\r\n", Indent, "", Offset, Val, Str));\r
+ DEBUG ((DEBUG_INFO, "%*a%08X: %-48a *%a*\r\n", Indent, "", Offset, Val, Str));\r
\r
Data += Size;\r
Offset += Size;\r
//\r
// No match\r
//\r
- DEBUG ((EFI_D_INFO, "VarCheckPcdValidData fail: ValidList mismatch (0x%lx)\n", OneData));\r
+ DEBUG ((DEBUG_INFO, "VarCheckPcdValidData fail: ValidList mismatch (0x%lx)\n", OneData));\r
DEBUG_CODE (VarCheckPcdInternalDumpHex (2, 0, PcdValidData->Length, (UINT8 *) PcdValidData););\r
return FALSE;\r
}\r
return TRUE;\r
}\r
}\r
- DEBUG ((EFI_D_INFO, "VarCheckPcdValidData fail: ValidRange mismatch (0x%lx)\n", OneData));\r
+ DEBUG ((DEBUG_INFO, "VarCheckPcdValidData fail: ValidRange mismatch (0x%lx)\n", OneData));\r
DEBUG_CODE (VarCheckPcdInternalDumpHex (2, 0, PcdValidData->Length, (UINT8 *) PcdValidData););\r
return FALSE;\r
break;\r
//\r
// Found the Pcd Variable that could be used to do check.\r
//\r
- DEBUG ((EFI_D_INFO, "VarCheckPcdVariable - %s:%g with Attributes = 0x%08x Size = 0x%x\n", VariableName, VendorGuid, Attributes, DataSize));\r
+ DEBUG ((DEBUG_INFO, "VarCheckPcdVariable - %s:%g with Attributes = 0x%08x Size = 0x%x\n", VariableName, VendorGuid, Attributes, DataSize));\r
if ((PcdVariable->Attributes != 0) && PcdVariable->Attributes != Attributes) {\r
- DEBUG ((EFI_D_INFO, "VarCheckPcdVariable fail for Attributes - 0x%08x\n", PcdVariable->Attributes));\r
+ DEBUG ((DEBUG_INFO, "VarCheckPcdVariable fail for Attributes - 0x%08x\n", PcdVariable->Attributes));\r
return EFI_SECURITY_VIOLATION;\r
}\r
\r
if (DataSize == 0) {\r
- DEBUG ((EFI_D_INFO, "VarCheckPcdVariable - CHECK PASS with DataSize == 0 !\n"));\r
+ DEBUG ((DEBUG_INFO, "VarCheckPcdVariable - CHECK PASS with DataSize == 0 !\n"));\r
return EFI_SUCCESS;\r
}\r
\r
PcdValidData = (VAR_CHECK_PCD_VALID_DATA_HEADER *) HEADER_ALIGN (((UINTN) PcdValidData + PcdValidData->Length));\r
}\r
\r
- DEBUG ((EFI_D_INFO, "VarCheckPcdVariable - ALL CHECK PASS!\n"));\r
+ DEBUG ((DEBUG_INFO, "VarCheckPcdVariable - ALL CHECK PASS!\n"));\r
return EFI_SUCCESS;\r
}\r
//\r
UINT64 OneValue;\r
UINT8 *Ptr;\r
\r
- DEBUG ((EFI_D_INFO, " VAR_CHECK_PCD_VALID_DATA_HEADER\n"));\r
- DEBUG ((EFI_D_INFO, " Type - 0x%02x\n", PcdValidData->Type));\r
- DEBUG ((EFI_D_INFO, " Length - 0x%02x\n", PcdValidData->Length));\r
- DEBUG ((EFI_D_INFO, " VarOffset - 0x%04x\n", PcdValidData->VarOffset));\r
- DEBUG ((EFI_D_INFO, " StorageWidth - 0x%02x\n", PcdValidData->StorageWidth));\r
+ DEBUG ((DEBUG_INFO, " VAR_CHECK_PCD_VALID_DATA_HEADER\n"));\r
+ DEBUG ((DEBUG_INFO, " Type - 0x%02x\n", PcdValidData->Type));\r
+ DEBUG ((DEBUG_INFO, " Length - 0x%02x\n", PcdValidData->Length));\r
+ DEBUG ((DEBUG_INFO, " VarOffset - 0x%04x\n", PcdValidData->VarOffset));\r
+ DEBUG ((DEBUG_INFO, " StorageWidth - 0x%02x\n", PcdValidData->StorageWidth));\r
\r
switch (PcdValidData->Type) {\r
case VarCheckPcdValidList:\r
CopyMem (&OneValue, Ptr, PcdValidData->StorageWidth);\r
switch (PcdValidData->StorageWidth) {\r
case sizeof (UINT8):\r
- DEBUG ((EFI_D_INFO, " ValidList - 0x%02x\n", OneValue));\r
+ DEBUG ((DEBUG_INFO, " ValidList - 0x%02x\n", OneValue));\r
break;\r
case sizeof (UINT16):\r
- DEBUG ((EFI_D_INFO, " ValidList - 0x%04x\n", OneValue));\r
+ DEBUG ((DEBUG_INFO, " ValidList - 0x%04x\n", OneValue));\r
break;\r
case sizeof (UINT32):\r
- DEBUG ((EFI_D_INFO, " ValidList - 0x%08x\n", OneValue));\r
+ DEBUG ((DEBUG_INFO, " ValidList - 0x%08x\n", OneValue));\r
break;\r
case sizeof (UINT64):\r
- DEBUG ((EFI_D_INFO, " ValidList - 0x%016lx\n", OneValue));\r
+ DEBUG ((DEBUG_INFO, " ValidList - 0x%016lx\n", OneValue));\r
break;\r
default:\r
ASSERT (FALSE);\r
\r
switch (PcdValidData->StorageWidth) {\r
case sizeof (UINT8):\r
- DEBUG ((EFI_D_INFO, " Minimum - 0x%02x\n", Minimum));\r
- DEBUG ((EFI_D_INFO, " Maximum - 0x%02x\n", Maximum));\r
+ DEBUG ((DEBUG_INFO, " Minimum - 0x%02x\n", Minimum));\r
+ DEBUG ((DEBUG_INFO, " Maximum - 0x%02x\n", Maximum));\r
break;\r
case sizeof (UINT16):\r
- DEBUG ((EFI_D_INFO, " Minimum - 0x%04x\n", Minimum));\r
- DEBUG ((EFI_D_INFO, " Maximum - 0x%04x\n", Maximum));\r
+ DEBUG ((DEBUG_INFO, " Minimum - 0x%04x\n", Minimum));\r
+ DEBUG ((DEBUG_INFO, " Maximum - 0x%04x\n", Maximum));\r
break;\r
case sizeof (UINT32):\r
- DEBUG ((EFI_D_INFO, " Minimum - 0x%08x\n", Minimum));\r
- DEBUG ((EFI_D_INFO, " Maximum - 0x%08x\n", Maximum));\r
+ DEBUG ((DEBUG_INFO, " Minimum - 0x%08x\n", Minimum));\r
+ DEBUG ((DEBUG_INFO, " Maximum - 0x%08x\n", Maximum));\r
break;\r
case sizeof (UINT64):\r
- DEBUG ((EFI_D_INFO, " Minimum - 0x%016lx\n", Minimum));\r
- DEBUG ((EFI_D_INFO, " Maximum - 0x%016lx\n", Maximum));\r
+ DEBUG ((DEBUG_INFO, " Minimum - 0x%016lx\n", Minimum));\r
+ DEBUG ((DEBUG_INFO, " Maximum - 0x%016lx\n", Maximum));\r
break;\r
default:\r
ASSERT (FALSE);\r
{\r
VAR_CHECK_PCD_VALID_DATA_HEADER *PcdValidData;\r
\r
- DEBUG ((EFI_D_INFO, "VAR_CHECK_PCD_VARIABLE_HEADER\n"));\r
- DEBUG ((EFI_D_INFO, " Revision - 0x%04x\n", PcdVariable->Revision));\r
- DEBUG ((EFI_D_INFO, " HeaderLength - 0x%04x\n", PcdVariable->HeaderLength));\r
- DEBUG ((EFI_D_INFO, " Length - 0x%08x\n", PcdVariable->Length));\r
- DEBUG ((EFI_D_INFO, " Type - 0x%02x\n", PcdVariable->Type));\r
- DEBUG ((EFI_D_INFO, " Attributes - 0x%08x\n", PcdVariable->Attributes));\r
- DEBUG ((EFI_D_INFO, " Guid - %g\n", &PcdVariable->Guid));\r
- DEBUG ((EFI_D_INFO, " Name - %s\n", PcdVariable + 1));\r
+ DEBUG ((DEBUG_INFO, "VAR_CHECK_PCD_VARIABLE_HEADER\n"));\r
+ DEBUG ((DEBUG_INFO, " Revision - 0x%04x\n", PcdVariable->Revision));\r
+ DEBUG ((DEBUG_INFO, " HeaderLength - 0x%04x\n", PcdVariable->HeaderLength));\r
+ DEBUG ((DEBUG_INFO, " Length - 0x%08x\n", PcdVariable->Length));\r
+ DEBUG ((DEBUG_INFO, " Type - 0x%02x\n", PcdVariable->Type));\r
+ DEBUG ((DEBUG_INFO, " Attributes - 0x%08x\n", PcdVariable->Attributes));\r
+ DEBUG ((DEBUG_INFO, " Guid - %g\n", &PcdVariable->Guid));\r
+ DEBUG ((DEBUG_INFO, " Name - %s\n", PcdVariable + 1));\r
\r
//\r
// For Pcd ValidData header align.\r
{\r
VAR_CHECK_PCD_VARIABLE_HEADER *PcdVariable;\r
\r
- DEBUG ((EFI_D_INFO, "DumpVarCheckPcd\n"));\r
+ DEBUG ((DEBUG_INFO, "DumpVarCheckPcd\n"));\r
\r
//\r
// For Pcd Variable header align.\r
mVarCheckPcdBinSize = VarCheckPcdBinSize;\r
FreePool (VarCheckPcdBin);\r
\r
- DEBUG ((EFI_D_INFO, "VarCheckPcdBin - at 0x%x size = 0x%x\n", mVarCheckPcdBin, mVarCheckPcdBinSize));\r
+ DEBUG ((DEBUG_INFO, "VarCheckPcdBin - at 0x%x size = 0x%x\n", mVarCheckPcdBin, mVarCheckPcdBinSize));\r
\r
#ifdef DUMP_VAR_CHECK_PCD\r
DEBUG_CODE (\r
);\r
#endif\r
} else {\r
- DEBUG ((EFI_D_INFO, "[VarCheckPcd] No VarCheckPcdBin found at the first RAW section\n"));\r
+ DEBUG ((DEBUG_INFO, "[VarCheckPcd] No VarCheckPcdBin found at the first RAW section\n"));\r
}\r
}\r
\r
// only permit the creation of variables with a UEFI Specification-defined\r
// VendorGuid when these variables are documented in the UEFI Specification.\r
//\r
- DEBUG ((EFI_D_INFO, "UEFI Variable Check fail %r - %s not in %g namespace\n", EFI_INVALID_PARAMETER, VariableName, VendorGuid));\r
+ DEBUG ((DEBUG_INFO, "UEFI Variable Check fail %r - %s not in %g namespace\n", EFI_INVALID_PARAMETER, VariableName, VendorGuid));\r
return EFI_INVALID_PARAMETER;\r
}\r
}\r
Data\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "UEFI Variable Check function fail %r - %g:%s\n", Status, VendorGuid, VariableName));\r
+ DEBUG ((DEBUG_INFO, "UEFI Variable Check function fail %r - %g:%s\n", Status, VendorGuid, VariableName));\r
return Status;\r
}\r
}\r
}\r
\r
DEBUG_CODE_BEGIN ();\r
- DEBUG ((EFI_D_ERROR, "AcpiSdt: FindPath - "));\r
+ DEBUG ((DEBUG_ERROR, "AcpiSdt: FindPath - "));\r
AmlPrintNameString (AmlPath);\r
- DEBUG ((EFI_D_ERROR, "\n"));\r
+ DEBUG ((DEBUG_ERROR, "\n"));\r
DEBUG_CODE_END ();\r
\r
if (AmlHandle->Signature == EFI_AML_ROOT_HANDLE_SIGNATURE) {\r
//\r
// Oops!!!, There must be something wrong.\r
//\r
- DEBUG ((EFI_D_ERROR, "AML: Override Happen - %a!\n", NameString));\r
- DEBUG ((EFI_D_ERROR, "AML: Existing Node - %x\n", AmlNodeList->Buffer));\r
- DEBUG ((EFI_D_ERROR, "AML: New Buffer - %x\n", Buffer));\r
+ DEBUG ((DEBUG_ERROR, "AML: Override Happen - %a!\n", NameString));\r
+ DEBUG ((DEBUG_ERROR, "AML: Existing Node - %x\n", AmlNodeList->Buffer));\r
+ DEBUG ((DEBUG_ERROR, "AML: New Buffer - %x\n", Buffer));\r
\r
return NULL;\r
}\r
CurrentLink = AmlParentNodeList->Children.ForwardLink;\r
\r
if (Level == 0) {\r
- DEBUG ((EFI_D_ERROR, "\\"));\r
+ DEBUG ((DEBUG_ERROR, "\\"));\r
} else {\r
for (Index = 0; Index < Level; Index++) {\r
- DEBUG ((EFI_D_ERROR, " "));\r
+ DEBUG ((DEBUG_ERROR, " "));\r
}\r
AmlPrintNameSeg (AmlParentNodeList->Name);\r
}\r
- DEBUG ((EFI_D_ERROR, "\n"));\r
+ DEBUG ((DEBUG_ERROR, "\n"));\r
\r
while (CurrentLink != &AmlParentNodeList->Children) {\r
CurrentAmlNodeList = EFI_AML_NODE_LIST_FROM_LINK (CurrentLink);\r
}\r
\r
DEBUG_CODE_BEGIN ();\r
- DEBUG ((EFI_D_ERROR, "AcpiSdt: NameSpace:\n"));\r
+ DEBUG ((DEBUG_ERROR, "AcpiSdt: NameSpace:\n"));\r
AmlDumpNodeInfo (AmlRootNodeList, 0);\r
DEBUG_CODE_END ();\r
\r
//\r
if (CurrentAmlNodeList != NULL) {\r
DEBUG_CODE_BEGIN ();\r
- DEBUG ((EFI_D_ERROR, "AcpiSdt: Search from: \\"));\r
+ DEBUG ((DEBUG_ERROR, "AcpiSdt: Search from: \\"));\r
AmlPrintNameSeg (CurrentAmlNodeList->Name);\r
- DEBUG ((EFI_D_ERROR, "\n"));\r
+ DEBUG ((DEBUG_ERROR, "\n"));\r
DEBUG_CODE_END ();\r
AmlNodeList = AmlFindNodeInTheTree (\r
AmlPath,\r
IN UINT8 *Buffer\r
)\r
{\r
- DEBUG ((EFI_D_ERROR, "%c", Buffer[0]));\r
+ DEBUG ((DEBUG_ERROR, "%c", Buffer[0]));\r
if ((Buffer[1] == '_') && (Buffer[2] == '_') && (Buffer[3] == '_')) {\r
return ;\r
}\r
- DEBUG ((EFI_D_ERROR, "%c", Buffer[1]));\r
+ DEBUG ((DEBUG_ERROR, "%c", Buffer[1]));\r
if ((Buffer[2] == '_') && (Buffer[3] == '_')) {\r
return ;\r
}\r
- DEBUG ((EFI_D_ERROR, "%c", Buffer[2]));\r
+ DEBUG ((DEBUG_ERROR, "%c", Buffer[2]));\r
if (Buffer[3] == '_') {\r
return ;\r
}\r
- DEBUG ((EFI_D_ERROR, "%c", Buffer[3]));\r
+ DEBUG ((DEBUG_ERROR, "%c", Buffer[3]));\r
return ;\r
}\r
\r
// RootChar\r
//\r
Buffer ++;\r
- DEBUG ((EFI_D_ERROR, "\\"));\r
+ DEBUG ((DEBUG_ERROR, "\\"));\r
} else if (*Buffer == AML_PARENT_PREFIX_CHAR) {\r
//\r
// ParentPrefixChar\r
//\r
do {\r
Buffer ++;\r
- DEBUG ((EFI_D_ERROR, "^"));\r
+ DEBUG ((DEBUG_ERROR, "^"));\r
} while (*Buffer == AML_PARENT_PREFIX_CHAR);\r
}\r
\r
AmlPrintNameSeg (Buffer);\r
Buffer += AML_NAME_SEG_SIZE;\r
for (Index = 0; Index < SegCount - 1; Index++) {\r
- DEBUG ((EFI_D_ERROR, "."));\r
+ DEBUG ((DEBUG_ERROR, "."));\r
AmlPrintNameSeg (Buffer);\r
Buffer += AML_NAME_SEG_SIZE;\r
}\r
);\r
} else {\r
// Unsupported for 32bit DXE, 64bit OS vector\r
- DEBUG (( EFI_D_ERROR, "Unsupported for 32bit DXE transfer to 64bit OS waking vector!\r\n"));\r
+ DEBUG (( DEBUG_ERROR, "Unsupported for 32bit DXE transfer to 64bit OS waking vector!\r\n"));\r
ASSERT (FALSE);\r
}\r
} else {\r
\r
return EFI_SUCCESS;\r
}\r
-\r
EFI_SIZE_TO_PAGES (sizeof (S3_PERFORMANCE_TABLE))\r
);\r
}\r
- DEBUG ((EFI_D_INFO, "FPDT: ACPI S3 Performance Table address = 0x%x\n", mAcpiS3PerformanceTable));\r
+ DEBUG ((DEBUG_INFO, "FPDT: ACPI S3 Performance Table address = 0x%x\n", mAcpiS3PerformanceTable));\r
if (mAcpiS3PerformanceTable != NULL) {\r
CopyMem (mAcpiS3PerformanceTable, &mS3PerformanceTableTemplate, sizeof (mS3PerformanceTableTemplate));\r
}\r
//\r
// Dump FPDT Boot Performance record.\r
//\r
- DEBUG ((EFI_D_INFO, "FPDT: Boot Performance - ResetEnd = %ld\n", mAcpiBootPerformanceTable->BasicBoot.ResetEnd));\r
- DEBUG ((EFI_D_INFO, "FPDT: Boot Performance - OsLoaderLoadImageStart = 0\n"));\r
- DEBUG ((EFI_D_INFO, "FPDT: Boot Performance - OsLoaderStartImageStart = %ld\n", mAcpiBootPerformanceTable->BasicBoot.OsLoaderStartImageStart));\r
- DEBUG ((EFI_D_INFO, "FPDT: Boot Performance - ExitBootServicesEntry = 0\n"));\r
- DEBUG ((EFI_D_INFO, "FPDT: Boot Performance - ExitBootServicesExit = 0\n"));\r
+ DEBUG ((DEBUG_INFO, "FPDT: Boot Performance - ResetEnd = %ld\n", mAcpiBootPerformanceTable->BasicBoot.ResetEnd));\r
+ DEBUG ((DEBUG_INFO, "FPDT: Boot Performance - OsLoaderLoadImageStart = 0\n"));\r
+ DEBUG ((DEBUG_INFO, "FPDT: Boot Performance - OsLoaderStartImageStart = %ld\n", mAcpiBootPerformanceTable->BasicBoot.OsLoaderStartImageStart));\r
+ DEBUG ((DEBUG_INFO, "FPDT: Boot Performance - ExitBootServicesEntry = 0\n"));\r
+ DEBUG ((DEBUG_INFO, "FPDT: Boot Performance - ExitBootServicesExit = 0\n"));\r
} else if (Data != NULL && CompareGuid (&Data->Type, &gEdkiiFpdtExtendedFirmwarePerformanceGuid)) {\r
//\r
// Get the Boot performance table and then install it to ACPI table.\r
//\r
// Dump FPDT Boot Performance record.\r
//\r
- DEBUG ((EFI_D_INFO, "FPDT: Boot Performance - ResetEnd = %ld\n", mAcpiBootPerformanceTable->BasicBoot.ResetEnd));\r
- DEBUG ((EFI_D_INFO, "FPDT: Boot Performance - OsLoaderLoadImageStart = %ld\n", mAcpiBootPerformanceTable->BasicBoot.OsLoaderLoadImageStart));\r
- DEBUG ((EFI_D_INFO, "FPDT: Boot Performance - OsLoaderStartImageStart = %ld\n", mAcpiBootPerformanceTable->BasicBoot.OsLoaderStartImageStart));\r
- DEBUG ((EFI_D_INFO, "FPDT: Boot Performance - ExitBootServicesEntry = %ld\n", mAcpiBootPerformanceTable->BasicBoot.ExitBootServicesEntry));\r
+ DEBUG ((DEBUG_INFO, "FPDT: Boot Performance - ResetEnd = %ld\n", mAcpiBootPerformanceTable->BasicBoot.ResetEnd));\r
+ DEBUG ((DEBUG_INFO, "FPDT: Boot Performance - OsLoaderLoadImageStart = %ld\n", mAcpiBootPerformanceTable->BasicBoot.OsLoaderLoadImageStart));\r
+ DEBUG ((DEBUG_INFO, "FPDT: Boot Performance - OsLoaderStartImageStart = %ld\n", mAcpiBootPerformanceTable->BasicBoot.OsLoaderStartImageStart));\r
+ DEBUG ((DEBUG_INFO, "FPDT: Boot Performance - ExitBootServicesEntry = %ld\n", mAcpiBootPerformanceTable->BasicBoot.ExitBootServicesEntry));\r
//\r
// ExitBootServicesExit will be updated later, so don't dump it here.\r
//\r
AcpiS3PerformanceTable = (S3_PERFORMANCE_TABLE *) (UINTN) S3PerformanceTablePointer;\r
ASSERT (AcpiS3PerformanceTable != NULL);\r
if (AcpiS3PerformanceTable->Header.Signature != EFI_ACPI_5_0_FPDT_S3_PERFORMANCE_TABLE_SIGNATURE) {\r
- DEBUG ((EFI_D_ERROR, "FPDT S3 performance data in ACPI memory get corrupted\n"));\r
+ DEBUG ((DEBUG_ERROR, "FPDT S3 performance data in ACPI memory get corrupted\n"));\r
return EFI_ABORTED;\r
}\r
AcpiS3ResumeRecord = &AcpiS3PerformanceTable->S3Resume;\r
AcpiS3ResumeRecord->ResumeCount++;\r
AcpiS3ResumeRecord->AverageResume = DivU64x32 (S3ResumeTotal + AcpiS3ResumeRecord->FullResume, AcpiS3ResumeRecord->ResumeCount);\r
\r
- DEBUG ((EFI_D_INFO, "FPDT: S3 Resume Performance - ResumeCount = %d\n", AcpiS3ResumeRecord->ResumeCount));\r
- DEBUG ((EFI_D_INFO, "FPDT: S3 Resume Performance - FullResume = %ld\n", AcpiS3ResumeRecord->FullResume));\r
- DEBUG ((EFI_D_INFO, "FPDT: S3 Resume Performance - AverageResume = %ld\n", AcpiS3ResumeRecord->AverageResume));\r
+ DEBUG ((DEBUG_INFO, "FPDT: S3 Resume Performance - ResumeCount = %d\n", AcpiS3ResumeRecord->ResumeCount));\r
+ DEBUG ((DEBUG_INFO, "FPDT: S3 Resume Performance - FullResume = %ld\n", AcpiS3ResumeRecord->FullResume));\r
+ DEBUG ((DEBUG_INFO, "FPDT: S3 Resume Performance - AverageResume = %ld\n", AcpiS3ResumeRecord->AverageResume));\r
\r
//\r
// Update S3 Suspend Performance Record.\r
AcpiS3SuspendRecord->SuspendStart = S3SuspendRecord.SuspendStart;\r
AcpiS3SuspendRecord->SuspendEnd = S3SuspendRecord.SuspendEnd;\r
\r
- DEBUG ((EFI_D_INFO, "FPDT: S3 Suspend Performance - SuspendStart = %ld\n", AcpiS3SuspendRecord->SuspendStart));\r
- DEBUG ((EFI_D_INFO, "FPDT: S3 Suspend Performance - SuspendEnd = %ld\n", AcpiS3SuspendRecord->SuspendEnd));\r
+ DEBUG ((DEBUG_INFO, "FPDT: S3 Suspend Performance - SuspendStart = %ld\n", AcpiS3SuspendRecord->SuspendStart));\r
+ DEBUG ((DEBUG_INFO, "FPDT: S3 Suspend Performance - SuspendEnd = %ld\n", AcpiS3SuspendRecord->SuspendEnd));\r
\r
Status = PeiServicesLocatePpi (\r
&gEfiPeiReadOnlyVariable2PpiGuid,\r
EFI_ACPI_4_0_FIRMWARE_ACPI_CONTROL_STRUCTURE *Facs;\r
VOID *Interface;\r
\r
- DEBUG ((EFI_D_INFO, "AcpiS3ContextSave!\n"));\r
+ DEBUG ((DEBUG_INFO, "AcpiS3ContextSave!\n"));\r
\r
Status = gBS->LocateProtocol (&gEfiLockBoxProtocolGuid, NULL, &Interface);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO | EFI_D_WARN, "ACPI S3 context can't be saved without LockBox!\n"));\r
+ DEBUG ((DEBUG_INFO | DEBUG_WARN, "ACPI S3 context can't be saved without LockBox!\n"));\r
goto Done;\r
}\r
\r
AcpiS3Context->S3DebugBufferAddress = (EFI_PHYSICAL_ADDRESS)(UINTN)AllocateMemoryBelow4G (EfiReservedMemoryType, EFI_PAGE_SIZE);\r
SetMem ((VOID *)(UINTN)AcpiS3Context->S3DebugBufferAddress, EFI_PAGE_SIZE, 0xff);\r
\r
- DEBUG((EFI_D_INFO, "AcpiS3Context: AcpiFacsTable is 0x%8x\n", AcpiS3Context->AcpiFacsTable));\r
- DEBUG((EFI_D_INFO, "AcpiS3Context: IdtrProfile is 0x%8x\n", AcpiS3Context->IdtrProfile));\r
- DEBUG((EFI_D_INFO, "AcpiS3Context: S3NvsPageTableAddress is 0x%8x\n", AcpiS3Context->S3NvsPageTableAddress));\r
- DEBUG((EFI_D_INFO, "AcpiS3Context: S3DebugBufferAddress is 0x%8x\n", AcpiS3Context->S3DebugBufferAddress));\r
- DEBUG((EFI_D_INFO, "AcpiS3Context: BootScriptStackBase is 0x%8x\n", AcpiS3Context->BootScriptStackBase));\r
- DEBUG((EFI_D_INFO, "AcpiS3Context: BootScriptStackSize is 0x%8x\n", AcpiS3Context->BootScriptStackSize));\r
+ DEBUG((DEBUG_INFO, "AcpiS3Context: AcpiFacsTable is 0x%8x\n", AcpiS3Context->AcpiFacsTable));\r
+ DEBUG((DEBUG_INFO, "AcpiS3Context: IdtrProfile is 0x%8x\n", AcpiS3Context->IdtrProfile));\r
+ DEBUG((DEBUG_INFO, "AcpiS3Context: S3NvsPageTableAddress is 0x%8x\n", AcpiS3Context->S3NvsPageTableAddress));\r
+ DEBUG((DEBUG_INFO, "AcpiS3Context: S3DebugBufferAddress is 0x%8x\n", AcpiS3Context->S3DebugBufferAddress));\r
+ DEBUG((DEBUG_INFO, "AcpiS3Context: BootScriptStackBase is 0x%8x\n", AcpiS3Context->BootScriptStackBase));\r
+ DEBUG((DEBUG_INFO, "AcpiS3Context: BootScriptStackSize is 0x%8x\n", AcpiS3Context->BootScriptStackSize));\r
\r
Status = SaveLockBox (\r
&gEfiAcpiVariableGuid,\r
Status = gBS->CloseEvent (Event);\r
ASSERT_EFI_ERROR (Status);\r
}\r
-\r
// Should not enter this case, if enter, the keyboard will not work.\r
// May need platfrom policy to connect keyboard.\r
//\r
- DEBUG ((EFI_D_WARN, "[Bds] Connect ConIn failed - %r!!!\n", Status));\r
+ DEBUG ((DEBUG_WARN, "[Bds] Connect ConIn failed - %r!!!\n", Status));\r
}\r
}\r
/**\r
EFI_STATUS Status;\r
UINT16 TimeoutRemain;\r
\r
- DEBUG ((EFI_D_INFO, "[Bds]BdsWait ...Zzzzzzzzzzzz...\n"));\r
+ DEBUG ((DEBUG_INFO, "[Bds]BdsWait ...Zzzzzzzzzzzz...\n"));\r
\r
TimeoutRemain = PcdGet16 (PcdPlatformBootTimeOut);\r
while (TimeoutRemain != 0) {\r
- DEBUG ((EFI_D_INFO, "[Bds]BdsWait(%d)..Zzzz...\n", (UINTN) TimeoutRemain));\r
+ DEBUG ((DEBUG_INFO, "[Bds]BdsWait(%d)..Zzzz...\n", (UINTN) TimeoutRemain));\r
PlatformBootManagerWaitCallback (TimeoutRemain);\r
\r
BdsReadKeys (); // BUGBUG: Only reading can signal HotkeyTriggered\r
if (PcdGet16 (PcdPlatformBootTimeOut) != 0 && TimeoutRemain == 0) {\r
PlatformBootManagerWaitCallback (0);\r
}\r
- DEBUG ((EFI_D_INFO, "[Bds]Exit the waiting!\n"));\r
+ DEBUG ((DEBUG_INFO, "[Bds]Exit the waiting!\n"));\r
}\r
\r
/**\r
(Attributes != (EFI_VARIABLE_BOOTSERVICE_ACCESS | EFI_VARIABLE_RUNTIME_ACCESS | EFI_VARIABLE_NON_VOLATILE))\r
){\r
\r
- DEBUG ((EFI_D_ERROR, "[Bds] Unformalized OsIndications variable exists. Delete it\n"));\r
+ DEBUG ((DEBUG_ERROR, "[Bds] Unformalized OsIndications variable exists. Delete it\n"));\r
Status = gRT->SetVariable (\r
EFI_OS_INDICATIONS_VARIABLE_NAME,\r
&gEfiGlobalVariableGuid,\r
//\r
PERF_CROSSMODULE_END("DXE");\r
PERF_CROSSMODULE_BEGIN("BDS");\r
- DEBUG ((EFI_D_INFO, "[Bds] Entry...\n"));\r
+ DEBUG ((DEBUG_INFO, "[Bds] Entry...\n"));\r
\r
//\r
// Fill in FirmwareVendor and FirmwareRevision from PCDs\r
\r
DEBUG_CODE (\r
EFI_BOOT_MANAGER_LOAD_OPTION_TYPE LoadOptionType;\r
- DEBUG ((EFI_D_INFO, "[Bds]OsIndication: %016x\n", OsIndication));\r
- DEBUG ((EFI_D_INFO, "[Bds]=============Begin Load Options Dumping ...=============\n"));\r
+ DEBUG ((DEBUG_INFO, "[Bds]OsIndication: %016x\n", OsIndication));\r
+ DEBUG ((DEBUG_INFO, "[Bds]=============Begin Load Options Dumping ...=============\n"));\r
for (LoadOptionType = 0; LoadOptionType < LoadOptionTypeMax; LoadOptionType++) {\r
DEBUG ((\r
- EFI_D_INFO, " %s Options:\n",\r
+ DEBUG_INFO, " %s Options:\n",\r
mBdsLoadOptionName[LoadOptionType]\r
));\r
LoadOptions = EfiBootManagerGetLoadOptions (&LoadOptionCount, LoadOptionType);\r
for (Index = 0; Index < LoadOptionCount; Index++) {\r
DEBUG ((\r
- EFI_D_INFO, " %s%04x: %s \t\t 0x%04x\n",\r
+ DEBUG_INFO, " %s%04x: %s \t\t 0x%04x\n",\r
mBdsLoadOptionName[LoadOptionType],\r
LoadOptions[Index].OptionNumber,\r
LoadOptions[Index].Description,\r
}\r
EfiBootManagerFreeLoadOptions (LoadOptions, LoadOptionCount);\r
}\r
- DEBUG ((EFI_D_INFO, "[Bds]=============End Load Options Dumping=============\n"));\r
+ DEBUG ((DEBUG_INFO, "[Bds]=============End Load Options Dumping=============\n"));\r
);\r
\r
//\r
}\r
EfiBootManagerFreeLoadOption (&PlatformDefaultBootOption);\r
\r
- DEBUG ((EFI_D_ERROR, "[Bds] Unable to boot!\n"));\r
+ DEBUG ((DEBUG_ERROR, "[Bds] Unable to boot!\n"));\r
PlatformBootManagerUnableToBoot ();\r
CpuDeadLoop ();\r
}\r
AddressEncMask = PageFaultContext->AddressEncMask;\r
\r
PFAddress = AsmReadCr2 ();\r
- DEBUG ((EFI_D_ERROR, "CapsuleX64 - PageFaultHandler: Cr2 - %lx\n", PFAddress));\r
+ DEBUG ((DEBUG_ERROR, "CapsuleX64 - PageFaultHandler: Cr2 - %lx\n", PFAddress));\r
\r
if (PFAddress >= PhyMask + SIZE_4KB) {\r
return PageFaultContext->OriginalHandler;\r
&Registration\r
);\r
} else {\r
- DEBUG ((EFI_D_ERROR, "FATAL ERROR: CapsuleLongModeBuffer cannot be saved: %r. Capsule in PEI may fail!\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "FATAL ERROR: CapsuleLongModeBuffer cannot be saved: %r. Capsule in PEI may fail!\n", Status));\r
gBS->FreePages (LongModeBuffer.StackBaseAddress, EFI_SIZE_TO_PAGES (LongModeBuffer.StackSize));\r
}\r
}\r
);\r
}\r
mConIn.PhysicalKeyToggleState = KeyData->KeyState.KeyToggleState;\r
- DEBUG ((EFI_D_INFO, "Current toggle state is 0x%02x\n", mConIn.PhysicalKeyToggleState));\r
+ DEBUG ((DEBUG_INFO, "Current toggle state is 0x%02x\n", mConIn.PhysicalKeyToggleState));\r
}\r
\r
return EFI_SUCCESS;\r
// Signal ConnectConIn event on first call in Lazy ConIn mode\r
//\r
if (!mConInIsConnect && PcdGetBool (PcdConInConnectOnDemand)) {\r
- DEBUG ((EFI_D_INFO, "Connect ConIn in first ReadKeyStoke in Lazy ConIn mode.\n"));\r
+ DEBUG ((DEBUG_INFO, "Connect ConIn in first ReadKeyStoke in Lazy ConIn mode.\n"));\r
gBS->SignalEvent (Private->ConnectConInEvent);\r
mConInIsConnect = TRUE;\r
}\r
// Signal ConnectConIn event on first call in Lazy ConIn mode\r
//\r
if (!mConInIsConnect && PcdGetBool (PcdConInConnectOnDemand)) {\r
- DEBUG ((EFI_D_INFO, "Connect ConIn in first ReadKeyStoke in Lazy ConIn mode.\n"));\r
+ DEBUG ((DEBUG_INFO, "Connect ConIn in first ReadKeyStoke in Lazy ConIn mode.\n"));\r
gBS->SignalEvent (Private->ConnectConInEvent);\r
mConInIsConnect = TRUE;\r
}\r
\r
DEBUG_CODE (\r
for (Index = 0; Index < ValidCount; Index++) {\r
- DEBUG ((EFI_D_INFO, "Graphics - Mode %d, Column = %d, Row = %d\n",\r
+ DEBUG ((DEBUG_INFO, "Graphics - Mode %d, Column = %d, Row = %d\n",\r
Index, NewModeBuffer[Index].Columns, NewModeBuffer[Index].Rows));\r
}\r
);\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "GraphicsConsole video resolution %d x %d\n", HorizontalResolution, VerticalResolution));\r
+ DEBUG ((DEBUG_INFO, "GraphicsConsole video resolution %d x %d\n", HorizontalResolution, VerticalResolution));\r
\r
//\r
// Initialize the mode which GraphicsConsole supports.\r
\r
return Status;\r
}\r
-\r
-\r
// Use default device infomation when the device info HOB doesn't exist\r
//\r
DeviceInfo = &mDefaultGraphicsDeviceInfo;\r
- DEBUG ((EFI_D_INFO, "[%a]: GraphicsDeviceInfo HOB doesn't exist!\n", gEfiCallerBaseName));\r
+ DEBUG ((DEBUG_INFO, "[%a]: GraphicsDeviceInfo HOB doesn't exist!\n", gEfiCallerBaseName));\r
} else {\r
DeviceInfo = (EFI_PEI_GRAPHICS_DEVICE_INFO_HOB *) (GET_GUID_HOB_DATA (HobStart));\r
- DEBUG ((EFI_D_INFO, "[%a]: GraphicsDeviceInfo HOB:\n"\r
+ DEBUG ((DEBUG_INFO, "[%a]: GraphicsDeviceInfo HOB:\n"\r
" VendorId = %04x, DeviceId = %04x,\n"\r
" RevisionId = %02x, BarIndex = %x,\n"\r
" SubsystemVendorId = %04x, SubsystemId = %04x\n",\r
}\r
Status = PciIo->GetBarAttributes (PciIo, Index, NULL, (VOID**) &Resources);\r
if (!EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "[%a]: BAR[%d]: Base = %lx, Length = %lx\n",\r
+ DEBUG ((DEBUG_INFO, "[%a]: BAR[%d]: Base = %lx, Length = %lx\n",\r
gEfiCallerBaseName, Index, Resources->AddrRangeMin, Resources->AddrLen));\r
if ((Resources->Desc == ACPI_ADDRESS_SPACE_DESCRIPTOR) &&\r
(Resources->Len == (UINT16) (sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3)) &&\r
(Resources->AddrLen >= GraphicsInfo->FrameBufferSize)\r
) {\r
FrameBufferBase = Resources->AddrRangeMin;\r
- DEBUG ((EFI_D_INFO, "[%a]: ... matched!\n", gEfiCallerBaseName));\r
+ DEBUG ((DEBUG_INFO, "[%a]: ... matched!\n", gEfiCallerBaseName));\r
break;\r
}\r
}\r
continue;\r
}\r
else {\r
- DEBUG ((EFI_D_ERROR, "Unexpected state in escape2\n"));\r
+ DEBUG ((DEBUG_ERROR, "Unexpected state in escape2\n"));\r
}\r
}\r
TerminalDevice->ResetState = RESET_STATE_DEFAULT;\r
) {\r
continue;\r
}\r
- DEBUG ((EFI_D_INFO, "PeiCdExpress InterfaceType is %d\n", Media2.InterfaceType));\r
- DEBUG ((EFI_D_INFO, "PeiCdExpress MediaPresent is %d\n", Media2.MediaPresent));\r
- DEBUG ((EFI_D_INFO, "PeiCdExpress BlockSize is 0x%x\n", Media2.BlockSize));\r
+ DEBUG ((DEBUG_INFO, "PeiCdExpress InterfaceType is %d\n", Media2.InterfaceType));\r
+ DEBUG ((DEBUG_INFO, "PeiCdExpress MediaPresent is %d\n", Media2.MediaPresent));\r
+ DEBUG ((DEBUG_INFO, "PeiCdExpress BlockSize is 0x%x\n", Media2.BlockSize));\r
} else {\r
Status = BlockIoPpi->GetBlockDeviceMediaInfo (\r
PeiServices,\r
) {\r
continue;\r
}\r
- DEBUG ((EFI_D_INFO, "PeiCdExpress DeviceType is %d\n", Media.DeviceType));\r
- DEBUG ((EFI_D_INFO, "PeiCdExpress MediaPresent is %d\n", Media.MediaPresent));\r
- DEBUG ((EFI_D_INFO, "PeiCdExpress BlockSize is 0x%x\n", Media.BlockSize));\r
+ DEBUG ((DEBUG_INFO, "PeiCdExpress DeviceType is %d\n", Media.DeviceType));\r
+ DEBUG ((DEBUG_INFO, "PeiCdExpress MediaPresent is %d\n", Media.MediaPresent));\r
+ DEBUG ((DEBUG_INFO, "PeiCdExpress BlockSize is 0x%x\n", Media.BlockSize));\r
}\r
\r
- DEBUG ((EFI_D_INFO, "PeiCdExpress Status is %d\n", Status));\r
+ DEBUG ((DEBUG_INFO, "PeiCdExpress Status is %d\n", Status));\r
\r
- DEBUG ((EFI_D_INFO, "IndexBlockDevice is %d\n", IndexBlockDevice));\r
+ DEBUG ((DEBUG_INFO, "IndexBlockDevice is %d\n", IndexBlockDevice));\r
PrivateData->CapsuleData[PrivateData->CapsuleCount].IndexBlock = IndexBlockDevice;\r
if (BlockIo2) {\r
PrivateData->CapsuleData[PrivateData->CapsuleCount].BlockIo2 = BlockIo2Ppi;\r
PrivateData->CapsuleData[PrivateData->CapsuleCount].BlockIo = BlockIoPpi;\r
}\r
Status = FindRecoveryCapsules (PrivateData);\r
- DEBUG ((EFI_D_INFO, "Status is %d\n", Status));\r
+ DEBUG ((DEBUG_INFO, "Status is %d\n", Status));\r
\r
if (EFI_ERROR (Status)) {\r
continue;\r
}\r
}\r
DEBUG ((\r
- EFI_D_BLKIO,\r
+ DEBUG_BLKIO,\r
" %c:Lba/Offset/Length/WorkingBuffer/Buffer = %016lx/%08x/%08x/%08x/%08x\n",\r
Write ? 'W': 'R', Lba, Offset, Length, WorkingBuffer, Buffer\r
));\r
VOID *WorkingBuffer;\r
LIST_ENTRY *Link;\r
\r
- DEBUG ((EFI_D_BLKIO, "DiskIo: Create subtasks for task: Offset/BufferSize/Buffer = %016lx/%08x/%08x\n", Offset, BufferSize, Buffer));\r
+ DEBUG ((DEBUG_BLKIO, "DiskIo: Create subtasks for task: Offset/BufferSize/Buffer = %016lx/%08x/%08x\n", Offset, BufferSize, Buffer));\r
\r
BlockSize = Instance->BlockIo->Media->BlockSize;\r
IoAlign = Instance->BlockIo->Media->IoAlign;\r
//\r
// If there is not enough memory, downgrade to blocking access\r
//\r
- DEBUG ((EFI_D_VERBOSE, "DiskIo: No enough memory so downgrade to blocking access\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "DiskIo: No enough memory so downgrade to blocking access\n"));\r
if (!DiskIoCreateSubtaskList (Instance, Write, Offset, BufferSize, BufferPtr, TRUE, SharedWorkingBuffer, Subtasks)) {\r
goto Done;\r
}\r
// Task->Token should be set to NULL by the DiskIo2OnReadWriteComplete\r
// It it's not, that means the non-blocking request was downgraded to blocking request.\r
//\r
- DEBUG ((EFI_D_VERBOSE, "DiskIo: Non-blocking request was downgraded to blocking request, signal event directly.\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "DiskIo: Non-blocking request was downgraded to blocking request, signal event directly.\n"));\r
Task->Token->TransactionStatus = Status;\r
gBS->SignalEvent (Task->Token->Event);\r
}\r
Catalog\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "EltCheckDevice: error reading catalog %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "EltCheckDevice: error reading catalog %r\n", Status));\r
continue;\r
}\r
//\r
// to make sure it looks like a Catalog header\r
//\r
if (Catalog->Catalog.Indicator != ELTORITO_ID_CATALOG || Catalog->Catalog.Id55AA != 0xAA55) {\r
- DEBUG ((EFI_D_ERROR, "EltCheckBootCatalog: El Torito boot catalog header IDs not correct\n"));\r
+ DEBUG ((DEBUG_ERROR, "EltCheckBootCatalog: El Torito boot catalog header IDs not correct\n"));\r
continue;\r
}\r
\r
}\r
\r
if ((Check & 0xFFFF) != 0) {\r
- DEBUG ((EFI_D_ERROR, "EltCheckBootCatalog: El Torito boot catalog header checksum failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "EltCheckBootCatalog: El Torito boot catalog header checksum failed\n"));\r
continue;\r
}\r
\r
break;\r
\r
default:\r
- DEBUG ((EFI_D_INIT, "EltCheckDevice: unsupported El Torito boot media type %x\n", Catalog->Boot.MediaType));\r
+ DEBUG ((DEBUG_INIT, "EltCheckDevice: unsupported El Torito boot media type %x\n", Catalog->Boot.MediaType));\r
SectorCount = 0;\r
SubBlockSize = Media->BlockSize;\r
break;\r
LastBlock = BlockIo->Media->LastBlock;\r
MediaId = BlockIo->Media->MediaId;\r
\r
- DEBUG ((EFI_D_INFO, " BlockSize : %d \n", BlockSize));\r
- DEBUG ((EFI_D_INFO, " LastBlock : %lx \n", LastBlock));\r
+ DEBUG ((DEBUG_INFO, " BlockSize : %d \n", BlockSize));\r
+ DEBUG ((DEBUG_INFO, " LastBlock : %lx \n", LastBlock));\r
\r
GptValidStatus = EFI_NOT_FOUND;\r
\r
// Check primary and backup partition tables\r
//\r
if (!PartitionValidGptTable (BlockIo, DiskIo, PRIMARY_PART_HEADER_LBA, PrimaryHeader)) {\r
- DEBUG ((EFI_D_INFO, " Not Valid primary partition table\n"));\r
+ DEBUG ((DEBUG_INFO, " Not Valid primary partition table\n"));\r
\r
if (!PartitionValidGptTable (BlockIo, DiskIo, LastBlock, BackupHeader)) {\r
- DEBUG ((EFI_D_INFO, " Not Valid backup partition table\n"));\r
+ DEBUG ((DEBUG_INFO, " Not Valid backup partition table\n"));\r
goto Done;\r
} else {\r
- DEBUG ((EFI_D_INFO, " Valid backup partition table\n"));\r
- DEBUG ((EFI_D_INFO, " Restore primary partition table by the backup\n"));\r
+ DEBUG ((DEBUG_INFO, " Valid backup partition table\n"));\r
+ DEBUG ((DEBUG_INFO, " Restore primary partition table by the backup\n"));\r
if (!PartitionRestoreGptTable (BlockIo, DiskIo, BackupHeader)) {\r
- DEBUG ((EFI_D_INFO, " Restore primary partition table error\n"));\r
+ DEBUG ((DEBUG_INFO, " Restore primary partition table error\n"));\r
}\r
\r
if (PartitionValidGptTable (BlockIo, DiskIo, BackupHeader->AlternateLBA, PrimaryHeader)) {\r
- DEBUG ((EFI_D_INFO, " Restore backup partition table success\n"));\r
+ DEBUG ((DEBUG_INFO, " Restore backup partition table success\n"));\r
}\r
}\r
} else if (!PartitionValidGptTable (BlockIo, DiskIo, PrimaryHeader->AlternateLBA, BackupHeader)) {\r
- DEBUG ((EFI_D_INFO, " Valid primary and !Valid backup partition table\n"));\r
- DEBUG ((EFI_D_INFO, " Restore backup partition table by the primary\n"));\r
+ DEBUG ((DEBUG_INFO, " Valid primary and !Valid backup partition table\n"));\r
+ DEBUG ((DEBUG_INFO, " Restore backup partition table by the primary\n"));\r
if (!PartitionRestoreGptTable (BlockIo, DiskIo, PrimaryHeader)) {\r
- DEBUG ((EFI_D_INFO, " Restore backup partition table error\n"));\r
+ DEBUG ((DEBUG_INFO, " Restore backup partition table error\n"));\r
}\r
\r
if (PartitionValidGptTable (BlockIo, DiskIo, PrimaryHeader->AlternateLBA, BackupHeader)) {\r
- DEBUG ((EFI_D_INFO, " Restore backup partition table success\n"));\r
+ DEBUG ((DEBUG_INFO, " Restore backup partition table success\n"));\r
}\r
\r
}\r
\r
- DEBUG ((EFI_D_INFO, " Valid primary and Valid backup partition table\n"));\r
+ DEBUG ((DEBUG_INFO, " Valid primary and Valid backup partition table\n"));\r
\r
//\r
// Read the EFI Partition Entries\r
//\r
PartEntry = AllocatePool (PrimaryHeader->NumberOfPartitionEntries * PrimaryHeader->SizeOfPartitionEntry);\r
if (PartEntry == NULL) {\r
- DEBUG ((EFI_D_ERROR, "Allocate pool error\n"));\r
+ DEBUG ((DEBUG_ERROR, "Allocate pool error\n"));\r
goto Done;\r
}\r
\r
);\r
if (EFI_ERROR (Status)) {\r
GptValidStatus = Status;\r
- DEBUG ((EFI_D_ERROR, " Partition Entry ReadDisk error\n"));\r
+ DEBUG ((DEBUG_ERROR, " Partition Entry ReadDisk error\n"));\r
goto Done;\r
}\r
\r
- DEBUG ((EFI_D_INFO, " Partition entries read block success\n"));\r
+ DEBUG ((DEBUG_INFO, " Partition entries read block success\n"));\r
\r
- DEBUG ((EFI_D_INFO, " Number of partition entries: %d\n", PrimaryHeader->NumberOfPartitionEntries));\r
+ DEBUG ((DEBUG_INFO, " Number of partition entries: %d\n", PrimaryHeader->NumberOfPartitionEntries));\r
\r
PEntryStatus = AllocateZeroPool (PrimaryHeader->NumberOfPartitionEntries * sizeof (EFI_PARTITION_ENTRY_STATUS));\r
if (PEntryStatus == NULL) {\r
- DEBUG ((EFI_D_ERROR, "Allocate pool error\n"));\r
+ DEBUG ((DEBUG_ERROR, "Allocate pool error\n"));\r
goto Done;\r
}\r
\r
}\r
CopyMem (&PartitionInfo.Info.Gpt, Entry, sizeof (EFI_PARTITION_ENTRY));\r
\r
- DEBUG ((EFI_D_INFO, " Index : %d\n", (UINT32) Index));\r
- DEBUG ((EFI_D_INFO, " Start LBA : %lx\n", (UINT64) HdDev.PartitionStart));\r
- DEBUG ((EFI_D_INFO, " End LBA : %lx\n", (UINT64) Entry->EndingLBA));\r
- DEBUG ((EFI_D_INFO, " Partition size: %lx\n", (UINT64) HdDev.PartitionSize));\r
- DEBUG ((EFI_D_INFO, " Start : %lx", MultU64x32 (Entry->StartingLBA, BlockSize)));\r
- DEBUG ((EFI_D_INFO, " End : %lx\n", MultU64x32 (Entry->EndingLBA, BlockSize)));\r
+ DEBUG ((DEBUG_INFO, " Index : %d\n", (UINT32) Index));\r
+ DEBUG ((DEBUG_INFO, " Start LBA : %lx\n", (UINT64) HdDev.PartitionStart));\r
+ DEBUG ((DEBUG_INFO, " End LBA : %lx\n", (UINT64) Entry->EndingLBA));\r
+ DEBUG ((DEBUG_INFO, " Partition size: %lx\n", (UINT64) HdDev.PartitionSize));\r
+ DEBUG ((DEBUG_INFO, " Start : %lx", MultU64x32 (Entry->StartingLBA, BlockSize)));\r
+ DEBUG ((DEBUG_INFO, " End : %lx\n", MultU64x32 (Entry->EndingLBA, BlockSize)));\r
\r
Status = PartitionInstallChildHandle (\r
This,\r
);\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Prepare to Free Pool\n"));\r
+ DEBUG ((DEBUG_INFO, "Prepare to Free Pool\n"));\r
\r
Done:\r
if (ProtectiveMbr != NULL) {\r
PartHdr = AllocateZeroPool (BlockSize);\r
\r
if (PartHdr == NULL) {\r
- DEBUG ((EFI_D_ERROR, "Allocate pool error\n"));\r
+ DEBUG ((DEBUG_ERROR, "Allocate pool error\n"));\r
return FALSE;\r
}\r
//\r
PartHdr->MyLBA != Lba ||\r
(PartHdr->SizeOfPartitionEntry < sizeof (EFI_PARTITION_ENTRY))\r
) {\r
- DEBUG ((EFI_D_INFO, "Invalid efi partition table header\n"));\r
+ DEBUG ((DEBUG_INFO, "Invalid efi partition table header\n"));\r
FreePool (PartHdr);\r
return FALSE;\r
}\r
return FALSE;\r
}\r
\r
- DEBUG ((EFI_D_INFO, " Valid efi partition table header\n"));\r
+ DEBUG ((DEBUG_INFO, " Valid efi partition table header\n"));\r
FreePool (PartHdr);\r
return TRUE;\r
}\r
//\r
Ptr = AllocatePool (PartHeader->NumberOfPartitionEntries * PartHeader->SizeOfPartitionEntry);\r
if (Ptr == NULL) {\r
- DEBUG ((EFI_D_ERROR, " Allocate pool error\n"));\r
+ DEBUG ((DEBUG_ERROR, " Allocate pool error\n"));\r
return FALSE;\r
}\r
\r
\r
Status = gBS->CalculateCrc32 (Ptr, Size, &Crc);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "CheckPEntryArrayCRC: Crc calculation failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "CheckPEntryArrayCRC: Crc calculation failed\n"));\r
FreePool (Ptr);\r
return FALSE;\r
}\r
PartHdr = AllocateZeroPool (BlockSize);\r
\r
if (PartHdr == NULL) {\r
- DEBUG ((EFI_D_ERROR, "Allocate pool error\n"));\r
+ DEBUG ((DEBUG_ERROR, "Allocate pool error\n"));\r
return FALSE;\r
}\r
\r
\r
Ptr = AllocatePool (PartHeader->NumberOfPartitionEntries * PartHeader->SizeOfPartitionEntry);\r
if (Ptr == NULL) {\r
- DEBUG ((EFI_D_ERROR, " Allocate pool error\n"));\r
+ DEBUG ((DEBUG_ERROR, " Allocate pool error\n"));\r
Status = EFI_OUT_OF_RESOURCES;\r
goto Done;\r
}\r
UINTN Index1;\r
UINTN Index2;\r
\r
- DEBUG ((EFI_D_INFO, " start check partition entries\n"));\r
+ DEBUG ((DEBUG_INFO, " start check partition entries\n"));\r
for (Index1 = 0; Index1 < PartHeader->NumberOfPartitionEntries; Index1++) {\r
Entry = (EFI_PARTITION_ENTRY *) ((UINT8 *) PartEntry + Index1 * PartHeader->SizeOfPartitionEntry);\r
if (CompareGuid (&Entry->PartitionTypeGUID, &gEfiPartTypeUnusedGuid)) {\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, " End check partition entries\n"));\r
+ DEBUG ((DEBUG_INFO, " End check partition entries\n"));\r
}\r
\r
\r
}\r
\r
if ((MaxSize != 0) && (Size > MaxSize)) {\r
- DEBUG ((EFI_D_ERROR, "CheckCrc32: Size > MaxSize\n"));\r
+ DEBUG ((DEBUG_ERROR, "CheckCrc32: Size > MaxSize\n"));\r
return FALSE;\r
}\r
//\r
\r
Status = gBS->CalculateCrc32 ((UINT8 *) Hdr, Size, &Crc);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "CheckCrc32: Crc calculation failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "CheckCrc32: Crc calculation failed\n"));\r
return FALSE;\r
}\r
//\r
//\r
DEBUG_CODE_BEGIN ();\r
if (OrgCrc != Crc) {\r
- DEBUG ((EFI_D_ERROR, "CheckCrc32: Crc check failed\n"));\r
+ DEBUG ((DEBUG_ERROR, "CheckCrc32: Crc check failed\n"));\r
}\r
DEBUG_CODE_END ();\r
\r
// with INT 13h\r
//\r
\r
- DEBUG((EFI_D_INFO, "PartitionValidMbr: Bad MBR partition size EndingLBA(%1x) > LastLBA(%1x)\n", EndingLBA, LastLba));\r
+ DEBUG((DEBUG_INFO, "PartitionValidMbr: Bad MBR partition size EndingLBA(%1x) > LastLBA(%1x)\n", EndingLBA, LastLba));\r
\r
return FALSE;\r
}\r
// bus driver. Hence, additional check is needed here.\r
//\r
if (HasChildren (ControllerHandle)) {\r
- DEBUG((EFI_D_ERROR, "PartitionDriverBindingStop: Still has child.\n"));\r
+ DEBUG((DEBUG_ERROR, "PartitionDriverBindingStop: Still has child.\n"));\r
return EFI_DEVICE_ERROR;\r
}\r
\r
\r
if (BlockIo2 != NULL) {\r
Status = BlockIo2->FlushBlocksEx (BlockIo2, NULL);\r
- DEBUG((EFI_D_ERROR, "PartitionDriverBindingStop: FlushBlocksEx returned with %r\n", Status));\r
+ DEBUG((DEBUG_ERROR, "PartitionDriverBindingStop: FlushBlocksEx returned with %r\n", Status));\r
} else {\r
Status = EFI_SUCCESS;\r
}\r
\r
return (BOOLEAN) (Index < EntryCount);\r
}\r
-\r
);\r
if (EFI_ERROR (Status)) {\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"RamDiskAcpiCheck: Cannot locate the EFI ACPI Table Protocol, "\r
"unable to publish RAM disks to NFIT.\n"\r
));\r
);\r
if (EFI_ERROR (Status)) {\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"RamDiskAcpiCheck: Cannot locate the EFI ACPI Sdt Protocol, "\r
"unable to publish RAM disks to NFIT.\n"\r
));\r
&DummyInterface\r
);\r
if (!EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "Driver already started!\n"));\r
+ DEBUG ((DEBUG_INFO, "Driver already started!\n"));\r
return EFI_ALREADY_STARTED;\r
}\r
\r
>= PrivateData->StartingAddr + PrivateData->Size)) {\r
MemoryFound = TRUE;\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"RamDiskPublishNfit: RAM disk with reserved memory type, will publish to NFIT.\n"\r
));\r
break;\r
// A NFIT is already in the ACPI table.\r
//\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"RamDiskPublishNfit: A NFIT is already exist in the ACPI Table.\n"\r
));\r
\r
// No NFIT is in the ACPI table, we will create one here.\r
//\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"RamDiskPublishNfit: No NFIT is in the ACPI Table, will create one.\n"\r
));\r
\r
IN UINTN Limit\r
)\r
{\r
- DEBUG ((EFI_D_INFO, "[DriverHealthManagement]RepairNotify: %d/%d\n", Value, Limit));\r
+ DEBUG ((DEBUG_INFO, "[DriverHealthManagement]RepairNotify: %d/%d\n", Value, Limit));\r
return EFI_SUCCESS;\r
}\r
\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
- DEBUG ((EFI_D_ERROR, "QuestionId = %x\n", QuestionId));\r
+ DEBUG ((DEBUG_ERROR, "QuestionId = %x\n", QuestionId));\r
\r
//\r
// We will have returned from processing a callback - user either hit ESC to exit, or selected\r
\r
return EFI_SUCCESS;\r
}\r
-\r
-\r
// We print debug information to let user know what happen.\r
//\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
"EBC Interrupter Version - 0x%016lx\n",\r
(UINT64) (((VM_MAJOR_VERSION & 0xFFFF) << 16) | ((VM_MINOR_VERSION & 0xFFFF)))\r
));\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
"Exception Type - 0x%016lx\n",\r
(UINT64)(UINTN)InterruptType\r
));\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
" R0 - 0x%016lx, R1 - 0x%016lx\n",\r
SystemContext.SystemContextEbc->R0,\r
SystemContext.SystemContextEbc->R1\r
));\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
" R2 - 0x%016lx, R3 - 0x%016lx\n",\r
SystemContext.SystemContextEbc->R2,\r
SystemContext.SystemContextEbc->R3\r
));\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
" R4 - 0x%016lx, R5 - 0x%016lx\n",\r
SystemContext.SystemContextEbc->R4,\r
SystemContext.SystemContextEbc->R5\r
));\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
" R6 - 0x%016lx, R7 - 0x%016lx\n",\r
SystemContext.SystemContextEbc->R6,\r
SystemContext.SystemContextEbc->R7\r
));\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
" Flags - 0x%016lx\n",\r
SystemContext.SystemContextEbc->Flags\r
));\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
" ControlFlags - 0x%016lx\n",\r
SystemContext.SystemContextEbc->ControlFlags\r
));\r
DEBUG ((\r
- EFI_D_ERROR,\r
+ DEBUG_ERROR,\r
" Ip - 0x%016lx\n\n",\r
SystemContext.SystemContextEbc->Ip\r
));\r
Status = gBS->LocateProtocol (&gEdkiiVariableLockProtocolGuid, NULL, (VOID **) &VariableLock);\r
if (!EFI_ERROR (Status)) {\r
Status = VariableLock->RequestToLock (VariableLock, EFI_ESRT_FMP_VARIABLE_NAME, &gEfiCallerIdGuid);\r
- DEBUG((EFI_D_INFO, "EsrtDxe Lock EsrtFmp Variable Status 0x%x", Status));\r
+ DEBUG((DEBUG_INFO, "EsrtDxe Lock EsrtFmp Variable Status 0x%x", Status));\r
\r
Status = VariableLock->RequestToLock (VariableLock, EFI_ESRT_NONFMP_VARIABLE_NAME, &gEfiCallerIdGuid);\r
- DEBUG((EFI_D_INFO, "EsrtDxe Lock EsrtNonFmp Variable Status 0x%x", Status));\r
+ DEBUG((DEBUG_INFO, "EsrtDxe Lock EsrtNonFmp Variable Status 0x%x", Status));\r
}\r
\r
return Status;\r
}\r
\r
if (NonFmpRepositorySize % sizeof(EFI_SYSTEM_RESOURCE_ENTRY) != 0) {\r
- DEBUG((EFI_D_ERROR, "NonFmp Repository Corrupt. Need to rebuild NonFmp Repository.\n"));\r
+ DEBUG((DEBUG_ERROR, "NonFmp Repository Corrupt. Need to rebuild NonFmp Repository.\n"));\r
NonFmpRepositorySize = 0;\r
}\r
\r
}\r
\r
if (FmpRepositorySize % sizeof(EFI_SYSTEM_RESOURCE_ENTRY) != 0) {\r
- DEBUG((EFI_D_ERROR, "Fmp Repository Corrupt. Need to rebuild Fmp Repository.\n"));\r
+ DEBUG((DEBUG_ERROR, "Fmp Repository Corrupt. Need to rebuild Fmp Repository.\n"));\r
FmpRepositorySize = 0;\r
}\r
\r
\r
EsrtTable = AllocatePool(sizeof(EFI_SYSTEM_RESOURCE_TABLE) + NonFmpRepositorySize + FmpRepositorySize);\r
if (EsrtTable == NULL) {\r
- DEBUG ((EFI_D_ERROR, "Esrt table memory allocation failure\n"));\r
+ DEBUG ((DEBUG_ERROR, "Esrt table memory allocation failure\n"));\r
goto EXIT;\r
}\r
\r
}\r
\r
if (RepositorySize % sizeof(EFI_SYSTEM_RESOURCE_ENTRY) != 0) {\r
- DEBUG((EFI_D_ERROR, "Repository Corrupt. Need to rebuild Repository.\n"));\r
+ DEBUG((DEBUG_ERROR, "Repository Corrupt. Need to rebuild Repository.\n"));\r
Status = EFI_ABORTED;\r
goto EXIT;\r
}\r
// if exist, update Esrt cache repository\r
//\r
if (RepositorySize % sizeof(EFI_SYSTEM_RESOURCE_ENTRY) != 0) {\r
- DEBUG((EFI_D_ERROR, "Repository Corrupt. Need to rebuild Repository.\n"));\r
+ DEBUG((DEBUG_ERROR, "Repository Corrupt. Need to rebuild Repository.\n"));\r
//\r
// Repository is corrupt. Clear Repository before insert new entry\r
//\r
}\r
\r
if ((RepositorySize % sizeof(EFI_SYSTEM_RESOURCE_ENTRY)) != 0) {\r
- DEBUG((EFI_D_ERROR, "Repository Corrupt. Need to rebuild Repository.\n"));\r
+ DEBUG((DEBUG_ERROR, "Repository Corrupt. Need to rebuild Repository.\n"));\r
//\r
// Repository is corrupt. Clear Repository before insert new entry\r
//\r
// if exist, update Esrt cache repository\r
//\r
if (RepositorySize % sizeof(EFI_SYSTEM_RESOURCE_ENTRY) != 0) {\r
- DEBUG((EFI_D_ERROR, "Repository Corrupt. Need to rebuild Repository.\n"));\r
+ DEBUG((DEBUG_ERROR, "Repository Corrupt. Need to rebuild Repository.\n"));\r
//\r
// Repository is corrupt. Clear Repository before insert new entry\r
//\r
// Check if there is enough space for the coming allocation\r
//\r
if (FTW_WRITE_TOTAL_SIZE (NumberOfWrites, PrivateDataSize) > FtwDevice->FtwWorkSpaceHeader->WriteQueueSize) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Allocate() request exceed Workspace, Caller: %g\n", CallerId));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Allocate() request exceed Workspace, Caller: %g\n", CallerId));\r
return EFI_BUFFER_TOO_SMALL;\r
}\r
//\r
}\r
\r
DEBUG (\r
- (EFI_D_INFO,\r
+ (DEBUG_INFO,\r
"Ftw: Allocate() success, Caller:%g, # %d\n",\r
CallerId,\r
NumberOfWrites)\r
// Ftw Write Header is not allocated\r
// Additional private data is not NULL, the private data size can't be determined.\r
//\r
- DEBUG ((EFI_D_ERROR, "Ftw: no allocates space for write record!\n"));\r
- DEBUG ((EFI_D_ERROR, "Ftw: Allocate service should be called before Write service!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: no allocates space for write record!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Allocate service should be called before Write service!\n"));\r
return EFI_NOT_READY;\r
}\r
}\r
\r
Status = Fvb->GetPhysicalAddress (Fvb, &FvbPhysicalAddress);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Write(), Get FVB physical address - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Write(), Get FVB physical address - %r\n", Status));\r
return EFI_ABORTED;\r
}\r
\r
//\r
Status = Fvb->GetBlockSize (Fvb, 0, &BlockSize, &NumberOfBlocks);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Write(), Get block size - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Write(), Get block size - %r\n", Status));\r
return EFI_ABORTED;\r
}\r
\r
NumberOfWriteBlocks = FTW_BLOCKS (Offset + Length, BlockSize);\r
- DEBUG ((EFI_D_INFO, "Ftw: Write(), BlockSize - 0x%x, NumberOfWriteBlock - 0x%x\n", BlockSize, NumberOfWriteBlocks));\r
+ DEBUG ((DEBUG_INFO, "Ftw: Write(), BlockSize - 0x%x, NumberOfWriteBlock - 0x%x\n", BlockSize, NumberOfWriteBlocks));\r
WriteLength = NumberOfWriteBlocks * BlockSize;\r
\r
//\r
FreePool (SpareBuffer);\r
\r
DEBUG (\r
- (EFI_D_INFO,\r
+ (DEBUG_INFO,\r
"Ftw: Write() success, (Lba:Offset)=(%lx:0x%x), Length: 0x%x\n",\r
Lba,\r
Offset,\r
//\r
Status = Fvb->GetBlockSize (Fvb, 0, &BlockSize, &NumberOfBlocks);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Restart(), Get block size - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Restart(), Get block size - %r\n", Status));\r
return EFI_ABORTED;\r
}\r
\r
return EFI_ABORTED;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "%a(): success\n", __FUNCTION__));\r
+ DEBUG ((DEBUG_INFO, "%a(): success\n", __FUNCTION__));\r
return EFI_SUCCESS;\r
}\r
\r
\r
FtwDevice->FtwLastWriteHeader->Complete = FTW_VALID_STATE;\r
\r
- DEBUG ((EFI_D_INFO, "%a(): success\n", __FUNCTION__));\r
+ DEBUG ((DEBUG_INFO, "%a(): success\n", __FUNCTION__));\r
return EFI_SUCCESS;\r
}\r
\r
Status = EFI_SUCCESS;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "%a(): success\n", __FUNCTION__));\r
+ DEBUG ((DEBUG_INFO, "%a(): success\n", __FUNCTION__));\r
\r
return Status;\r
}\r
-\r
TempCommBufferSize = *CommBufferSize;\r
\r
if (TempCommBufferSize < SMM_FTW_COMMUNICATE_HEADER_SIZE) {\r
- DEBUG ((EFI_D_ERROR, "SmmFtwHandler: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmFtwHandler: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
CommBufferPayloadSize = TempCommBufferSize - SMM_FTW_COMMUNICATE_HEADER_SIZE;\r
\r
if (!FtwSmmIsBufferOutsideSmmValid ((UINTN)CommBuffer, TempCommBufferSize)) {\r
- DEBUG ((EFI_D_ERROR, "SmmFtwHandler: SMM communication buffer in SMRAM or overflow!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmFtwHandler: SMM communication buffer in SMRAM or overflow!\n"));\r
return EFI_SUCCESS;\r
}\r
\r
//\r
// It will be not safe to expose the operations after End Of Dxe.\r
//\r
- DEBUG ((EFI_D_ERROR, "SmmFtwHandler: Not safe to do the operation: %x after End Of Dxe, so access denied!\n", SmmFtwFunctionHeader->Function));\r
+ DEBUG ((DEBUG_ERROR, "SmmFtwHandler: Not safe to do the operation: %x after End Of Dxe, so access denied!\n", SmmFtwFunctionHeader->Function));\r
SmmFtwFunctionHeader->ReturnStatus = EFI_ACCESS_DENIED;\r
return EFI_SUCCESS;\r
}\r
switch (SmmFtwFunctionHeader->Function) {\r
case FTW_FUNCTION_GET_MAX_BLOCK_SIZE:\r
if (CommBufferPayloadSize < sizeof (SMM_FTW_GET_MAX_BLOCK_SIZE_HEADER)) {\r
- DEBUG ((EFI_D_ERROR, "GetMaxBlockSize: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "GetMaxBlockSize: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
SmmGetMaxBlockSizeHeader = (SMM_FTW_GET_MAX_BLOCK_SIZE_HEADER *) SmmFtwFunctionHeader->Data;\r
\r
case FTW_FUNCTION_ALLOCATE:\r
if (CommBufferPayloadSize < sizeof (SMM_FTW_ALLOCATE_HEADER)) {\r
- DEBUG ((EFI_D_ERROR, "Allocate: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Allocate: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
SmmFtwAllocateHeader = (SMM_FTW_ALLOCATE_HEADER *) SmmFtwFunctionHeader->Data;\r
\r
case FTW_FUNCTION_WRITE:\r
if (CommBufferPayloadSize < OFFSET_OF (SMM_FTW_WRITE_HEADER, Data)) {\r
- DEBUG ((EFI_D_ERROR, "Write: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Write: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
SmmFtwWriteHeader = (SMM_FTW_WRITE_HEADER *) SmmFtwFunctionHeader->Data;\r
// SMRAM range check already covered before\r
//\r
if (InfoSize > CommBufferPayloadSize) {\r
- DEBUG ((EFI_D_ERROR, "Write: Data size exceed communication buffer size limit!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Write: Data size exceed communication buffer size limit!\n"));\r
Status = EFI_ACCESS_DENIED;\r
break;\r
}\r
\r
case FTW_FUNCTION_RESTART:\r
if (CommBufferPayloadSize < sizeof (SMM_FTW_RESTART_HEADER)) {\r
- DEBUG ((EFI_D_ERROR, "Restart: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Restart: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
SmmFtwRestartHeader = (SMM_FTW_RESTART_HEADER *) SmmFtwFunctionHeader->Data;\r
\r
case FTW_FUNCTION_GET_LAST_WRITE:\r
if (CommBufferPayloadSize < OFFSET_OF (SMM_FTW_GET_LAST_WRITE_HEADER, Data)) {\r
- DEBUG ((EFI_D_ERROR, "GetLastWrite: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "GetLastWrite: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
SmmFtwGetLastWriteHeader = (SMM_FTW_GET_LAST_WRITE_HEADER *) SmmFtwFunctionHeader->Data;\r
// SMRAM range check already covered before\r
//\r
if (InfoSize > CommBufferPayloadSize) {\r
- DEBUG ((EFI_D_ERROR, "Data size exceed communication buffer size limit!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Data size exceed communication buffer size limit!\n"));\r
Status = EFI_ACCESS_DENIED;\r
break;\r
}\r
//\r
Status = SarProtocol->GetSwapState (SarProtocol, &TopSwap);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Get Top Swapped status - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Get Top Swapped status - %r\n", Status));\r
FreePool (Buffer);\r
return EFI_ABORTED;\r
}\r
Ptr\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: FVB Write boot block - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: FVB Write boot block - %r\n", Status));\r
FreePool (Buffer);\r
return Status;\r
}\r
Count = BlockSize;\r
Status = FvBlock->Write (FvBlock, Lba + Index, 0, &Count, Ptr);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: FVB Write block - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: FVB Write block - %r\n", Status));\r
FreePool (Buffer);\r
return Status;\r
}\r
Ptr\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: FVB Write block - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: FVB Write block - %r\n", Status));\r
FreePool (Buffer);\r
return Status;\r
}\r
FtwDevice->WorkSpaceLength = (UINTN) PcdGet32 (PcdFlashNvStorageFtwWorkingSize);\r
FtwDevice->SpareAreaLength = (UINTN) PcdGet32 (PcdFlashNvStorageFtwSpareSize);\r
if ((FtwDevice->WorkSpaceLength == 0) || (FtwDevice->SpareAreaLength == 0)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Workspace or Spare block does not exist!\n"));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Workspace or Spare block does not exist!\n"));\r
FreePool (FtwDevice);\r
return EFI_INVALID_PARAMETER;\r
}\r
//\r
if (((FtwDevice->WorkSpaceAddress & (FtwDevice->WorkBlockSize - 1)) != 0) ||\r
((FtwDevice->WorkSpaceLength & (FtwDevice->WorkBlockSize - 1)) != 0)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Work space address or length is not block size aligned when work space size is larger than one block size\n"));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Work space address or length is not block size aligned when work space size is larger than one block size\n"));\r
FreePool (HandleBuffer);\r
ASSERT (FALSE);\r
return EFI_ABORTED;\r
}\r
} else if ((FtwDevice->FtwWorkSpaceBase + FtwDevice->FtwWorkSpaceSize) > FtwDevice->WorkBlockSize) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: The work space range should not span blocks when work space size is less than one block size\n"));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: The work space range should not span blocks when work space size is less than one block size\n"));\r
FreePool (HandleBuffer);\r
ASSERT (FALSE);\r
return EFI_ABORTED;\r
// Check the range of spare area to make sure that it's in FV range\r
//\r
if ((FtwDevice->FtwSpareLba + FtwDevice->NumberOfSpareBlock) > NumberOfBlocks) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Spare area is out of FV range\n"));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Spare area is out of FV range\n"));\r
FreePool (HandleBuffer);\r
ASSERT (FALSE);\r
return EFI_ABORTED;\r
//\r
if (((FtwDevice->SpareAreaAddress & (FtwDevice->SpareBlockSize - 1)) != 0) ||\r
((FtwDevice->SpareAreaLength & (FtwDevice->SpareBlockSize - 1)) != 0)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Spare area address or length is not block size aligned\n"));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Spare area address or length is not block size aligned\n"));\r
FreePool (HandleBuffer);\r
//\r
// Report Status Code EFI_SW_EC_ABORTED.\r
(FtwDevice->FtwWorkSpaceLba == (EFI_LBA) (-1)) || (FtwDevice->FtwSpareLba == (EFI_LBA) (-1))) {\r
return EFI_ABORTED;\r
}\r
- DEBUG ((EFI_D_INFO, "Ftw: FtwWorkSpaceLba - 0x%lx, WorkBlockSize - 0x%x, FtwWorkSpaceBase - 0x%x\n", FtwDevice->FtwWorkSpaceLba, FtwDevice->WorkBlockSize, FtwDevice->FtwWorkSpaceBase));\r
- DEBUG ((EFI_D_INFO, "Ftw: FtwSpareLba - 0x%lx, SpareBlockSize - 0x%x\n", FtwDevice->FtwSpareLba, FtwDevice->SpareBlockSize));\r
+ DEBUG ((DEBUG_INFO, "Ftw: FtwWorkSpaceLba - 0x%lx, WorkBlockSize - 0x%x, FtwWorkSpaceBase - 0x%x\n", FtwDevice->FtwWorkSpaceLba, FtwDevice->WorkBlockSize, FtwDevice->FtwWorkSpaceBase));\r
+ DEBUG ((DEBUG_INFO, "Ftw: FtwSpareLba - 0x%lx, SpareBlockSize - 0x%x\n", FtwDevice->FtwSpareLba, FtwDevice->SpareBlockSize));\r
\r
return EFI_SUCCESS;\r
}\r
}\r
}\r
FtwDevice->FtwWorkBlockLba = FtwDevice->FtwWorkSpaceLba + FtwDevice->NumberOfWorkSpaceBlock - FtwDevice->NumberOfWorkBlock;\r
- DEBUG ((EFI_D_INFO, "Ftw: NumberOfWorkBlock - 0x%x, FtwWorkBlockLba - 0x%lx\n", FtwDevice->NumberOfWorkBlock, FtwDevice->FtwWorkBlockLba));\r
+ DEBUG ((DEBUG_INFO, "Ftw: NumberOfWorkBlock - 0x%x, FtwWorkBlockLba - 0x%lx\n", FtwDevice->NumberOfWorkBlock, FtwDevice->FtwWorkBlockLba));\r
\r
//\r
// Calcualte the LBA and base of work space in spare block.\r
WorkSpaceLbaOffset = FtwDevice->FtwWorkSpaceLba - FtwDevice->FtwWorkBlockLba;\r
FtwDevice->FtwWorkSpaceLbaInSpare = (EFI_LBA) (((UINTN) WorkSpaceLbaOffset * FtwDevice->WorkBlockSize + FtwDevice->FtwWorkSpaceBase) / FtwDevice->SpareBlockSize);\r
FtwDevice->FtwWorkSpaceBaseInSpare = ((UINTN) WorkSpaceLbaOffset * FtwDevice->WorkBlockSize + FtwDevice->FtwWorkSpaceBase) % FtwDevice->SpareBlockSize;\r
- DEBUG ((EFI_D_INFO, "Ftw: WorkSpaceLbaInSpare - 0x%lx, WorkSpaceBaseInSpare - 0x%x\n", FtwDevice->FtwWorkSpaceLbaInSpare, FtwDevice->FtwWorkSpaceBaseInSpare));\r
+ DEBUG ((DEBUG_INFO, "Ftw: WorkSpaceLbaInSpare - 0x%lx, WorkSpaceBaseInSpare - 0x%x\n", FtwDevice->FtwWorkSpaceLbaInSpare, FtwDevice->FtwWorkSpaceBaseInSpare));\r
\r
//\r
// Initialize other parameters, and set WorkSpace as FTW_ERASED_BYTE.\r
//\r
if (IsValidWorkSpace (FtwDevice->FtwWorkSpaceHeader)) {\r
Status = FlushSpareBlockToWorkingBlock (FtwDevice);\r
- DEBUG ((EFI_D_INFO, "Ftw: Restart working block update in %a() - %r\n",\r
+ DEBUG ((DEBUG_INFO, "Ftw: Restart working block update in %a() - %r\n",\r
__FUNCTION__, Status));\r
FtwAbort (&FtwDevice->FtwInstance);\r
//\r
Status = WorkSpaceRefresh (FtwDevice);\r
ASSERT_EFI_ERROR (Status);\r
} else {\r
- DEBUG ((EFI_D_INFO,\r
+ DEBUG ((DEBUG_INFO,\r
"Ftw: Both working and spare blocks are invalid, init workspace\n"));\r
//\r
// If both are invalid, then initialize work space.\r
(FtwDevice->FtwLastWriteRecord->SpareComplete != FTW_VALID_STATE) &&\r
IsFirstRecordOfWrites (FtwDevice->FtwLastWriteHeader, FtwDevice->FtwLastWriteRecord)\r
) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Init.. find first record not SpareCompleted, abort()\n"));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Init.. find first record not SpareCompleted, abort()\n"));\r
FtwAbort (&FtwDevice->FtwInstance);\r
}\r
//\r
(FtwDevice->FtwLastWriteRecord->DestinationComplete == FTW_VALID_STATE) &&\r
IsLastRecordOfWrites (FtwDevice->FtwLastWriteHeader, FtwDevice->FtwLastWriteRecord)\r
) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Init.. find last record completed but header not, abort()\n"));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Init.. find last record completed but header not, abort()\n"));\r
FtwAbort (&FtwDevice->FtwInstance);\r
}\r
//\r
) {\r
if (FtwDevice->FtwLastWriteRecord->BootBlockUpdate == FTW_VALID_STATE) {\r
Status = FlushSpareBlockToBootBlock (FtwDevice);\r
- DEBUG ((EFI_D_ERROR, "Ftw: Restart boot block update - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Restart boot block update - %r\n", Status));\r
ASSERT_EFI_ERROR (Status);\r
FtwAbort (&FtwDevice->FtwInstance);\r
} else {\r
FvbHandle = GetFvbByAddress ((EFI_PHYSICAL_ADDRESS) (UINTN) ((INT64) FtwDevice->SpareAreaAddress + FtwDevice->FtwLastWriteRecord->RelativeOffset), &Fvb);\r
if (FvbHandle != NULL) {\r
Status = FtwRestart (&FtwDevice->FtwInstance, FvbHandle);\r
- DEBUG ((EFI_D_ERROR, "Ftw: Restart last write - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Restart last write - %r\n", Status));\r
ASSERT_EFI_ERROR (Status);\r
}\r
FtwAbort (&FtwDevice->FtwInstance);\r
\r
return EFI_SUCCESS;\r
}\r
-\r
return TRUE;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Ftw: Work block header check mismatch\n"));\r
+ DEBUG ((DEBUG_INFO, "Ftw: Work block header check mismatch\n"));\r
return FALSE;\r
}\r
\r
&FtwDevice->FtwLastWriteHeader\r
);\r
RemainingSpaceSize = FtwDevice->FtwWorkSpaceSize - ((UINTN) FtwDevice->FtwLastWriteHeader - (UINTN) FtwDevice->FtwWorkSpace);\r
- DEBUG ((EFI_D_INFO, "Ftw: Remaining work space size - %x\n", RemainingSpaceSize));\r
+ DEBUG ((DEBUG_INFO, "Ftw: Remaining work space size - %x\n", RemainingSpaceSize));\r
//\r
// If FtwGetLastWriteHeader() returns error, or the remaining space size is even not enough to contain\r
// one EFI_FAULT_TOLERANT_WRITE_HEADER + one EFI_FAULT_TOLERANT_WRITE_RECORD(It will cause that the header\r
//\r
Status = FtwReclaimWorkSpace (FtwDevice, TRUE);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "Ftw: Reclaim workspace - %r\n", Status));\r
+ DEBUG ((DEBUG_ERROR, "Ftw: Reclaim workspace - %r\n", Status));\r
return EFI_ABORTED;\r
}\r
//\r
UINT8 *Ptr;\r
EFI_LBA WorkSpaceLbaOffset;\r
\r
- DEBUG ((EFI_D_INFO, "Ftw: start to reclaim work space\n"));\r
+ DEBUG ((DEBUG_INFO, "Ftw: start to reclaim work space\n"));\r
\r
WorkSpaceLbaOffset = FtwDevice->FtwWorkSpaceLba - FtwDevice->FtwWorkBlockLba;\r
\r
\r
FreePool (SpareBuffer);\r
\r
- DEBUG ((EFI_D_INFO, "Ftw: reclaim work space successfully\n"));\r
+ DEBUG ((DEBUG_INFO, "Ftw: reclaim work space successfully\n"));\r
\r
return EFI_SUCCESS;\r
}\r
}\r
\r
if ((WorkingHeader->WorkingBlockValid != FTW_VALID_STATE) || (WorkingHeader->WorkingBlockInvalid == FTW_VALID_STATE)) {\r
- DEBUG ((EFI_D_ERROR, "FtwPei: Work block header valid bit check error\n"));\r
+ DEBUG ((DEBUG_ERROR, "FtwPei: Work block header valid bit check error\n"));\r
return FALSE;\r
}\r
\r
if (WorkingHeader->WriteQueueSize != (WorkingLength - sizeof (EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER))) {\r
- DEBUG ((EFI_D_ERROR, "FtwPei: Work block header WriteQueueSize check error\n"));\r
+ DEBUG ((DEBUG_ERROR, "FtwPei: Work block header WriteQueueSize check error\n"));\r
return FALSE;\r
}\r
\r
// Check signature with gEdkiiWorkingBlockSignatureGuid\r
//\r
if (!CompareGuid (&gEdkiiWorkingBlockSignatureGuid, &WorkingHeader->Signature)) {\r
- DEBUG ((EFI_D_ERROR, "FtwPei: Work block header signature check error, it should be gEdkiiWorkingBlockSignatureGuid\n"));\r
+ DEBUG ((DEBUG_ERROR, "FtwPei: Work block header signature check error, it should be gEdkiiWorkingBlockSignatureGuid\n"));\r
//\r
// To be compatible with old signature gEfiSystemNvDataFvGuid.\r
//\r
} else {\r
Data = *(UINT8 *) (WorkingHeader + 1);\r
if (Data != 0xff) {\r
- DEBUG ((EFI_D_ERROR, "FtwPei: Old format FTW structure can't be handled\n"));\r
+ DEBUG ((DEBUG_ERROR, "FtwPei: Old format FTW structure can't be handled\n"));\r
ASSERT (FALSE);\r
return FALSE;\r
}\r
FtwLastWrite.SpareAddress = SpareAreaAddress;\r
FtwLastWrite.Length = SpareAreaLength;\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"FtwPei last write data: TargetAddress - 0x%x SpareAddress - 0x%x Length - 0x%x\n",\r
(UINTN) FtwLastWrite.TargetAddress,\r
(UINTN) FtwLastWrite.SpareAddress,\r
//\r
// Found the workspace.\r
//\r
- DEBUG ((EFI_D_INFO, "FtwPei: workspace in spare block is at 0x%x.\n", (UINTN) WorkSpaceInSpareArea));\r
+ DEBUG ((DEBUG_INFO, "FtwPei: workspace in spare block is at 0x%x.\n", (UINTN) WorkSpaceInSpareArea));\r
FtwWorkingBlockHeader = (EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER *) (UINTN) WorkSpaceInSpareArea;\r
break;\r
}\r
FtwLastWrite.SpareAddress = SpareAreaAddress;\r
FtwLastWrite.Length = SpareAreaLength;\r
DEBUG ((\r
- EFI_D_INFO,\r
+ DEBUG_INFO,\r
"FtwPei last write data: TargetAddress - 0x%x SpareAddress - 0x%x Length - 0x%x\n",\r
(UINTN) FtwLastWrite.TargetAddress,\r
(UINTN) FtwLastWrite.SpareAddress,\r
//\r
// Both are invalid.\r
//\r
- DEBUG ((EFI_D_ERROR, "FtwPei: Both working and spare block are invalid.\n"));\r
+ DEBUG ((DEBUG_ERROR, "FtwPei: Both working and spare block are invalid.\n"));\r
}\r
}\r
\r
// Header->VarStoreId == 0 means no storage for this question.\r
//\r
ASSERT (Header->VarStoreId != 0);\r
- DEBUG ((EFI_D_INFO, "Varstore Id: 0x%x\n", Header->VarStoreId));\r
+ DEBUG ((DEBUG_INFO, "Varstore Id: 0x%x\n", Header->VarStoreId));\r
\r
Storage = FindStorageFromVarId (FormPackage, Header->VarStoreId);\r
ASSERT (Storage != NULL);\r
// Header->VarStoreId == 0 means no storage for this question.\r
//\r
ASSERT (Header->VarStoreId != 0);\r
- DEBUG ((EFI_D_INFO, "Varstore Id: 0x%x\n", Header->VarStoreId));\r
+ DEBUG ((DEBUG_INFO, "Varstore Id: 0x%x\n", Header->VarStoreId));\r
\r
Storage = FindStorageFromVarId (FormPackage, Header->VarStoreId);\r
ASSERT (Storage != NULL);\r
// Sanity check\r
//\r
if (mLocked) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Locked!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Locked!\n"));\r
LockBoxParameterSave->Header.ReturnStatus = (UINT64)EFI_ACCESS_DENIED;\r
return ;\r
}\r
// Sanity check\r
//\r
if (!SmmIsBufferOutsideSmmValid ((UINTN)TempLockBoxParameterSave.Buffer, (UINTN)TempLockBoxParameterSave.Length)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Save address in SMRAM or buffer overflow!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Save address in SMRAM or buffer overflow!\n"));\r
LockBoxParameterSave->Header.ReturnStatus = (UINT64)EFI_ACCESS_DENIED;\r
return ;\r
}\r
// Sanity check\r
//\r
if (mLocked) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Locked!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Locked!\n"));\r
LockBoxParameterSetAttributes->Header.ReturnStatus = (UINT64)EFI_ACCESS_DENIED;\r
return ;\r
}\r
// Sanity check\r
//\r
if (mLocked) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Locked!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Locked!\n"));\r
LockBoxParameterUpdate->Header.ReturnStatus = (UINT64)EFI_ACCESS_DENIED;\r
return ;\r
}\r
// Sanity check\r
//\r
if (!SmmIsBufferOutsideSmmValid ((UINTN)TempLockBoxParameterUpdate.Buffer, (UINTN)TempLockBoxParameterUpdate.Length)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Update address in SMRAM or buffer overflow!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Update address in SMRAM or buffer overflow!\n"));\r
LockBoxParameterUpdate->Header.ReturnStatus = (UINT64)EFI_ACCESS_DENIED;\r
return ;\r
}\r
// Sanity check\r
//\r
if (!SmmIsBufferOutsideSmmValid ((UINTN)TempLockBoxParameterRestore.Buffer, (UINTN)TempLockBoxParameterRestore.Length)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Restore address in SMRAM or buffer overflow!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Restore address in SMRAM or buffer overflow!\n"));\r
LockBoxParameterRestore->Header.ReturnStatus = (UINT64)EFI_ACCESS_DENIED;\r
return ;\r
}\r
// Sanity check\r
//\r
if (TempCommBufferSize < sizeof(EFI_SMM_LOCK_BOX_PARAMETER_HEADER)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Command Buffer Size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Command Buffer Size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
if (!SmmIsBufferOutsideSmmValid ((UINTN)CommBuffer, TempCommBufferSize)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Command Buffer in SMRAM or overflow!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Command Buffer in SMRAM or overflow!\n"));\r
return EFI_SUCCESS;\r
}\r
\r
switch (LockBoxParameterHeader->Command) {\r
case EFI_SMM_LOCK_BOX_COMMAND_SAVE:\r
if (TempCommBufferSize < sizeof(EFI_SMM_LOCK_BOX_PARAMETER_SAVE)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Command Buffer Size for SAVE invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Command Buffer Size for SAVE invalid!\n"));\r
break;\r
}\r
SmmLockBoxSave ((EFI_SMM_LOCK_BOX_PARAMETER_SAVE *)(UINTN)LockBoxParameterHeader);\r
break;\r
case EFI_SMM_LOCK_BOX_COMMAND_UPDATE:\r
if (TempCommBufferSize < sizeof(EFI_SMM_LOCK_BOX_PARAMETER_UPDATE)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Command Buffer Size for UPDATE invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Command Buffer Size for UPDATE invalid!\n"));\r
break;\r
}\r
SmmLockBoxUpdate ((EFI_SMM_LOCK_BOX_PARAMETER_UPDATE *)(UINTN)LockBoxParameterHeader);\r
break;\r
case EFI_SMM_LOCK_BOX_COMMAND_RESTORE:\r
if (TempCommBufferSize < sizeof(EFI_SMM_LOCK_BOX_PARAMETER_RESTORE)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Command Buffer Size for RESTORE invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Command Buffer Size for RESTORE invalid!\n"));\r
break;\r
}\r
SmmLockBoxRestore ((EFI_SMM_LOCK_BOX_PARAMETER_RESTORE *)(UINTN)LockBoxParameterHeader);\r
break;\r
case EFI_SMM_LOCK_BOX_COMMAND_SET_ATTRIBUTES:\r
if (TempCommBufferSize < sizeof(EFI_SMM_LOCK_BOX_PARAMETER_SET_ATTRIBUTES)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Command Buffer Size for SET_ATTRIBUTES invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Command Buffer Size for SET_ATTRIBUTES invalid!\n"));\r
break;\r
}\r
SmmLockBoxSetAttributes ((EFI_SMM_LOCK_BOX_PARAMETER_SET_ATTRIBUTES *)(UINTN)LockBoxParameterHeader);\r
break;\r
case EFI_SMM_LOCK_BOX_COMMAND_RESTORE_ALL_IN_PLACE:\r
if (TempCommBufferSize < sizeof(EFI_SMM_LOCK_BOX_PARAMETER_RESTORE_ALL_IN_PLACE)) {\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Command Buffer Size for RESTORE_ALL_IN_PLACE invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Command Buffer Size for RESTORE_ALL_IN_PLACE invalid!\n"));\r
break;\r
}\r
SmmLockBoxRestoreAllInPlace ((EFI_SMM_LOCK_BOX_PARAMETER_RESTORE_ALL_IN_PLACE *)(UINTN)LockBoxParameterHeader);\r
break;\r
default:\r
- DEBUG ((EFI_D_ERROR, "SmmLockBox Command invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmLockBox Command invalid!\n"));\r
break;\r
}\r
\r
//\r
if ((EntryPointStructure != NULL) &&\r
(EntryPointStructure->TableLength + StructureSize > SMBIOS_TABLE_MAX_LENGTH)) {\r
- DEBUG ((EFI_D_INFO, "SmbiosAdd: Total length exceeds max 32-bit table length with type = %d size = 0x%x\n", Record->Type, StructureSize));\r
+ DEBUG ((DEBUG_INFO, "SmbiosAdd: Total length exceeds max 32-bit table length with type = %d size = 0x%x\n", Record->Type, StructureSize));\r
} else {\r
Smbios32BitTable = TRUE;\r
- DEBUG ((EFI_D_INFO, "SmbiosAdd: Smbios type %d with size 0x%x is added to 32-bit table\n", Record->Type, StructureSize));\r
+ DEBUG ((DEBUG_INFO, "SmbiosAdd: Smbios type %d with size 0x%x is added to 32-bit table\n", Record->Type, StructureSize));\r
}\r
}\r
\r
//\r
if ((Smbios30EntryPointStructure != NULL) &&\r
(Smbios30EntryPointStructure->TableMaximumSize + StructureSize > SMBIOS_3_0_TABLE_MAX_LENGTH)) {\r
- DEBUG ((EFI_D_INFO, "SmbiosAdd: Total length exceeds max 64-bit table length with type = %d size = 0x%x\n", Record->Type, StructureSize));\r
+ DEBUG ((DEBUG_INFO, "SmbiosAdd: Total length exceeds max 64-bit table length with type = %d size = 0x%x\n", Record->Type, StructureSize));\r
} else {\r
- DEBUG ((EFI_D_INFO, "SmbiosAdd: Smbios type %d with size 0x%x is added to 64-bit table\n", Record->Type, StructureSize));\r
+ DEBUG ((DEBUG_INFO, "SmbiosAdd: Smbios type %d with size 0x%x is added to 64-bit table\n", Record->Type, StructureSize));\r
Smbios64BitTable = TRUE;\r
}\r
}\r
// in the Structure Table Length field of the SMBIOS Structure Table Entry Point,\r
// which is a WORD field limited to 65,535 bytes.\r
//\r
- DEBUG ((EFI_D_INFO, "SmbiosUpdateString: Total length exceeds max 32-bit table length\n"));\r
+ DEBUG ((DEBUG_INFO, "SmbiosUpdateString: Total length exceeds max 32-bit table length\n"));\r
} else {\r
- DEBUG ((EFI_D_INFO, "SmbiosUpdateString: New smbios record add to 32-bit table\n"));\r
+ DEBUG ((DEBUG_INFO, "SmbiosUpdateString: New smbios record add to 32-bit table\n"));\r
SmbiosEntry->Smbios32BitTable = TRUE;\r
}\r
}\r
//\r
if ((Smbios30EntryPointStructure != NULL) &&\r
(Smbios30EntryPointStructure->TableMaximumSize + InputStrLen - TargetStrLen > SMBIOS_3_0_TABLE_MAX_LENGTH)) {\r
- DEBUG ((EFI_D_INFO, "SmbiosUpdateString: Total length exceeds max 64-bit table length\n"));\r
+ DEBUG ((DEBUG_INFO, "SmbiosUpdateString: Total length exceeds max 64-bit table length\n"));\r
} else {\r
- DEBUG ((EFI_D_INFO, "SmbiosUpdateString: New smbios record add to 64-bit table\n"));\r
+ DEBUG ((DEBUG_INFO, "SmbiosUpdateString: New smbios record add to 64-bit table\n"));\r
SmbiosEntry->Smbios64BitTable = TRUE;\r
}\r
}\r
// configuration table without depending on PI SMBIOS protocol.\r
//\r
if (SmbiosEntry->Smbios32BitTable) {\r
- DEBUG ((EFI_D_INFO, "SmbiosRemove: remove from 32-bit table\n"));\r
+ DEBUG ((DEBUG_INFO, "SmbiosRemove: remove from 32-bit table\n"));\r
}\r
if (SmbiosEntry->Smbios64BitTable) {\r
- DEBUG ((EFI_D_INFO, "SmbiosRemove: remove from 64-bit table\n"));\r
+ DEBUG ((DEBUG_INFO, "SmbiosRemove: remove from 64-bit table\n"));\r
}\r
//\r
// Update the whole SMBIOS table again based on which table the removed SMBIOS record is in.\r
// It should be done only once.\r
// Allocate memory (below 4GB).\r
//\r
- DEBUG ((EFI_D_INFO, "SmbiosCreateTable: Initialize 32-bit entry point structure\n"));\r
+ DEBUG ((DEBUG_INFO, "SmbiosCreateTable: Initialize 32-bit entry point structure\n"));\r
EntryPointStructureData.MajorVersion = mPrivateData.Smbios.MajorVersion;\r
EntryPointStructureData.MinorVersion = mPrivateData.Smbios.MinorVersion;\r
EntryPointStructureData.SmbiosBcdRevision = (UINT8) ((PcdGet16 (PcdSmbiosVersion) >> 4) & 0xf0) | (UINT8) (PcdGet16 (PcdSmbiosVersion) & 0x0f);\r
&PhysicalAddress\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SmbiosCreateTable () could not allocate EntryPointStructure < 4GB\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmbiosCreateTable () could not allocate EntryPointStructure < 4GB\n"));\r
Status = gBS->AllocatePages (\r
AllocateAnyPages,\r
EfiRuntimeServicesData,\r
// If new SMBIOS table size exceeds the previous allocated page,\r
// it is time to re-allocate memory (below 4GB).\r
//\r
- DEBUG ((EFI_D_INFO, "%a() re-allocate SMBIOS 32-bit table\n",\r
+ DEBUG ((DEBUG_INFO, "%a() re-allocate SMBIOS 32-bit table\n",\r
__FUNCTION__));\r
if (EntryPointStructure->TableAddress != 0) {\r
//\r
&PhysicalAddress\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SmbiosCreateTable() could not allocate SMBIOS table < 4GB\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmbiosCreateTable() could not allocate SMBIOS table < 4GB\n"));\r
EntryPointStructure->TableAddress = 0;\r
return EFI_OUT_OF_RESOURCES;\r
} else {\r
// It should be done only once.\r
// Allocate memory at any address.\r
//\r
- DEBUG ((EFI_D_INFO, "SmbiosCreateTable: Initialize 64-bit entry point structure\n"));\r
+ DEBUG ((DEBUG_INFO, "SmbiosCreateTable: Initialize 64-bit entry point structure\n"));\r
Smbios30EntryPointStructureData.MajorVersion = mPrivateData.Smbios.MajorVersion;\r
Smbios30EntryPointStructureData.MinorVersion = mPrivateData.Smbios.MinorVersion;\r
Smbios30EntryPointStructureData.DocRev = PcdGet8 (PcdSmbiosDocRev);\r
&PhysicalAddress\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SmbiosCreate64BitTable() could not allocate Smbios30EntryPointStructure\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmbiosCreate64BitTable() could not allocate Smbios30EntryPointStructure\n"));\r
return EFI_OUT_OF_RESOURCES;\r
}\r
\r
// If new SMBIOS table size exceeds the previous allocated page,\r
// it is time to re-allocate memory at anywhere.\r
//\r
- DEBUG ((EFI_D_INFO, "%a() re-allocate SMBIOS 64-bit table\n",\r
+ DEBUG ((DEBUG_INFO, "%a() re-allocate SMBIOS 64-bit table\n",\r
__FUNCTION__));\r
if (Smbios30EntryPointStructure->TableAddress != 0) {\r
//\r
&PhysicalAddress\r
);\r
if (EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_ERROR, "SmbiosCreateTable() could not allocate SMBIOS 64-bit table\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmbiosCreateTable() could not allocate SMBIOS 64-bit table\n"));\r
Smbios30EntryPointStructure->TableAddress = 0;\r
return EFI_OUT_OF_RESOURCES;\r
} else {\r
{\r
UINTN Index;\r
for (Index = 0; Index < Size; Index++) {\r
- DEBUG ((EFI_D_VERBOSE, "%02x", (UINTN)Data[Index]));\r
+ DEBUG ((DEBUG_VERBOSE, "%02x", (UINTN)Data[Index]));\r
}\r
}\r
\r
Count = Size / COLUME_SIZE;\r
Left = Size % COLUME_SIZE;\r
for (Index = 0; Index < Count; Index++) {\r
- DEBUG ((EFI_D_VERBOSE, "%04x: ", Index * COLUME_SIZE));\r
+ DEBUG ((DEBUG_VERBOSE, "%04x: ", Index * COLUME_SIZE));\r
InternalDumpData (Data + Index * COLUME_SIZE, COLUME_SIZE);\r
- DEBUG ((EFI_D_VERBOSE, "\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "\n"));\r
}\r
\r
if (Left != 0) {\r
- DEBUG ((EFI_D_VERBOSE, "%04x: ", Index * COLUME_SIZE));\r
+ DEBUG ((DEBUG_VERBOSE, "%04x: ", Index * COLUME_SIZE));\r
InternalDumpData (Data + Index * COLUME_SIZE, Left);\r
- DEBUG ((EFI_D_VERBOSE, "\n"));\r
+ DEBUG ((DEBUG_VERBOSE, "\n"));\r
}\r
}\r
\r
CHAR8 *String;\r
UINTN StringLen;\r
\r
- DEBUG ((EFI_D_INFO, "Smbios Table (Type - %d):\n", ((SMBIOS_STRUCTURE *)TableEntry)->Type));\r
+ DEBUG ((DEBUG_INFO, "Smbios Table (Type - %d):\n", ((SMBIOS_STRUCTURE *)TableEntry)->Type));\r
DEBUG_CODE (InternalDumpHex (TableEntry, TableEntrySize););\r
\r
//\r
// set ' ' for string field\r
String = GetSmbiosStringById (TableEntry, StringId, &StringLen);\r
ASSERT (String != NULL);\r
- //DEBUG ((EFI_D_INFO,"StrId(0x%x)-%a(%d)\n", StringId, String, StringLen));\r
+ //DEBUG ((DEBUG_INFO,"StrId(0x%x)-%a(%d)\n", StringId, String, StringLen));\r
SetMem (String, StringLen, ' ');\r
}\r
}\r
}\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Filter Smbios Table (Type - %d):\n", ((SMBIOS_STRUCTURE *)TableEntry)->Type));\r
+ DEBUG ((DEBUG_INFO, "Filter Smbios Table (Type - %d):\n", ((SMBIOS_STRUCTURE *)TableEntry)->Type));\r
DEBUG_CODE (InternalDumpHex (TableEntry, TableEntrySize););\r
}\r
\r
(VOID **) &Smbios3Table\r
);\r
if (!EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "Smbios3Table:\n"));\r
- DEBUG ((EFI_D_INFO, " AnchorString - '%c%c%c%c%c'\n",\r
+ DEBUG ((DEBUG_INFO, "Smbios3Table:\n"));\r
+ DEBUG ((DEBUG_INFO, " AnchorString - '%c%c%c%c%c'\n",\r
Smbios3Table->AnchorString[0],\r
Smbios3Table->AnchorString[1],\r
Smbios3Table->AnchorString[2],\r
Smbios3Table->AnchorString[3],\r
Smbios3Table->AnchorString[4]\r
));\r
- DEBUG ((EFI_D_INFO, " EntryPointStructureChecksum - 0x%02x\n", Smbios3Table->EntryPointStructureChecksum));\r
- DEBUG ((EFI_D_INFO, " EntryPointLength - 0x%02x\n", Smbios3Table->EntryPointLength));\r
- DEBUG ((EFI_D_INFO, " MajorVersion - 0x%02x\n", Smbios3Table->MajorVersion));\r
- DEBUG ((EFI_D_INFO, " MinorVersion - 0x%02x\n", Smbios3Table->MinorVersion));\r
- DEBUG ((EFI_D_INFO, " DocRev - 0x%02x\n", Smbios3Table->DocRev));\r
- DEBUG ((EFI_D_INFO, " EntryPointRevision - 0x%02x\n", Smbios3Table->EntryPointRevision));\r
- DEBUG ((EFI_D_INFO, " TableMaximumSize - 0x%08x\n", Smbios3Table->TableMaximumSize));\r
- DEBUG ((EFI_D_INFO, " TableAddress - 0x%016lx\n", Smbios3Table->TableAddress));\r
+ DEBUG ((DEBUG_INFO, " EntryPointStructureChecksum - 0x%02x\n", Smbios3Table->EntryPointStructureChecksum));\r
+ DEBUG ((DEBUG_INFO, " EntryPointLength - 0x%02x\n", Smbios3Table->EntryPointLength));\r
+ DEBUG ((DEBUG_INFO, " MajorVersion - 0x%02x\n", Smbios3Table->MajorVersion));\r
+ DEBUG ((DEBUG_INFO, " MinorVersion - 0x%02x\n", Smbios3Table->MinorVersion));\r
+ DEBUG ((DEBUG_INFO, " DocRev - 0x%02x\n", Smbios3Table->DocRev));\r
+ DEBUG ((DEBUG_INFO, " EntryPointRevision - 0x%02x\n", Smbios3Table->EntryPointRevision));\r
+ DEBUG ((DEBUG_INFO, " TableMaximumSize - 0x%08x\n", Smbios3Table->TableMaximumSize));\r
+ DEBUG ((DEBUG_INFO, " TableAddress - 0x%016lx\n", Smbios3Table->TableAddress));\r
}\r
}\r
\r
(VOID **) &SmbiosTable\r
);\r
if (!EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "SmbiosTable:\n"));\r
- DEBUG ((EFI_D_INFO, " AnchorString - '%c%c%c%c'\n",\r
+ DEBUG ((DEBUG_INFO, "SmbiosTable:\n"));\r
+ DEBUG ((DEBUG_INFO, " AnchorString - '%c%c%c%c'\n",\r
SmbiosTable->AnchorString[0],\r
SmbiosTable->AnchorString[1],\r
SmbiosTable->AnchorString[2],\r
SmbiosTable->AnchorString[3]\r
));\r
- DEBUG ((EFI_D_INFO, " EntryPointStructureChecksum - 0x%02x\n", SmbiosTable->EntryPointStructureChecksum));\r
- DEBUG ((EFI_D_INFO, " EntryPointLength - 0x%02x\n", SmbiosTable->EntryPointLength));\r
- DEBUG ((EFI_D_INFO, " MajorVersion - 0x%02x\n", SmbiosTable->MajorVersion));\r
- DEBUG ((EFI_D_INFO, " MinorVersion - 0x%02x\n", SmbiosTable->MinorVersion));\r
- DEBUG ((EFI_D_INFO, " MaxStructureSize - 0x%08x\n", SmbiosTable->MaxStructureSize));\r
- DEBUG ((EFI_D_INFO, " EntryPointRevision - 0x%02x\n", SmbiosTable->EntryPointRevision));\r
- DEBUG ((EFI_D_INFO, " FormattedArea - '%c%c%c%c%c'\n",\r
+ DEBUG ((DEBUG_INFO, " EntryPointStructureChecksum - 0x%02x\n", SmbiosTable->EntryPointStructureChecksum));\r
+ DEBUG ((DEBUG_INFO, " EntryPointLength - 0x%02x\n", SmbiosTable->EntryPointLength));\r
+ DEBUG ((DEBUG_INFO, " MajorVersion - 0x%02x\n", SmbiosTable->MajorVersion));\r
+ DEBUG ((DEBUG_INFO, " MinorVersion - 0x%02x\n", SmbiosTable->MinorVersion));\r
+ DEBUG ((DEBUG_INFO, " MaxStructureSize - 0x%08x\n", SmbiosTable->MaxStructureSize));\r
+ DEBUG ((DEBUG_INFO, " EntryPointRevision - 0x%02x\n", SmbiosTable->EntryPointRevision));\r
+ DEBUG ((DEBUG_INFO, " FormattedArea - '%c%c%c%c%c'\n",\r
SmbiosTable->FormattedArea[0],\r
SmbiosTable->FormattedArea[1],\r
SmbiosTable->FormattedArea[2],\r
SmbiosTable->FormattedArea[3],\r
SmbiosTable->FormattedArea[4]\r
));\r
- DEBUG ((EFI_D_INFO, " IntermediateAnchorString - '%c%c%c%c%c'\n",\r
+ DEBUG ((DEBUG_INFO, " IntermediateAnchorString - '%c%c%c%c%c'\n",\r
SmbiosTable->IntermediateAnchorString[0],\r
SmbiosTable->IntermediateAnchorString[1],\r
SmbiosTable->IntermediateAnchorString[2],\r
SmbiosTable->IntermediateAnchorString[3],\r
SmbiosTable->IntermediateAnchorString[4]\r
));\r
- DEBUG ((EFI_D_INFO, " IntermediateChecksum - 0x%02x\n", SmbiosTable->IntermediateChecksum));\r
- DEBUG ((EFI_D_INFO, " TableLength - 0x%04x\n", SmbiosTable->TableLength));\r
- DEBUG ((EFI_D_INFO, " TableAddress - 0x%08x\n", SmbiosTable->TableAddress));\r
- DEBUG ((EFI_D_INFO, " NumberOfSmbiosStructures - 0x%04x\n", SmbiosTable->NumberOfSmbiosStructures));\r
- DEBUG ((EFI_D_INFO, " SmbiosBcdRevision - 0x%02x\n", SmbiosTable->SmbiosBcdRevision));\r
+ DEBUG ((DEBUG_INFO, " IntermediateChecksum - 0x%02x\n", SmbiosTable->IntermediateChecksum));\r
+ DEBUG ((DEBUG_INFO, " TableLength - 0x%04x\n", SmbiosTable->TableLength));\r
+ DEBUG ((DEBUG_INFO, " TableAddress - 0x%08x\n", SmbiosTable->TableAddress));\r
+ DEBUG ((DEBUG_INFO, " NumberOfSmbiosStructures - 0x%04x\n", SmbiosTable->NumberOfSmbiosStructures));\r
+ DEBUG ((DEBUG_INFO, " SmbiosBcdRevision - 0x%02x\n", SmbiosTable->SmbiosBcdRevision));\r
}\r
}\r
\r
Entry->NumberOfPages = DEFAULT_COMMON_PI_SMM_COMMUNIATION_REGION_PAGES;\r
Entry->Attribute = 0;\r
\r
- DEBUG ((EFI_D_INFO, "PiSmmCommunicationRegionTable:(0x%x)\n", PiSmmCommunicationRegionTable));\r
- DEBUG ((EFI_D_INFO, " Version - 0x%x\n", PiSmmCommunicationRegionTable->Version));\r
- DEBUG ((EFI_D_INFO, " NumberOfEntries - 0x%x\n", PiSmmCommunicationRegionTable->NumberOfEntries));\r
- DEBUG ((EFI_D_INFO, " DescriptorSize - 0x%x\n", PiSmmCommunicationRegionTable->DescriptorSize));\r
- DEBUG ((EFI_D_INFO, "Entry:(0x%x)\n", Entry));\r
- DEBUG ((EFI_D_INFO, " Type - 0x%x\n", Entry->Type));\r
- DEBUG ((EFI_D_INFO, " PhysicalStart - 0x%lx\n", Entry->PhysicalStart));\r
- DEBUG ((EFI_D_INFO, " VirtualStart - 0x%lx\n", Entry->VirtualStart));\r
- DEBUG ((EFI_D_INFO, " NumberOfPages - 0x%lx\n", Entry->NumberOfPages));\r
- DEBUG ((EFI_D_INFO, " Attribute - 0x%lx\n", Entry->Attribute));\r
+ DEBUG ((DEBUG_INFO, "PiSmmCommunicationRegionTable:(0x%x)\n", PiSmmCommunicationRegionTable));\r
+ DEBUG ((DEBUG_INFO, " Version - 0x%x\n", PiSmmCommunicationRegionTable->Version));\r
+ DEBUG ((DEBUG_INFO, " NumberOfEntries - 0x%x\n", PiSmmCommunicationRegionTable->NumberOfEntries));\r
+ DEBUG ((DEBUG_INFO, " DescriptorSize - 0x%x\n", PiSmmCommunicationRegionTable->DescriptorSize));\r
+ DEBUG ((DEBUG_INFO, "Entry:(0x%x)\n", Entry));\r
+ DEBUG ((DEBUG_INFO, " Type - 0x%x\n", Entry->Type));\r
+ DEBUG ((DEBUG_INFO, " PhysicalStart - 0x%lx\n", Entry->PhysicalStart));\r
+ DEBUG ((DEBUG_INFO, " VirtualStart - 0x%lx\n", Entry->VirtualStart));\r
+ DEBUG ((DEBUG_INFO, " NumberOfPages - 0x%lx\n", Entry->NumberOfPages));\r
+ DEBUG ((DEBUG_INFO, " Attribute - 0x%lx\n", Entry->Attribute));\r
\r
//\r
// Publish this table, so that other driver can use the buffer.\r
mTimestampProperties.EndValue = mTimerLibStartValue - mTimerLibEndValue;\r
}\r
\r
- DEBUG ((EFI_D_INFO, "TimerFrequency:0x%lx, TimerLibStartTime:0x%lx, TimerLibEndtime:0x%lx\n", mTimestampProperties.Frequency, mTimerLibStartValue, mTimerLibEndValue));\r
+ DEBUG ((DEBUG_INFO, "TimerFrequency:0x%lx, TimerLibStartTime:0x%lx, TimerLibEndtime:0x%lx\n", mTimestampProperties.Frequency, mTimerLibStartValue, mTimerLibEndValue));\r
\r
//\r
// Install the Timestamp Protocol onto a new handle\r
// Let FvHeader point to spare block.\r
//\r
FvHeader = (EFI_FIRMWARE_VOLUME_HEADER *) (UINTN) FtwLastWriteData->SpareAddress;\r
- DEBUG ((EFI_D_INFO, "PeiVariable: NV storage is backed up in spare block: 0x%x\n", (UINTN) FtwLastWriteData->SpareAddress));\r
+ DEBUG ((DEBUG_INFO, "PeiVariable: NV storage is backed up in spare block: 0x%x\n", (UINTN) FtwLastWriteData->SpareAddress));\r
} else if ((FtwLastWriteData->TargetAddress > NvStorageBase) && (FtwLastWriteData->TargetAddress < (NvStorageBase + NvStorageSize))) {\r
StoreInfo->FtwLastWriteData = FtwLastWriteData;\r
//\r
// Flash NV storage from the offset is backed up in spare block.\r
//\r
BackUpOffset = (UINT32) (FtwLastWriteData->TargetAddress - NvStorageBase);\r
- DEBUG ((EFI_D_INFO, "PeiVariable: High partial NV storage from offset: %x is backed up in spare block: 0x%x\n", BackUpOffset, (UINTN) FtwLastWriteData->SpareAddress));\r
+ DEBUG ((DEBUG_INFO, "PeiVariable: High partial NV storage from offset: %x is backed up in spare block: 0x%x\n", BackUpOffset, (UINTN) FtwLastWriteData->SpareAddress));\r
//\r
// At least one block data in flash NV storage is still valid, so still leave FvHeader point to NV storage base.\r
//\r
// Check if the Firmware Volume is not corrupted\r
//\r
if ((FvHeader->Signature != EFI_FVH_SIGNATURE) || (!CompareGuid (&gEfiSystemNvDataFvGuid, &FvHeader->FileSystemGuid))) {\r
- DEBUG ((EFI_D_ERROR, "Firmware Volume for Variable Store is corrupted\n"));\r
+ DEBUG ((DEBUG_ERROR, "Firmware Volume for Variable Store is corrupted\n"));\r
break;\r
}\r
\r
);\r
}\r
\r
- DEBUG ((EFI_D_INFO, "VariableDxe: MeasureVariable (Pcr - %x, EventType - %x, ", (UINTN)7, (UINTN)EV_EFI_VARIABLE_DRIVER_CONFIG));\r
- DEBUG ((EFI_D_INFO, "VariableName - %s, VendorGuid - %g)\n", VarName, VendorGuid));\r
+ DEBUG ((DEBUG_INFO, "VariableDxe: MeasureVariable (Pcr - %x, EventType - %x, ", (UINTN)7, (UINTN)EV_EFI_VARIABLE_DRIVER_CONFIG));\r
+ DEBUG ((DEBUG_INFO, "VariableName - %s, VendorGuid - %g)\n", VarName, VendorGuid));\r
\r
Status = TpmMeasureAndLogData (\r
7,\r
VariableData,\r
VariableDataSize\r
);\r
- DEBUG ((EFI_D_INFO, "MeasureBootPolicyVariable - %r\n", Status));\r
+ DEBUG ((DEBUG_INFO, "MeasureBootPolicyVariable - %r\n", Status));\r
\r
if (VariableData != NULL) {\r
FreePool (VariableData);\r
VAR_ERROR_FLAG TempFlag;\r
\r
DEBUG_CODE (\r
- DEBUG ((EFI_D_ERROR, "RecordVarErrorFlag (0x%02x) %s:%g - 0x%08x - 0x%x\n", Flag, VariableName, VendorGuid, Attributes, VariableSize));\r
+ DEBUG ((DEBUG_ERROR, "RecordVarErrorFlag (0x%02x) %s:%g - 0x%08x - 0x%x\n", Flag, VariableName, VendorGuid, Attributes, VariableSize));\r
if (Flag == VAR_ERROR_FLAG_SYSTEM_ERROR) {\r
if (AtRuntime ()) {\r
- DEBUG ((EFI_D_ERROR, "CommonRuntimeVariableSpace = 0x%x - CommonVariableTotalSize = 0x%x\n", mVariableModuleGlobal->CommonRuntimeVariableSpace, mVariableModuleGlobal->CommonVariableTotalSize));\r
+ DEBUG ((DEBUG_ERROR, "CommonRuntimeVariableSpace = 0x%x - CommonVariableTotalSize = 0x%x\n", mVariableModuleGlobal->CommonRuntimeVariableSpace, mVariableModuleGlobal->CommonVariableTotalSize));\r
} else {\r
- DEBUG ((EFI_D_ERROR, "CommonVariableSpace = 0x%x - CommonVariableTotalSize = 0x%x\n", mVariableModuleGlobal->CommonVariableSpace, mVariableModuleGlobal->CommonVariableTotalSize));\r
+ DEBUG ((DEBUG_ERROR, "CommonVariableSpace = 0x%x - CommonVariableTotalSize = 0x%x\n", mVariableModuleGlobal->CommonVariableSpace, mVariableModuleGlobal->CommonVariableTotalSize));\r
}\r
} else {\r
- DEBUG ((EFI_D_ERROR, "CommonMaxUserVariableSpace = 0x%x - CommonUserVariableTotalSize = 0x%x\n", mVariableModuleGlobal->CommonMaxUserVariableSpace, mVariableModuleGlobal->CommonUserVariableTotalSize));\r
+ DEBUG ((DEBUG_ERROR, "CommonMaxUserVariableSpace = 0x%x - CommonUserVariableTotalSize = 0x%x\n", mVariableModuleGlobal->CommonMaxUserVariableSpace, mVariableModuleGlobal->CommonUserVariableTotalSize));\r
}\r
);\r
\r
}\r
\r
Flag = mCurrentBootVarErrFlag;\r
- DEBUG ((EFI_D_INFO, "Initialize variable error flag (%02x)\n", Flag));\r
+ DEBUG ((DEBUG_INFO, "Initialize variable error flag (%02x)\n", Flag));\r
\r
Status = FindVariable (\r
VAR_ERROR_FLAG_NAME,\r
ISO_639_2_ENTRY_SIZE + 1, Attributes, 0, 0, &Variable, NULL);\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Variable Driver Auto Update PlatformLang, PlatformLang:%a, Lang:%a Status: %r\n", BestPlatformLang, BestLang, Status));\r
+ DEBUG ((DEBUG_INFO, "Variable Driver Auto Update PlatformLang, PlatformLang:%a, Lang:%a Status: %r\n", BestPlatformLang, BestLang, Status));\r
}\r
}\r
\r
AsciiStrSize (BestPlatformLang), Attributes, 0, 0, &Variable, NULL);\r
}\r
\r
- DEBUG ((EFI_D_INFO, "Variable Driver Auto Update Lang, Lang:%a, PlatformLang:%a Status: %r\n", BestLang, BestPlatformLang, Status));\r
+ DEBUG ((DEBUG_INFO, "Variable Driver Auto Update Lang, Lang:%a, PlatformLang:%a Status: %r\n", BestLang, BestPlatformLang, Status));\r
}\r
}\r
}\r
//\r
// Trying to update NV variable prior to the installation of EFI_VARIABLE_WRITE_ARCH_PROTOCOL\r
//\r
- DEBUG ((EFI_D_ERROR, "Update NV variable before EFI_VARIABLE_WRITE_ARCH_PROTOCOL ready - %r\n", EFI_NOT_AVAILABLE_YET));\r
+ DEBUG ((DEBUG_ERROR, "Update NV variable before EFI_VARIABLE_WRITE_ARCH_PROTOCOL ready - %r\n", EFI_NOT_AVAILABLE_YET));\r
return EFI_NOT_AVAILABLE_YET;\r
} else if ((Attributes & VARIABLE_ATTRIBUTE_AT_AW) != 0) {\r
//\r
// Trying to update volatile authenticated variable prior to the installation of EFI_VARIABLE_WRITE_ARCH_PROTOCOL\r
// The authenticated variable perhaps is not initialized, just return here.\r
//\r
- DEBUG ((EFI_D_ERROR, "Update AUTH variable before EFI_VARIABLE_WRITE_ARCH_PROTOCOL ready - %r\n", EFI_NOT_AVAILABLE_YET));\r
+ DEBUG ((DEBUG_ERROR, "Update AUTH variable before EFI_VARIABLE_WRITE_ARCH_PROTOCOL ready - %r\n", EFI_NOT_AVAILABLE_YET));\r
return EFI_NOT_AVAILABLE_YET;\r
}\r
}\r
// 2. The only attribute differing is EFI_VARIABLE_APPEND_WRITE\r
//\r
Status = EFI_INVALID_PARAMETER;\r
- DEBUG ((EFI_D_INFO, "[Variable]: Rewritten a preexisting variable(0x%08x) with different attributes(0x%08x) - %g:%s\n", Variable.CurrPtr->Attributes, Attributes, VendorGuid, VariableName));\r
+ DEBUG ((DEBUG_INFO, "[Variable]: Rewritten a preexisting variable(0x%08x) with different attributes(0x%08x) - %g:%s\n", Variable.CurrPtr->Attributes, Attributes, VendorGuid, VariableName));\r
goto Done;\r
}\r
}\r
//\r
// All HOB variables have been flushed in flash.\r
//\r
- DEBUG ((EFI_D_INFO, "Variable driver: all HOB variables have been flushed in flash.\n"));\r
+ DEBUG ((DEBUG_INFO, "Variable driver: all HOB variables have been flushed in flash.\n"));\r
if (mVariableModuleGlobal->VariableGlobal.VariableRuntimeCacheContext.HobFlushComplete != NULL) {\r
*(mVariableModuleGlobal->VariableGlobal.VariableRuntimeCacheContext.HobFlushComplete) = TRUE;\r
}\r
GetVariableHeaderSize (mVariableModuleGlobal->VariableGlobal.AuthFormat);\r
Status = AuthVariableLibInitialize (&mAuthContextIn, &mAuthContextOut);\r
if (!EFI_ERROR (Status)) {\r
- DEBUG ((EFI_D_INFO, "Variable driver will work with auth variable support!\n"));\r
+ DEBUG ((DEBUG_INFO, "Variable driver will work with auth variable support!\n"));\r
mVariableModuleGlobal->VariableGlobal.AuthSupport = TRUE;\r
if (mAuthContextOut.AuthVarEntry != NULL) {\r
for (Index = 0; Index < mAuthContextOut.AuthVarEntryCount; Index++) {\r
}\r
}\r
} else if (Status == EFI_UNSUPPORTED) {\r
- DEBUG ((EFI_D_INFO, "NOTICE - AuthVariableLibInitialize() returns %r!\n", Status));\r
- DEBUG ((EFI_D_INFO, "Variable driver will continue to work without auth variable support!\n"));\r
+ DEBUG ((DEBUG_INFO, "NOTICE - AuthVariableLibInitialize() returns %r!\n", Status));\r
+ DEBUG ((DEBUG_INFO, "Variable driver will continue to work without auth variable support!\n"));\r
mVariableModuleGlobal->VariableGlobal.AuthSupport = FALSE;\r
Status = EFI_SUCCESS;\r
}\r
return EFI_OUT_OF_RESOURCES;\r
}\r
} else {\r
- DEBUG ((EFI_D_ERROR, "HOB Variable Store header is corrupted!\n"));\r
+ DEBUG ((DEBUG_ERROR, "HOB Variable Store header is corrupted!\n"));\r
}\r
}\r
\r
// has been initialized in InitNonVolatileVariableStore().\r
//\r
if (mVariableModuleGlobal->VariableGlobal.AuthFormat) {\r
- DEBUG ((EFI_D_INFO, "Variable driver will work with auth variable format!\n"));\r
+ DEBUG ((DEBUG_INFO, "Variable driver will work with auth variable format!\n"));\r
//\r
// Set AuthSupport to FALSE first, VariableWriteServiceInitialize() will initialize it.\r
//\r
mVariableModuleGlobal->VariableGlobal.AuthSupport = FALSE;\r
VariableGuid = &gEfiAuthenticatedVariableGuid;\r
} else {\r
- DEBUG ((EFI_D_INFO, "Variable driver will work without auth variable support!\n"));\r
+ DEBUG ((DEBUG_INFO, "Variable driver will work without auth variable support!\n"));\r
mVariableModuleGlobal->VariableGlobal.AuthSupport = FALSE;\r
VariableGuid = &gEfiVariableGuid;\r
}\r
\r
return Status;\r
}\r
-\r
{\r
EFI_STATUS Status;\r
\r
- DEBUG ((EFI_D_INFO, "[Variable]END_OF_DXE is signaled\n"));\r
+ DEBUG ((DEBUG_INFO, "[Variable]END_OF_DXE is signaled\n"));\r
MorLockInitAtEndOfDxe ();\r
Status = LockVariablePolicy ();\r
ASSERT_EFI_ERROR (Status);\r
\r
return EFI_SUCCESS;\r
}\r
-\r
TempCommBufferSize = *CommBufferSize;\r
\r
if (TempCommBufferSize < SMM_VARIABLE_COMMUNICATE_HEADER_SIZE) {\r
- DEBUG ((EFI_D_ERROR, "SmmVariableHandler: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmVariableHandler: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
CommBufferPayloadSize = TempCommBufferSize - SMM_VARIABLE_COMMUNICATE_HEADER_SIZE;\r
if (CommBufferPayloadSize > mVariableBufferPayloadSize) {\r
- DEBUG ((EFI_D_ERROR, "SmmVariableHandler: SMM communication buffer payload size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmVariableHandler: SMM communication buffer payload size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
\r
if (!VariableSmmIsBufferOutsideSmmValid ((UINTN)CommBuffer, TempCommBufferSize)) {\r
- DEBUG ((EFI_D_ERROR, "SmmVariableHandler: SMM communication buffer in SMRAM or overflow!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SmmVariableHandler: SMM communication buffer in SMRAM or overflow!\n"));\r
return EFI_SUCCESS;\r
}\r
\r
switch (SmmVariableFunctionHeader->Function) {\r
case SMM_VARIABLE_FUNCTION_GET_VARIABLE:\r
if (CommBufferPayloadSize < OFFSET_OF(SMM_VARIABLE_COMMUNICATE_ACCESS_VARIABLE, Name)) {\r
- DEBUG ((EFI_D_ERROR, "GetVariable: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "GetVariable: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
//\r
// SMRAM range check already covered before\r
//\r
if (InfoSize > CommBufferPayloadSize) {\r
- DEBUG ((EFI_D_ERROR, "GetVariable: Data size exceed communication buffer size limit!\n"));\r
+ DEBUG ((DEBUG_ERROR, "GetVariable: Data size exceed communication buffer size limit!\n"));\r
Status = EFI_ACCESS_DENIED;\r
goto EXIT;\r
}\r
\r
case SMM_VARIABLE_FUNCTION_GET_NEXT_VARIABLE_NAME:\r
if (CommBufferPayloadSize < OFFSET_OF(SMM_VARIABLE_COMMUNICATE_GET_NEXT_VARIABLE_NAME, Name)) {\r
- DEBUG ((EFI_D_ERROR, "GetNextVariableName: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "GetNextVariableName: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
//\r
// SMRAM range check already covered before\r
//\r
if (InfoSize > CommBufferPayloadSize) {\r
- DEBUG ((EFI_D_ERROR, "GetNextVariableName: Data size exceed communication buffer size limit!\n"));\r
+ DEBUG ((DEBUG_ERROR, "GetNextVariableName: Data size exceed communication buffer size limit!\n"));\r
Status = EFI_ACCESS_DENIED;\r
goto EXIT;\r
}\r
\r
case SMM_VARIABLE_FUNCTION_SET_VARIABLE:\r
if (CommBufferPayloadSize < OFFSET_OF(SMM_VARIABLE_COMMUNICATE_ACCESS_VARIABLE, Name)) {\r
- DEBUG ((EFI_D_ERROR, "SetVariable: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SetVariable: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
//\r
// Data buffer should not contain SMM range\r
//\r
if (InfoSize > CommBufferPayloadSize) {\r
- DEBUG ((EFI_D_ERROR, "SetVariable: Data size exceed communication buffer size limit!\n"));\r
+ DEBUG ((DEBUG_ERROR, "SetVariable: Data size exceed communication buffer size limit!\n"));\r
Status = EFI_ACCESS_DENIED;\r
goto EXIT;\r
}\r
\r
case SMM_VARIABLE_FUNCTION_QUERY_VARIABLE_INFO:\r
if (CommBufferPayloadSize < sizeof (SMM_VARIABLE_COMMUNICATE_QUERY_VARIABLE_INFO)) {\r
- DEBUG ((EFI_D_ERROR, "QueryVariableInfo: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "QueryVariableInfo: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
QueryVariableInfo = (SMM_VARIABLE_COMMUNICATE_QUERY_VARIABLE_INFO *) SmmVariableFunctionHeader->Data;\r
\r
case SMM_VARIABLE_FUNCTION_GET_PAYLOAD_SIZE:\r
if (CommBufferPayloadSize < sizeof (SMM_VARIABLE_COMMUNICATE_GET_PAYLOAD_SIZE)) {\r
- DEBUG ((EFI_D_ERROR, "GetPayloadSize: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "GetPayloadSize: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
GetPayloadSize = (SMM_VARIABLE_COMMUNICATE_GET_PAYLOAD_SIZE *) SmmVariableFunctionHeader->Data;\r
break;\r
case SMM_VARIABLE_FUNCTION_VAR_CHECK_VARIABLE_PROPERTY_GET:\r
if (CommBufferPayloadSize < OFFSET_OF (SMM_VARIABLE_COMMUNICATE_VAR_CHECK_VARIABLE_PROPERTY, Name)) {\r
- DEBUG ((EFI_D_ERROR, "VarCheckVariablePropertyGet: SMM communication buffer size invalid!\n"));\r
+ DEBUG ((DEBUG_ERROR, "VarCheckVariablePropertyGet: SMM communication buffer size invalid!\n"));\r
return EFI_SUCCESS;\r
}\r
//\r
// SMRAM range check already covered before\r
//\r
if (InfoSize > CommBufferPayloadSize) {\r
- DEBUG ((EFI_D_ERROR, "VarCheckVariablePropertyGet: Data size exceed communication buffer size limit!\n"));\r
+ DEBUG ((DEBUG_ERROR, "VarCheckVariablePropertyGet: Data size exceed communication buffer size limit!\n"));\r
Status = EFI_ACCESS_DENIED;\r
goto EXIT;\r
}\r
{\r
EFI_STATUS Status;\r
\r
- DEBUG ((EFI_D_INFO, "[Variable]SMM_END_OF_DXE is signaled\n"));\r
+ DEBUG ((DEBUG_INFO, "[Variable]SMM_END_OF_DXE is signaled\n"));\r
MorLockInitAtEndOfDxe ();\r
Status = LockVariablePolicy ();\r
ASSERT_EFI_ERROR (Status);\r
\r
return EFI_SUCCESS;\r
}\r
-\r
-\r
mWatchdogTimerNotifyFunction (mWatchdogTimerPeriod);\r
}\r
\r
- DEBUG ((EFI_D_ERROR, "Watchdog Timer resetting system\n"));\r
+ DEBUG ((DEBUG_ERROR, "Watchdog Timer resetting system\n"));\r
\r
//\r
// Reset the platform\r