ArmPkg: only attempt buildin MmCommunicationDxe for AArch64
[mirror_edk2.git] / EmbeddedPkg / Include / Protocol / PlatformBootManager.h
CommitLineData
7e074d15
HZ
1/** @file\r
2\r
3 Copyright (c) 2018, Linaro. All rights reserved.<BR>\r
4\r
878b807a 5 SPDX-License-Identifier: BSD-2-Clause-Patent\r
7e074d15
HZ
6\r
7**/\r
8\r
9#ifndef __PLATFORM_BOOT_MANAGER_PROTOCOL_H__\r
10#define __PLATFORM_BOOT_MANAGER_PROTOCOL_H__\r
11\r
12//\r
13// Protocol interface structure\r
14//\r
15typedef struct _PLATFORM_BOOT_MANAGER_PROTOCOL PLATFORM_BOOT_MANAGER_PROTOCOL;\r
16\r
17//\r
18// Function Prototypes\r
19//\r
20\r
21/*\r
22 Get predefined boot options for platform.\r
23\r
24 @param[out] Count The number of elements in each of\r
25 BootOptions and BootKeys. On successful\r
26 return, Count is at least one.\r
27\r
28 @param[out] BootOptions An array of platform boot options.\r
29 BootOptions is pool-allocated by\r
30 GET_PLATFORM_BOOT_OPTIONS_AND_KEYS, and\r
31 GET_PLATFORM_BOOT_OPTIONS_AND_KEYS populates\r
32 every element in BootOptions with\r
33 EfiBootManagerInitializeLoadOption().\r
34 BootOptions shall not contain duplicate\r
35 entries. The caller is responsible for\r
36 releasing BootOptions after use with\r
37 EfiBootManagerFreeLoadOptions().\r
38\r
39 @param[out] BootKeys A pool-allocated array of platform boot\r
40 hotkeys. For every 0 <= Index < Count, if\r
41 BootOptions[Index] is not to be associated\r
42 with a hotkey, then BootKeys[Index] is\r
43 zero-filled. Otherwise, BootKeys[Index]\r
44 specifies the boot hotkey for\r
45 BootOptions[Index]. BootKeys shall not\r
46 contain duplicate entries (other than\r
47 zero-filled entries). The caller is\r
48 responsible for releasing BootKeys with\r
49 FreePool() after use.\r
50\r
51 @retval EFI_SUCCESS Count, BootOptions and BootKeys have\r
52 been set.\r
53\r
54 @retval EFI_OUT_OF_RESOURCES Memory allocation failed.\r
55\r
56 @retval EFI_UNSUPPORTED The platform doesn't provide boot options\r
57 as a feature.\r
58\r
59 @retval EFI_NOT_FOUND The platform could provide boot options\r
60 as a feature, but none have been\r
61 configured.\r
62\r
63 @return Error codes propagated from underlying\r
64 functions.\r
65*/\r
66typedef\r
67EFI_STATUS\r
68(EFIAPI *GET_PLATFORM_BOOT_OPTIONS_AND_KEYS) (\r
69 OUT UINTN *Count,\r
70 OUT EFI_BOOT_MANAGER_LOAD_OPTION **BootOptions,\r
71 OUT EFI_INPUT_KEY **BootKeys\r
72 );\r
73\r
74struct _PLATFORM_BOOT_MANAGER_PROTOCOL {\r
75 GET_PLATFORM_BOOT_OPTIONS_AND_KEYS GetPlatformBootOptionsAndKeys;\r
76};\r
77\r
78extern EFI_GUID gPlatformBootManagerProtocolGuid;\r
79\r
80#endif /* __PLATFORM_BOOT_MANAGER_PROTOCOL_H__ */\r