TianoCore EDK2 master
Loading...
Searching...
No Matches
NvmExpressDiskInfo.c File Reference
#include "NvmExpress.h"

Go to the source code of this file.

Functions

VOID InitializeDiskInfo (IN NVME_DEVICE_PRIVATE_DATA *Device)
 
EFI_STATUS EFIAPI NvmExpressDiskInfoInquiry (IN EFI_DISK_INFO_PROTOCOL *This, IN OUT VOID *InquiryData, IN OUT UINT32 *InquiryDataSize)
 
EFI_STATUS EFIAPI NvmExpressDiskInfoIdentify (IN EFI_DISK_INFO_PROTOCOL *This, IN OUT VOID *IdentifyData, IN OUT UINT32 *IdentifyDataSize)
 
EFI_STATUS EFIAPI NvmExpressDiskInfoSenseData (IN EFI_DISK_INFO_PROTOCOL *This, IN OUT VOID *SenseData, IN OUT UINT32 *SenseDataSize, OUT UINT8 *SenseDataNumber)
 
EFI_STATUS EFIAPI NvmExpressDiskInfoWhichIde (IN EFI_DISK_INFO_PROTOCOL *This, OUT UINT32 *IdeChannel, OUT UINT32 *IdeDevice)
 

Variables

EFI_DISK_INFO_PROTOCOL gNvmExpressDiskInfoProtocolTemplate
 

Detailed Description

This file is used to implement the EFI_DISK_INFO_PROTOCOL interface..

Copyright (c) 2013, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file NvmExpressDiskInfo.c.

Function Documentation

◆ InitializeDiskInfo()

VOID InitializeDiskInfo ( IN NVME_DEVICE_PRIVATE_DATA Device)

Initialize the installation of DiskInfo protocol.

This function prepares for the installation of DiskInfo protocol on the child handle. By default, it installs DiskInfo protocol with NVME interface GUID.

Parameters
[in]DeviceThe pointer of NVME_DEVICE_PRIVATE_DATA.

Definition at line 29 of file NvmExpressDiskInfo.c.

◆ NvmExpressDiskInfoIdentify()

EFI_STATUS EFIAPI NvmExpressDiskInfoIdentify ( IN EFI_DISK_INFO_PROTOCOL This,
IN OUT VOID *  IdentifyData,
IN OUT UINT32 *  IdentifyDataSize 
)

Provides identify information for the controller type.

This function is used to get identify data. Data format of Identify data is defined by the Interface GUID.

Parameters
[in]ThisPointer to the EFI_DISK_INFO_PROTOCOL instance.
[in,out]IdentifyDataPointer to a buffer for the identify data.
[in,out]IdentifyDataSizePointer to the value for the identify data size.
Return values
EFI_SUCCESSThe command was accepted without any errors.
EFI_NOT_FOUNDDevice does not support this data class
EFI_DEVICE_ERRORError reading IdentifyData from device
EFI_BUFFER_TOO_SMALLIdentifyDataSize not big enough

Definition at line 83 of file NvmExpressDiskInfo.c.

◆ NvmExpressDiskInfoInquiry()

EFI_STATUS EFIAPI NvmExpressDiskInfoInquiry ( IN EFI_DISK_INFO_PROTOCOL This,
IN OUT VOID *  InquiryData,
IN OUT UINT32 *  InquiryDataSize 
)

Provides inquiry information for the controller type.

This function is used to get inquiry data. Data format of Identify data is defined by the Interface GUID.

Parameters
[in]ThisPointer to the EFI_DISK_INFO_PROTOCOL instance.
[in,out]InquiryDataPointer to a buffer for the inquiry data.
[in,out]InquiryDataSizePointer to the value for the inquiry data size.
Return values
EFI_SUCCESSThe command was accepted without any errors.
EFI_NOT_FOUNDDevice does not support this data class
EFI_DEVICE_ERRORError reading InquiryData from device
EFI_BUFFER_TOO_SMALLInquiryDataSize not big enough

Definition at line 54 of file NvmExpressDiskInfo.c.

◆ NvmExpressDiskInfoSenseData()

EFI_STATUS EFIAPI NvmExpressDiskInfoSenseData ( IN EFI_DISK_INFO_PROTOCOL This,
IN OUT VOID *  SenseData,
IN OUT UINT32 *  SenseDataSize,
OUT UINT8 *  SenseDataNumber 
)

Provides sense data information for the controller type.

This function is used to get sense data. Data format of Sense data is defined by the Interface GUID.

Parameters
[in]ThisPointer to the EFI_DISK_INFO_PROTOCOL instance.
[in,out]SenseDataPointer to the SenseData.
[in,out]SenseDataSizeSize of SenseData in bytes.
[out]SenseDataNumberPointer to the value for the sense data size.
Return values
EFI_SUCCESSThe command was accepted without any errors.
EFI_NOT_FOUNDDevice does not support this data class.
EFI_DEVICE_ERRORError reading SenseData from device.
EFI_BUFFER_TOO_SMALLSenseDataSize not big enough.

Definition at line 123 of file NvmExpressDiskInfo.c.

◆ NvmExpressDiskInfoWhichIde()

EFI_STATUS EFIAPI NvmExpressDiskInfoWhichIde ( IN EFI_DISK_INFO_PROTOCOL This,
OUT UINT32 *  IdeChannel,
OUT UINT32 *  IdeDevice 
)

This function is used to get controller information.

Parameters
[in]ThisPointer to the EFI_DISK_INFO_PROTOCOL instance.
[out]IdeChannelPointer to the Ide Channel number. Primary or secondary.
[out]IdeDevicePointer to the Ide Device number. Master or slave.
Return values
EFI_SUCCESSIdeChannel and IdeDevice are valid.
EFI_UNSUPPORTEDThis is not an IDE device.

Definition at line 146 of file NvmExpressDiskInfo.c.

Variable Documentation

◆ gNvmExpressDiskInfoProtocolTemplate

EFI_DISK_INFO_PROTOCOL gNvmExpressDiskInfoProtocolTemplate
Initial value:
= {
}
#define EFI_DISK_INFO_NVME_INTERFACE_GUID
Definition: DiskInfo.h:65
EFI_STATUS EFIAPI NvmExpressDiskInfoSenseData(IN EFI_DISK_INFO_PROTOCOL *This, IN OUT VOID *SenseData, IN OUT UINT32 *SenseDataSize, OUT UINT8 *SenseDataNumber)
EFI_STATUS EFIAPI NvmExpressDiskInfoWhichIde(IN EFI_DISK_INFO_PROTOCOL *This, OUT UINT32 *IdeChannel, OUT UINT32 *IdeDevice)
EFI_STATUS EFIAPI NvmExpressDiskInfoIdentify(IN EFI_DISK_INFO_PROTOCOL *This, IN OUT VOID *IdentifyData, IN OUT UINT32 *IdentifyDataSize)
EFI_STATUS EFIAPI NvmExpressDiskInfoInquiry(IN EFI_DISK_INFO_PROTOCOL *This, IN OUT VOID *InquiryData, IN OUT UINT32 *InquiryDataSize)

Definition at line 11 of file NvmExpressDiskInfo.c.