|
TianoCore EDK2 master
|
Go to the source code of this file.
Macros | |
| #define | NVME_SHUTDOWN_PROCESS_TIMEOUT 45 |
Variables | |
| UINTN | mNvmeControllerNumber = 0 |
NvmExpressDxe driver is used to manage non-volatile memory subsystem which follows NVM Express specification.
Copyright (c) 2013 - 2019, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file NvmExpressHci.c.
| #define NVME_SHUTDOWN_PROCESS_TIMEOUT 45 |
Definition at line 13 of file NvmExpressHci.c.
| EFI_STATUS NvmeControllerInit | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private | ) |
Initialize the Nvm Express controller.
| [in] | Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| EFI_SUCCESS | The NVM Express Controller is initialized successfully. |
| Others | A device error occurred while initializing the controller. |
Definition at line 723 of file NvmExpressHci.c.
| EFI_STATUS NvmeCreateIoCompletionQueue | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private | ) |
Create io completion queue.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
Definition at line 577 of file NvmExpressHci.c.
| EFI_STATUS NvmeCreateIoSubmissionQueue | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private | ) |
Create io submission queue.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
Definition at line 649 of file NvmExpressHci.c.
| EFI_STATUS NvmeDisableController | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private | ) |
Disable the Nvm Express controller.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
Definition at line 314 of file NvmExpressHci.c.
| EFI_STATUS NvmeEnableController | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private | ) |
Enable the Nvm Express controller.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
Definition at line 393 of file NvmExpressHci.c.
| EFI_STATUS NvmeIdentifyController | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private, |
| IN VOID * | Buffer | ||
| ) |
Get identify controller data.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| Buffer | The buffer used to store the identify controller data. |
Definition at line 472 of file NvmExpressHci.c.
| EFI_STATUS NvmeIdentifyNamespace | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private, |
| IN UINT32 | NamespaceId, | ||
| IN VOID * | Buffer | ||
| ) |
Get specified identify namespace data.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| NamespaceId | The specified namespace identifier. |
| Buffer | The buffer used to store the identify namespace data. |
Definition at line 527 of file NvmExpressHci.c.
Register the shutdown notification through the ResetNotification protocol.
Register the shutdown notification when mNvmeControllerNumber increased from 0 to 1.
Definition at line 1070 of file NvmExpressHci.c.
| VOID EFIAPI NvmeShutdownAllControllers | ( | IN EFI_RESET_TYPE | ResetType, |
| IN EFI_STATUS | ResetStatus, | ||
| IN UINTN | DataSize, | ||
| IN VOID *ResetData | OPTIONAL | ||
| ) |
This routine is called to properly shutdown the Nvm Express controller per NVMe spec.
| [in] | ResetType | The type of reset to perform. |
| [in] | ResetStatus | The status code for the reset. |
| [in] | DataSize | The size, in bytes, of ResetData. |
| [in] | ResetData | For a ResetType of EfiResetCold, EfiResetWarm, or EfiResetShutdown the data buffer starts with a Null-terminated string, optionally followed by additional binary data. The string is a description that the caller may use to further indicate the reason for the system reset. For a ResetType of EfiResetPlatformSpecific the data buffer also starts with a Null-terminated string that is followed by an EFI_GUID that describes the specific type of reset to perform. |
Definition at line 956 of file NvmExpressHci.c.
Unregister the shutdown notification through the ResetNotification protocol.
Unregister the shutdown notification when mNvmeControllerNumber decreased from 1 to 0.
Definition at line 1095 of file NvmExpressHci.c.
| EFI_STATUS ReadNvmeControllerCapabilities | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private, |
| IN NVME_CAP * | Cap | ||
| ) |
Read Nvm Express controller capability register.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| Cap | The buffer used to store capability register content. |
Definition at line 32 of file NvmExpressHci.c.
| EFI_STATUS ReadNvmeControllerConfiguration | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private, |
| IN NVME_CC * | Cc | ||
| ) |
Read Nvm Express controller configuration register.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| Cc | The buffer used to store configuration register content. |
Definition at line 70 of file NvmExpressHci.c.
| EFI_STATUS ReadNvmeControllerStatus | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private, |
| IN NVME_CSTS * | Csts | ||
| ) |
Read Nvm Express controller status register.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| Csts | The buffer used to store status register content. |
Definition at line 154 of file NvmExpressHci.c.
| EFI_STATUS WriteNvmeAdminCompletionQueueBaseAddress | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private, |
| IN NVME_ACQ * | Acq | ||
| ) |
Write Nvm Express admin completion queue base address register.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| Acq | The buffer used to store the content to be written into admin completion queue base address register. |
Definition at line 274 of file NvmExpressHci.c.
| EFI_STATUS WriteNvmeAdminQueueAttributes | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private, |
| IN NVME_AQA * | Aqa | ||
| ) |
Write Nvm Express admin queue attributes register.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| Aqa | The buffer used to store the content to be written into admin queue attributes register. |
Definition at line 192 of file NvmExpressHci.c.
| EFI_STATUS WriteNvmeAdminSubmissionQueueBaseAddress | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private, |
| IN NVME_ASQ * | Asq | ||
| ) |
Write Nvm Express admin submission queue base address register.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| Asq | The buffer used to store the content to be written into admin submission queue base address register. |
Definition at line 233 of file NvmExpressHci.c.
| EFI_STATUS WriteNvmeControllerConfiguration | ( | IN NVME_CONTROLLER_PRIVATE_DATA * | Private, |
| IN NVME_CC * | Cc | ||
| ) |
Write Nvm Express controller configuration register.
| Private | The pointer to the NVME_CONTROLLER_PRIVATE_DATA data structure. |
| Cc | The buffer used to store the content to be written into configuration register. |
Definition at line 108 of file NvmExpressHci.c.
| UINTN mNvmeControllerNumber = 0 |
Definition at line 19 of file NvmExpressHci.c.