]> git.proxmox.com Git - mirror_edk2.git/blob - SecurityPkg/Tcg/MemoryOverwriteControl/TcgMor.h
SecurityPkg: Replace BSD License with BSD+Patent License
[mirror_edk2.git] / SecurityPkg / Tcg / MemoryOverwriteControl / TcgMor.h
1 /** @file
2 The header file for TcgMor.
3
4 Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>
5 SPDX-License-Identifier: BSD-2-Clause-Patent
6
7 **/
8
9 #ifndef __TCG_MOR_H__
10 #define __TCG_MOR_H__
11
12 #include <PiDxe.h>
13
14 #include <Guid/MemoryOverwriteControl.h>
15
16 #include <Library/UefiDriverEntryPoint.h>
17 #include <Library/UefiBootServicesTableLib.h>
18 #include <Library/UefiRuntimeServicesTableLib.h>
19 #include <Library/DebugLib.h>
20 #include <Library/UefiLib.h>
21 #include <Library/MemoryAllocationLib.h>
22
23 #include <Protocol/StorageSecurityCommand.h>
24 #include <Protocol/BlockIo.h>
25
26 //
27 // Supported Security Protocols List Description.
28 // Refer to ATA8-ACS Spec 7.57.6.2 Table 69 or SPC4 7.7.1.3 Table 511.
29 //
30 typedef struct {
31 UINT8 Reserved1[6];
32 UINT8 SupportedSecurityListLength[2];
33 UINT8 SupportedSecurityProtocol[1];
34 } SUPPORTED_SECURITY_PROTOCOLS_PARAMETER_DATA;
35
36 #define SECURITY_PROTOCOL_TCG 0x02
37 #define SECURITY_PROTOCOL_IEEE1667 0xEE
38
39 #define ROUNDUP512(x) (((x) % 512 == 0) ? (x) : ((x) / 512 + 1) * 512)
40
41 #endif
42