summaryrefslogtreecommitdiffstats
path: root/MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ComponentName.c
diff options
context:
space:
mode:
Diffstat (limited to 'MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ComponentName.c')
-rw-r--r--MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ComponentName.c34
1 files changed, 16 insertions, 18 deletions
diff --git a/MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ComponentName.c b/MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ComponentName.c
index b193de9ed9..212d26bf88 100644
--- a/MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ComponentName.c
+++ b/MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ComponentName.c
@@ -6,7 +6,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
**/
-
#include "ScsiDisk.h"
//
@@ -21,16 +20,15 @@ GLOBAL_REMOVE_IF_UNREFERENCED EFI_COMPONENT_NAME_PROTOCOL gScsiDiskComponentNam
//
// EFI Component Name 2 Protocol
//
-GLOBAL_REMOVE_IF_UNREFERENCED EFI_COMPONENT_NAME2_PROTOCOL gScsiDiskComponentName2 = {
- (EFI_COMPONENT_NAME2_GET_DRIVER_NAME) ScsiDiskComponentNameGetDriverName,
- (EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME) ScsiDiskComponentNameGetControllerName,
+GLOBAL_REMOVE_IF_UNREFERENCED EFI_COMPONENT_NAME2_PROTOCOL gScsiDiskComponentName2 = {
+ (EFI_COMPONENT_NAME2_GET_DRIVER_NAME)ScsiDiskComponentNameGetDriverName,
+ (EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME)ScsiDiskComponentNameGetControllerName,
"en"
};
-
-GLOBAL_REMOVE_IF_UNREFERENCED EFI_UNICODE_STRING_TABLE mScsiDiskDriverNameTable[] = {
- { "eng;en", (CHAR16 *) L"Scsi Disk Driver" },
- { NULL , NULL }
+GLOBAL_REMOVE_IF_UNREFERENCED EFI_UNICODE_STRING_TABLE mScsiDiskDriverNameTable[] = {
+ { "eng;en", (CHAR16 *)L"Scsi Disk Driver" },
+ { NULL, NULL }
};
/**
@@ -160,16 +158,16 @@ ScsiDiskComponentNameGetDriverName (
EFI_STATUS
EFIAPI
ScsiDiskComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
)
{
- EFI_STATUS Status;
- SCSI_DISK_DEV *ScsiDiskDevice;
- EFI_BLOCK_IO_PROTOCOL *BlockIo;
+ EFI_STATUS Status;
+ SCSI_DISK_DEV *ScsiDiskDevice;
+ EFI_BLOCK_IO_PROTOCOL *BlockIo;
//
// This is a device driver, so ChildHandle must be NULL.
@@ -189,13 +187,14 @@ ScsiDiskComponentNameGetControllerName (
if (EFI_ERROR (Status)) {
return Status;
}
+
//
// Get the device context
//
Status = gBS->OpenProtocol (
ControllerHandle,
&gEfiBlockIoProtocolGuid,
- (VOID **) &BlockIo,
+ (VOID **)&BlockIo,
gScsiDiskDriverBinding.DriverBindingHandle,
ControllerHandle,
EFI_OPEN_PROTOCOL_GET_PROTOCOL
@@ -214,5 +213,4 @@ ScsiDiskComponentNameGetControllerName (
ControllerName,
(BOOLEAN)(This == &gScsiDiskComponentName)
);
-
}