TianoCore EDK2
master
Loading...
Searching...
No Matches
HddPasswordCommon.h
Go to the documentation of this file.
1
10
#ifndef _HDD_PASSWORD_COMMON_H_
11
#define _HDD_PASSWORD_COMMON_H_
12
13
//
14
// The payload length of HDD related ATA commands
15
//
16
#define HDD_PAYLOAD 512
17
18
#define ATA_SECURITY_SET_PASSWORD_CMD 0xF1
19
#define ATA_SECURITY_UNLOCK_CMD 0xF2
20
#define ATA_SECURITY_FREEZE_LOCK_CMD 0xF5
21
#define ATA_SECURITY_DIS_PASSWORD_CMD 0xF6
22
23
//
24
// The max retry count specified in ATA 8 spec.
25
//
26
#define MAX_HDD_PASSWORD_RETRY_COUNT 5
27
28
//
29
// According to ATA spec, the max length of hdd password is 32 bytes
30
//
31
#define HDD_PASSWORD_MAX_LENGTH 32
32
33
#define HDD_PASSWORD_DEVICE_INFO_GUID { 0x96d877ad, 0x48af, 0x4b39, { 0x9b, 0x27, 0x4d, 0x97, 0x43, 0x9, 0xae, 0x47 } }
34
35
typedef
struct
{
36
UINT8 Bus;
37
UINT8 Device;
38
UINT8 Function;
39
UINT8 Reserved;
40
UINT16 Port;
41
UINT16 PortMultiplierPort;
42
}
HDD_PASSWORD_DEVICE
;
43
44
//
45
// It will be used to unlock HDD password for S3.
46
//
47
typedef
struct
{
48
HDD_PASSWORD_DEVICE
Device;
49
CHAR8 Password[HDD_PASSWORD_MAX_LENGTH];
50
UINT32 DevicePathLength;
51
EFI_DEVICE_PATH_PROTOCOL
DevicePath[];
52
}
HDD_PASSWORD_DEVICE_INFO
;
53
54
#endif
// _HDD_PASSWORD_COMMON_H_
EFI_DEVICE_PATH_PROTOCOL
Definition:
DevicePath.h:43
HDD_PASSWORD_DEVICE_INFO
Definition:
HddPasswordCommon.h:47
HDD_PASSWORD_DEVICE
Definition:
HddPasswordCommon.h:35
SecurityPkg
HddPassword
HddPasswordCommon.h
Generated on Fri Nov 15 2024 18:01:23 for TianoCore EDK2 by
1.9.6