19 EFI_EXT_SCSI_PASS_THRU_ATTRIBUTES_PHYSICAL | EFI_EXT_SCSI_PASS_THRU_ATTRIBUTES_LOGICAL | EFI_EXT_SCSI_PASS_THRU_ATTRIBUTES_NONBLOCKIO,
95UINT8 mUfsTargetId[TARGET_MAX_BYTES];
155 Private = UFS_PASS_THRU_PRIVATE_DATA_FROM_THIS (This);
157 if ((Packet ==
NULL) || (Packet->Cdb ==
NULL)) {
158 return EFI_INVALID_PARAMETER;
164 if ((Packet->CdbLength != 6) && (Packet->CdbLength != 10) &&
165 (Packet->CdbLength != 12) && (Packet->CdbLength != 16))
167 return EFI_INVALID_PARAMETER;
170 if ((Packet->SenseDataLength != 0) && (Packet->SenseData ==
NULL)) {
171 return EFI_INVALID_PARAMETER;
174 if ((This->Mode->IoAlign > 1) && !
ADDRESS_IS_ALIGNED (Packet->InDataBuffer, This->Mode->IoAlign)) {
175 return EFI_INVALID_PARAMETER;
178 if ((This->Mode->IoAlign > 1) && !
ADDRESS_IS_ALIGNED (Packet->OutDataBuffer, This->Mode->IoAlign)) {
179 return EFI_INVALID_PARAMETER;
182 if ((This->Mode->IoAlign > 1) && !
ADDRESS_IS_ALIGNED (Packet->SenseData, This->Mode->IoAlign)) {
183 return EFI_INVALID_PARAMETER;
189 SetMem (mUfsTargetId, TARGET_MAX_BYTES, 0x00);
190 if ((Target ==
NULL) || (
CompareMem (Target, mUfsTargetId, TARGET_MAX_BYTES) != 0)) {
191 return EFI_INVALID_PARAMETER;
199 if ((UINT8)Lun == UFS_WLUN_PREFIX) {
200 UfsLun = BIT7 | (((UINT8 *)&Lun)[1] & 0xFF);
201 }
else if ((UINT8)Lun == 0) {
202 UfsLun = ((UINT8 *)&Lun)[1] & 0xFF;
204 return EFI_INVALID_PARAMETER;
207 for (Index = 0; Index < UFS_MAX_LUNS; Index++) {
208 if ((Private->Luns.BitMask & (BIT0 << Index)) == 0) {
212 if (Private->Luns.Lun[Index] == UfsLun) {
217 if (Index == UFS_MAX_LUNS) {
218 return EFI_INVALID_PARAMETER;
256 IN OUT UINT8 **Target,
265 Private = UFS_PASS_THRU_PRIVATE_DATA_FROM_THIS (This);
267 if ((Target ==
NULL) || (Lun ==
NULL)) {
268 return EFI_INVALID_PARAMETER;
271 if (*Target ==
NULL) {
272 return EFI_INVALID_PARAMETER;
276 SetMem (mUfsTargetId, TARGET_MAX_BYTES, 0xFF);
277 if (
CompareMem (*Target, mUfsTargetId, TARGET_MAX_BYTES) == 0) {
281 SetMem (*Target, TARGET_MAX_BYTES, 0x00);
282 for (Index = 0; Index < UFS_MAX_LUNS; Index++) {
283 if ((Private->Luns.BitMask & (BIT0 << Index)) != 0) {
284 UfsLun = Private->Luns.Lun[Index];
289 if (Index != UFS_MAX_LUNS) {
291 if ((UfsLun & BIT7) == BIT7) {
292 ((UINT8 *)Lun)[0] = UFS_WLUN_PREFIX;
293 ((UINT8 *)Lun)[1] = UfsLun & ~BIT7;
295 ((UINT8 *)Lun)[1] = UfsLun;
300 return EFI_NOT_FOUND;
304 SetMem (mUfsTargetId, TARGET_MAX_BYTES, 0x00);
305 if (
CompareMem (*Target, mUfsTargetId, TARGET_MAX_BYTES) == 0) {
306 if (((UINT8 *)Lun)[0] == UFS_WLUN_PREFIX) {
307 UfsLun = BIT7 | (((UINT8 *)Lun)[1] & 0xFF);
308 }
else if (((UINT8 *)Lun)[0] == 0) {
309 UfsLun = ((UINT8 *)Lun)[1] & 0xFF;
311 return EFI_NOT_FOUND;
314 for (Index = 0; Index < UFS_MAX_LUNS; Index++) {
315 if ((Private->Luns.BitMask & (BIT0 << Index)) == 0) {
319 if (Private->Luns.Lun[Index] != UfsLun) {
323 for (Next = Index + 1; Next < UFS_MAX_LUNS; Next++) {
324 if ((Private->Luns.BitMask & (BIT0 << Next)) != 0) {
325 UfsLun = Private->Luns.Lun[Next];
330 if (Next == UFS_MAX_LUNS) {
331 return EFI_NOT_FOUND;
337 if (Index != UFS_MAX_LUNS) {
339 if ((UfsLun & BIT7) == BIT7) {
340 ((UINT8 *)Lun)[0] = UFS_WLUN_PREFIX;
341 ((UINT8 *)Lun)[1] = UfsLun & ~BIT7;
343 ((UINT8 *)Lun)[1] = UfsLun;
348 return EFI_NOT_FOUND;
352 return EFI_NOT_FOUND;
396 Private = UFS_PASS_THRU_PRIVATE_DATA_FROM_THIS (This);
401 SetMem (mUfsTargetId, TARGET_MAX_BYTES, 0x00);
402 if (
CompareMem (Target, mUfsTargetId, TARGET_MAX_BYTES) != 0) {
403 return EFI_INVALID_PARAMETER;
406 if ((UINT8)Lun == UFS_WLUN_PREFIX) {
407 UfsLun = BIT7 | (((UINT8 *)&Lun)[1] & 0xFF);
408 }
else if ((UINT8)Lun == 0) {
409 UfsLun = ((UINT8 *)&Lun)[1] & 0xFF;
411 return EFI_NOT_FOUND;
414 for (Index = 0; Index < UFS_MAX_LUNS; Index++) {
415 if ((Private->Luns.BitMask & (BIT0 << Index)) == 0) {
419 if (Private->Luns.Lun[Index] == UfsLun) {
424 if (Index == UFS_MAX_LUNS) {
425 return EFI_NOT_FOUND;
429 if (DevicePathNode ==
NULL) {
430 return EFI_OUT_OF_RESOURCES;
433 DevicePathNode->Ufs.
Pun = 0;
434 DevicePathNode->Ufs.
Lun = UfsLun;
475 Private = UFS_PASS_THRU_PRIVATE_DATA_FROM_THIS (This);
480 if ((DevicePath ==
NULL) || (Target ==
NULL) || (Lun ==
NULL)) {
481 return EFI_INVALID_PARAMETER;
484 if (*Target ==
NULL) {
485 return EFI_INVALID_PARAMETER;
494 return EFI_UNSUPPORTED;
499 Pun = (UINT8)DevicePathNode->Ufs.
Pun;
500 UfsLun = (UINT8)DevicePathNode->Ufs.
Lun;
503 return EFI_NOT_FOUND;
506 for (Index = 0; Index < UFS_MAX_LUNS; Index++) {
507 if ((Private->Luns.BitMask & (BIT0 << Index)) == 0) {
511 if (Private->Luns.Lun[Index] == UfsLun) {
516 if (Index == UFS_MAX_LUNS) {
517 return EFI_NOT_FOUND;
520 SetMem (*Target, TARGET_MAX_BYTES, 0x00);
522 if ((UfsLun & BIT7) == BIT7) {
523 ((UINT8 *)Lun)[0] = UFS_WLUN_PREFIX;
524 ((UINT8 *)Lun)[1] = UfsLun & ~BIT7;
526 ((UINT8 *)Lun)[1] = UfsLun;
614 IN OUT UINT8 **Target
617 if ((Target ==
NULL) || (*Target ==
NULL)) {
618 return EFI_INVALID_PARAMETER;
621 SetMem (mUfsTargetId, TARGET_MAX_BYTES, 0xFF);
622 if (
CompareMem (*Target, mUfsTargetId, TARGET_MAX_BYTES) == 0) {
623 SetMem (*Target, TARGET_MAX_BYTES, 0x00);
627 return EFI_NOT_FOUND;
688 Status =
gBS->OpenProtocol (
690 &gEfiDevicePathProtocolGuid,
691 (VOID *)&ParentDevicePath,
692 This->DriverBindingHandle,
694 EFI_OPEN_PROTOCOL_BY_DRIVER
696 if (EFI_ERROR (Status)) {
708 &gEfiDevicePathProtocolGuid,
709 This->DriverBindingHandle,
713 Status =
gBS->OpenProtocol (
716 (VOID **)&UfsHostController,
717 This->DriverBindingHandle,
719 EFI_OPEN_PROTOCOL_BY_DRIVER
722 if (EFI_ERROR (Status)) {
735 This->DriverBindingHandle,
758 UINT8 DeviceInitStatus;
761 DeviceInitStatus = 0xFF;
762 Timeout =
PcdGet32 (PcdUfsInitialCompletionTimeout);
767 Status =
UfsSetFlag (Private, UfsFlagDevInit);
768 if (EFI_ERROR (Status)) {
773 Status =
UfsReadFlag (Private, UfsFlagDevInit, &DeviceInitStatus);
774 if (EFI_ERROR (Status)) {
780 }
while (DeviceInitStatus != 0 && Timeout != 0);
783 DEBUG ((DEBUG_ERROR,
"UfsFinishDeviceInitialization DeviceInitStatus=%x EFI_TIMEOUT \n", DeviceInitStatus));
786 DEBUG ((DEBUG_INFO,
"UfsFinishDeviceInitialization Timeout left=%x EFI_SUCCESS \n", Timeout));
841 UINT32 UnitDescriptorSize;
842 UINT32 DeviceDescriptorSize;
843 EDKII_UFS_CARD_REF_CLK_FREQ_ATTRIBUTE Attributes;
851 DEBUG ((DEBUG_INFO,
"==UfsPassThru Start== Controller = %x\n", Controller));
853 Status =
gBS->OpenProtocol (
857 This->DriverBindingHandle,
859 EFI_OPEN_PROTOCOL_BY_DRIVER
862 if (EFI_ERROR (Status)) {
863 DEBUG ((DEBUG_ERROR,
"Open Ufs Host Controller Protocol Error, Status = %r\n", Status));
870 Status = UfsHc->GetUfsHcMmioBar (UfsHc, &UfsHcBase);
871 if (EFI_ERROR (Status)) {
872 DEBUG ((DEBUG_ERROR,
"Get Ufs Host Controller Mmio Bar Error, Status = %r\n", Status));
880 if (Private ==
NULL) {
881 DEBUG ((DEBUG_ERROR,
"Unable to allocate Ufs Pass Thru private data\n"));
882 Status = EFI_OUT_OF_RESOURCES;
886 Private->ExtScsiPassThru.
Mode = &Private->ExtScsiPassThruMode;
887 Private->UfsHostController = UfsHc;
888 Private->UfsHcBase = UfsHcBase;
889 Private->Handle = Controller;
897 if (mUfsHcPlatform ==
NULL) {
898 Status =
gBS->LocateProtocol (&gEdkiiUfsHcPlatformProtocolGuid,
NULL, (VOID **)&mUfsHcPlatform);
899 if (EFI_ERROR (Status)) {
900 DEBUG ((DEBUG_INFO,
"No UfsHcPlatformProtocol present\n"));
905 if (EFI_ERROR (Status)) {
906 DEBUG ((DEBUG_ERROR,
"Failed to initialize UfsHcInfo\n"));
914 if (EFI_ERROR (Status)) {
915 DEBUG ((DEBUG_ERROR,
"Ufs Host Controller Initialization Error, Status = %r\n", Status));
925 if (EFI_ERROR (Status)) {
926 DEBUG ((DEBUG_ERROR,
"Ufs Sending NOP IN command Error, Status = %r\n", Status));
931 if (EFI_ERROR (Status)) {
932 DEBUG ((DEBUG_ERROR,
"Device failed to finish initialization, Status = %r\n", Status));
936 if ((mUfsHcPlatform !=
NULL) &&
937 ((mUfsHcPlatform->
RefClkFreq == EdkiiUfsCardRefClkFreq19p2Mhz) ||
938 (mUfsHcPlatform->
RefClkFreq == EdkiiUfsCardRefClkFreq26Mhz) ||
939 (mUfsHcPlatform->
RefClkFreq == EdkiiUfsCardRefClkFreq38p4Mhz)))
941 RefClkAttr = UfsAttrRefClkFreq;
942 Attributes = EdkiiUfsCardRefClkFreqObsolete;
944 if (!EFI_ERROR (Status)) {
945 if (Attributes != mUfsHcPlatform->
RefClkFreq) {
949 "Setting bRefClkFreq attribute(%x) to %x\n 0 -> 19.2 Mhz\n 1 -> 26 Mhz\n 2 -> 38.4 Mhz\n 3 -> Obsolete\n",
954 if (EFI_ERROR (Status)) {
957 "Failed to Change Reference Clock Attribute to %d, Status = %r \n",
966 "Failed to Read Reference Clock Attribute, Status = %r \n",
973 Status = mUfsHcPlatform->
Callback (Private->Handle, EdkiiUfsHcPostLinkStartup, &Private->UfsHcDriverInterface);
974 if (EFI_ERROR (Status)) {
977 "Failure from platform driver during EdkiiUfsHcPostLinkStartup, Status = %r\n",
988 for (Index = 0; Index < 8; Index++) {
989 Status =
UfsRwDeviceDesc (Private,
TRUE, UfsUnitDesc, (UINT8)Index, 0, &UnitDescriptor, &UnitDescriptorSize);
990 if (EFI_ERROR (Status)) {
991 DEBUG ((DEBUG_ERROR,
"Failed to read unit descriptor, index = %X, status = %r\n", Index, Status));
995 if (UnitDescriptor.LunEn == 0x1) {
996 DEBUG ((DEBUG_INFO,
"UFS LUN %X is enabled\n", Index));
997 Private->Luns.BitMask |= (BIT0 << Index);
1005 Status =
UfsRwDeviceDesc (Private,
TRUE, UfsDeviceDesc, 0, 0, &DeviceDescriptor, &DeviceDescriptorSize);
1006 if (EFI_ERROR (Status)) {
1007 DEBUG ((DEBUG_ERROR,
"Failed to read device descriptor, status = %r\n", Status));
1009 if (DeviceDescriptor.SecurityLun == 0x1) {
1010 DEBUG ((DEBUG_INFO,
"UFS WLUN RPMB is supported\n"));
1011 Private->Luns.BitMask |= BIT11;
1018 Status =
gBS->CreateEvent (
1019 EVT_TIMER | EVT_NOTIFY_SIGNAL,
1023 &Private->TimerEvent
1025 if (EFI_ERROR (Status)) {
1026 DEBUG ((DEBUG_ERROR,
"Ufs Create Async Tasks Event Error, Status = %r\n", Status));
1030 Status =
gBS->SetTimer (
1031 Private->TimerEvent,
1035 if (EFI_ERROR (Status)) {
1036 DEBUG ((DEBUG_ERROR,
"Ufs Set Periodic Timer Error, Status = %r\n", Status));
1040 Status =
gBS->InstallMultipleProtocolInterfaces (
1042 &gEfiExtScsiPassThruProtocolGuid,
1043 &(Private->ExtScsiPassThru),
1045 &(Private->UfsDevConfig),
1053 if (Private !=
NULL) {
1054 if (Private->TmrlMapping !=
NULL) {
1055 UfsHc->Unmap (UfsHc, Private->TmrlMapping);
1058 if (Private->UtpTmrlBase !=
NULL) {
1062 if (Private->TrlMapping !=
NULL) {
1063 UfsHc->Unmap (UfsHc, Private->TrlMapping);
1066 if (Private->UtpTrlBase !=
NULL) {
1070 if (Private->TimerEvent !=
NULL) {
1071 gBS->CloseEvent (Private->TimerEvent);
1077 if (UfsHc !=
NULL) {
1078 gBS->CloseProtocol (
1081 This->DriverBindingHandle,
1132 DEBUG ((DEBUG_INFO,
"==UfsPassThru Stop== Controller Controller = %x\n", Controller));
1134 Status =
gBS->OpenProtocol (
1136 &gEfiExtScsiPassThruProtocolGuid,
1137 (VOID **)&ExtScsiPassThru,
1138 This->DriverBindingHandle,
1140 EFI_OPEN_PROTOCOL_GET_PROTOCOL
1143 if (EFI_ERROR (Status)) {
1144 return EFI_DEVICE_ERROR;
1147 Private = UFS_PASS_THRU_PRIVATE_DATA_FROM_THIS (ExtScsiPassThru);
1148 UfsHc = Private->UfsHostController;
1155 TransReq = UFS_PASS_THRU_TRANS_REQ_FROM_THIS (Entry);
1162 EFI_EXT_SCSI_STATUS_HOST_ADAPTER_PHASE_ERROR;
1168 Status =
gBS->UninstallMultipleProtocolInterfaces (
1170 &gEfiExtScsiPassThruProtocolGuid,
1171 &(Private->ExtScsiPassThru),
1173 &(Private->UfsDevConfig),
1177 if (EFI_ERROR (Status)) {
1178 return EFI_DEVICE_ERROR;
1187 if (Private->TmrlMapping !=
NULL) {
1188 UfsHc->Unmap (UfsHc, Private->TmrlMapping);
1191 if (Private->UtpTmrlBase !=
NULL) {
1195 if (Private->TrlMapping !=
NULL) {
1196 UfsHc->Unmap (UfsHc, Private->TrlMapping);
1199 if (Private->UtpTrlBase !=
NULL) {
1203 if (Private->TimerEvent !=
NULL) {
1204 gBS->CloseEvent (Private->TimerEvent);
1212 gBS->CloseProtocol (
1215 This->DriverBindingHandle,
1247 &gUfsPassThruDriverBinding,
1249 &gUfsPassThruComponentName,
1250 &gUfsPassThruComponentName2
UINTN EFIAPI MicroSecondDelay(IN UINTN MicroSeconds)
BOOLEAN EFIAPI IsListEmpty(IN CONST LIST_ENTRY *ListHead)
#define BASE_LIST_FOR_EACH_SAFE(Entry, NextEntry, ListHead)
LIST_ENTRY *EFIAPI InitializeListHead(IN OUT LIST_ENTRY *ListHead)
INTN EFIAPI CompareMem(IN CONST VOID *DestinationBuffer, IN CONST VOID *SourceBuffer, IN UINTN Length)
VOID *EFIAPI SetMem(OUT VOID *Buffer, IN UINTN Length, IN UINT8 Value)
#define MESSAGING_DEVICE_PATH
UINTN EFIAPI DevicePathNodeLength(IN CONST VOID *Node)
VOID EFIAPI FreePool(IN VOID *Buffer)
VOID *EFIAPI AllocateCopyPool(IN UINTN AllocationSize, IN CONST VOID *Buffer)
#define ADDRESS_IS_ALIGNED(Address, Alignment)
#define GLOBAL_REMOVE_IF_UNREFERENCED
#define ASSERT_EFI_ERROR(StatusParameter)
#define DEBUG(Expression)
VOID EFIAPI ProcessAsyncTaskList(IN EFI_EVENT Event, IN VOID *Context)
#define PcdGet32(TokenName)
EFI_GUID gEdkiiUfsHostControllerProtocolGuid
#define EFI_SIZE_TO_PAGES(Size)
EFI_STATUS EFIAPI EfiLibInstallDriverBindingComponentName2(IN CONST EFI_HANDLE ImageHandle, IN CONST EFI_SYSTEM_TABLE *SystemTable, IN EFI_DRIVER_BINDING_PROTOCOL *DriverBinding, IN EFI_HANDLE DriverBindingHandle, IN CONST EFI_COMPONENT_NAME_PROTOCOL *ComponentName OPTIONAL, IN CONST EFI_COMPONENT_NAME2_PROTOCOL *ComponentName2 OPTIONAL)
EFI_STATUS UfsRwDeviceDesc(IN UFS_PEIM_HC_PRIVATE_DATA *Private, IN BOOLEAN Read, IN UINT8 DescId, IN UINT8 Index, IN UINT8 Selector, IN OUT VOID *Descriptor, IN UINT32 DescSize)
EFI_STATUS UfsRwAttributes(IN UFS_PEIM_HC_PRIVATE_DATA *Private, IN BOOLEAN Read, IN UINT8 AttrId, IN UINT8 Index, IN UINT8 Selector, IN OUT UINT32 *Attributes)
EFI_STATUS UfsReadFlag(IN UFS_PEIM_HC_PRIVATE_DATA *Private, IN UINT8 FlagId, OUT UINT8 *Value)
EFI_STATUS UfsExecNopCmds(IN UFS_PEIM_HC_PRIVATE_DATA *Private)
EFI_STATUS UfsControllerInit(IN EDKII_UFS_HC_PLATFORM_PPI *UfsHcPlatformPpi, IN UFS_PEIM_HC_PRIVATE_DATA *Private)
EFI_STATUS UfsControllerStop(IN UFS_PEIM_HC_PRIVATE_DATA *Private)
EFI_STATUS UfsSetFlag(IN UFS_PEIM_HC_PRIVATE_DATA *Private, IN UINT8 FlagId)
EFI_STATUS UfsExecScsiCmds(IN UFS_PEIM_HC_PRIVATE_DATA *Private, IN UINT8 Lun, IN OUT UFS_SCSI_REQUEST_PACKET *Packet)
EFI_STATUS EFIAPI UfsRwUfsAttribute(IN EFI_UFS_DEVICE_CONFIG_PROTOCOL *This, IN BOOLEAN Read, IN UINT8 AttrId, IN UINT8 Index, IN UINT8 Selector, IN OUT UINT8 *Attribute, IN OUT UINT32 *AttrSize)
EFI_STATUS EFIAPI UfsRwUfsFlag(IN EFI_UFS_DEVICE_CONFIG_PROTOCOL *This, IN BOOLEAN Read, IN UINT8 FlagId, IN OUT UINT8 *Flag)
EFI_STATUS EFIAPI UfsRwUfsDescriptor(IN EFI_UFS_DEVICE_CONFIG_PROTOCOL *This, IN BOOLEAN Read, IN UINT8 DescId, IN UINT8 Index, IN UINT8 Selector, IN OUT UINT8 *Descriptor, IN OUT UINT32 *DescSize)
EFI_GUID gEfiUfsDeviceConfigProtocolGuid
EFI_STATUS EFIAPI UfsPassThruGetNextTargetLun(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN OUT UINT8 **Target, IN OUT UINT64 *Lun)
EFI_STATUS EFIAPI InitializeUfsPassThru(IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable)
EFI_STATUS EFIAPI UfsPassThruResetTargetLun(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN UINT8 *Target, IN UINT64 Lun)
EFI_STATUS EFIAPI UfsPassThruPassThru(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN UINT8 *Target, IN UINT64 Lun, IN OUT EFI_EXT_SCSI_PASS_THRU_SCSI_REQUEST_PACKET *Packet, IN EFI_EVENT Event OPTIONAL)
EFI_STATUS EFIAPI UfsPassThruBuildDevicePath(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN UINT8 *Target, IN UINT64 Lun, IN OUT EFI_DEVICE_PATH_PROTOCOL **DevicePath)
EFI_STATUS EFIAPI UfsPassThruGetTargetLun(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN EFI_DEVICE_PATH_PROTOCOL *DevicePath, OUT UINT8 **Target, OUT UINT64 *Lun)
EFI_STATUS UfsFinishDeviceInitialization(IN UFS_PASS_THRU_PRIVATE_DATA *Private)
EFI_STATUS EFIAPI UfsPassThruGetNextTarget(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This, IN OUT UINT8 **Target)
EFI_STATUS EFIAPI UfsPassThruDriverBindingStart(IN EFI_DRIVER_BINDING_PROTOCOL *This, IN EFI_HANDLE Controller, IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath)
EFI_STATUS EFIAPI UfsPassThruResetChannel(IN EFI_EXT_SCSI_PASS_THRU_PROTOCOL *This)
EFI_STATUS EFIAPI UfsPassThruDriverBindingStop(IN EFI_DRIVER_BINDING_PROTOCOL *This, IN EFI_HANDLE Controller, IN UINTN NumberOfChildren, IN EFI_HANDLE *ChildHandleBuffer)
EFI_STATUS EFIAPI UfsPassThruDriverBindingSupported(IN EFI_DRIVER_BINDING_PROTOCOL *This, IN EFI_HANDLE Controller, IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath)
EFI_STATUS GetUfsHcInfo(IN UFS_PASS_THRU_PRIVATE_DATA *Private)
EFI_STATUS EFIAPI UfsHcDriverInterfaceExecUicCommand(IN EDKII_UFS_HC_DRIVER_INTERFACE *This, IN OUT EDKII_UIC_COMMAND *UicCommand)
VOID EFIAPI SignalCallerEvent(IN UFS_PASS_THRU_PRIVATE_DATA *Private, IN UFS_PASS_THRU_TRANS_REQ *TransReq)
EDKII_UFS_EXEC_UIC_COMMAND UfsExecUicCommand
EDKII_UFS_HOST_CONTROLLER_PROTOCOL * UfsHcProtocol
EDKII_UFS_CARD_REF_CLK_FREQ_ATTRIBUTE RefClkFreq
EDKII_UFS_HC_PLATFORM_CALLBACK Callback
EFI_EXT_SCSI_PASS_THRU_MODE * Mode