summaryrefslogtreecommitdiff
path: root/EdkModulePkg/Universal/Debugger
diff options
context:
space:
mode:
authorlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2007-03-14 02:02:43 +0000
committerlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2007-03-14 02:02:43 +0000
commit2c3b5ec562c7b43a73424e1be25e2053d1edfe4f (patch)
tree01495edfd3c8cdd9ae39054443a47b198bc48e10 /EdkModulePkg/Universal/Debugger
parent9db9711c414fe3207ffae81b3c1627554c428308 (diff)
downloadedk2-platforms-2c3b5ec562c7b43a73424e1be25e2053d1edfe4f.tar.xz
Clean up the gBS sevice (CopyMem, SetMem, AllocatePool, FreePool) with the corresponding APIs defined in Mde library class for these modules.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2456 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'EdkModulePkg/Universal/Debugger')
-rw-r--r--EdkModulePkg/Universal/Debugger/Debugport/Dxe/DebugPort.c54
1 files changed, 27 insertions, 27 deletions
diff --git a/EdkModulePkg/Universal/Debugger/Debugport/Dxe/DebugPort.c b/EdkModulePkg/Universal/Debugger/Debugport/Dxe/DebugPort.c
index 88d19d4ad0..a15ec1cb30 100644
--- a/EdkModulePkg/Universal/Debugger/Debugport/Dxe/DebugPort.c
+++ b/EdkModulePkg/Universal/Debugger/Debugport/Dxe/DebugPort.c
@@ -67,7 +67,7 @@ Returns:
if (Status == EFI_BUFFER_TOO_SMALL) {
if (gDebugPortDevice->DebugPortVariable != NULL) {
- gBS->FreePool (gDebugPortDevice->DebugPortVariable);
+ FreePool (gDebugPortDevice->DebugPortVariable);
}
DebugPortDevice->DebugPortVariable = AllocatePool (DataSize);
@@ -85,31 +85,31 @@ Returns:
}
if (EfiIsDevicePathEnd (DevicePath)) {
- gBS->FreePool (gDebugPortDevice->DebugPortVariable);
+ FreePool (gDebugPortDevice->DebugPortVariable);
DebugPortDevice->DebugPortVariable = NULL;
} else {
- gBS->CopyMem (
- &DebugPortDevice->BaudRate,
- &((UART_DEVICE_PATH *) DevicePath)->BaudRate,
- sizeof (((UART_DEVICE_PATH *) DevicePath)->BaudRate)
- );
+ CopyMem (
+ &DebugPortDevice->BaudRate,
+ &((UART_DEVICE_PATH *) DevicePath)->BaudRate,
+ sizeof (((UART_DEVICE_PATH *) DevicePath)->BaudRate)
+ );
DebugPortDevice->ReceiveFifoDepth = DEBUGPORT_UART_DEFAULT_FIFO_DEPTH;
DebugPortDevice->Timeout = DEBUGPORT_UART_DEFAULT_TIMEOUT;
- gBS->CopyMem (
- &DebugPortDevice->Parity,
- &((UART_DEVICE_PATH *) DevicePath)->Parity,
- sizeof (((UART_DEVICE_PATH *) DevicePath)->Parity)
- );
- gBS->CopyMem (
- &DebugPortDevice->DataBits,
- &((UART_DEVICE_PATH *) DevicePath)->DataBits,
- sizeof (((UART_DEVICE_PATH *) DevicePath)->DataBits)
- );
- gBS->CopyMem (
- &DebugPortDevice->StopBits,
- &((UART_DEVICE_PATH *) DevicePath)->StopBits,
- sizeof (((UART_DEVICE_PATH *) DevicePath)->StopBits)
- );
+ CopyMem (
+ &DebugPortDevice->Parity,
+ &((UART_DEVICE_PATH *) DevicePath)->Parity,
+ sizeof (((UART_DEVICE_PATH *) DevicePath)->Parity)
+ );
+ CopyMem (
+ &DebugPortDevice->DataBits,
+ &((UART_DEVICE_PATH *) DevicePath)->DataBits,
+ sizeof (((UART_DEVICE_PATH *) DevicePath)->DataBits)
+ );
+ CopyMem (
+ &DebugPortDevice->StopBits,
+ &((UART_DEVICE_PATH *) DevicePath)->StopBits,
+ sizeof (((UART_DEVICE_PATH *) DevicePath)->StopBits)
+ );
}
}
}
@@ -273,7 +273,7 @@ Returns:
Status = EFI_UNSUPPORTED;
}
- gBS->FreePool (Dp1);
+ FreePool (Dp1);
if (EFI_ERROR (Status)) {
return Status;
}
@@ -389,7 +389,7 @@ Returns:
DebugPortDP.Header.Type = MESSAGING_DEVICE_PATH;
DebugPortDP.Header.SubType = MSG_VENDOR_DP;
SetDevicePathNodeLength (&(DebugPortDP.Header), sizeof (DebugPortDP));
- gBS->CopyMem (&DebugPortDP.Guid, &gEfiDebugPortDevicePathGuid, sizeof (EFI_GUID));
+ CopyMem (&DebugPortDP.Guid, &gEfiDebugPortDevicePathGuid, sizeof (EFI_GUID));
Dp1 = DevicePathFromHandle (ControllerHandle);
if (Dp1 == NULL) {
@@ -516,7 +516,7 @@ Returns:
ControllerHandle
);
- gBS->FreePool (gDebugPortDevice->DebugPortDevicePath);
+ FreePool (gDebugPortDevice->DebugPortDevicePath);
return EFI_SUCCESS;
} else {
@@ -803,10 +803,10 @@ Returns:
// Clean up allocations
//
if (gDebugPortDevice->DebugPortVariable != NULL) {
- gBS->FreePool (gDebugPortDevice->DebugPortVariable);
+ FreePool (gDebugPortDevice->DebugPortVariable);
}
- gBS->FreePool (gDebugPortDevice);
+ FreePool (gDebugPortDevice);
return EFI_SUCCESS;
}