Skip to content

Commit

Permalink
MdePkg BootManagerPolicy.h: Define GUID for connecting storage devices.
Browse files Browse the repository at this point in the history
Some platforms require connecting storage media while booting to
network, or require enumerating storage protocols that were not initially
enumerated during BDS. This change adds a GUID to allow implementation
of boot manager's ConnectDeviceClass to connect storage media.

Signed-off-by: Aaron Pop <[email protected]>
  • Loading branch information
cfernald authored and mergify[bot] committed Dec 17, 2024
1 parent b38180e commit cef65b2
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
13 changes: 13 additions & 0 deletions MdePkg/Include/Protocol/BootManagerPolicy.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
to connect devices using platform policy.
Copyright (c) 2015 - 2018, Intel Corporation. All rights reserved.<BR>
Copyright (c) Microsoft Corporation.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/

Expand All @@ -31,6 +32,11 @@
0x113B2126, 0xFC8A, 0x11E3, { 0xBD, 0x6C, 0xB8, 0xE8, 0x56, 0x2C, 0xBA, 0xFA } \
}

#define EFI_BOOT_MANAGER_POLICY_STORAGE_GUID \
{ \
0xCD68FE79, 0xD3CB, 0x436E, { 0xA8, 0x50, 0xF4, 0x43, 0xC8, 0x8C, 0xFB, 0x49 } \
}

typedef struct _EFI_BOOT_MANAGER_POLICY_PROTOCOL EFI_BOOT_MANAGER_POLICY_PROTOCOL;

#define EFI_BOOT_MANAGER_POLICY_PROTOCOL_REVISION 0x00010000
Expand Down Expand Up @@ -98,6 +104,12 @@ EFI_STATUS
EFI_BOOT_SERVICES.ConnectController(). If the Boot Manager has policy
associated with connect all UEFI drivers this policy will be used.
If Class is EFI_BOOT_MANAGER_POLICY_STORAGE_GUID then the Boot Manager will
connect the protocols associated with the discoverable storage disks. This may include
EFI_BLOCK_IO_PROTOCOL, EFI_SIMPLE_FILE_SYSTEM_PROTOCOL, or other storage protocols
appropriate to the device. Some platforms may choose to restrict the connected
devices to exclude USB or other peripherals.
A platform can also define platform specific Class values as a properly generated
EFI_GUID would never conflict with this specification.
Expand Down Expand Up @@ -128,5 +140,6 @@ extern EFI_GUID gEfiBootManagerPolicyProtocolGuid;
extern EFI_GUID gEfiBootManagerPolicyConsoleGuid;
extern EFI_GUID gEfiBootManagerPolicyNetworkGuid;
extern EFI_GUID gEfiBootManagerPolicyConnectAllGuid;
extern EFI_GUID gEfiBootManagerPolicyStorageGuid;

#endif
2 changes: 2 additions & 0 deletions MdePkg/MdePkg.dec
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
# Copyright (c) 2021 - 2022, Arm Limited. All rights reserved.<BR>
# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
# Copyright (c) 2023, Ampere Computing LLC. All rights reserved.<BR>
# Copyright (c) Microsoft Corporation.<BR>
#
# SPDX-License-Identifier: BSD-2-Clause-Patent
#
Expand Down Expand Up @@ -702,6 +703,7 @@
gEfiBootManagerPolicyConsoleGuid = { 0xCAB0E94C, 0xE15F, 0x11E3, { 0x91, 0x8D, 0xB8, 0xE8, 0x56, 0x2C, 0xBA, 0xFA }}
gEfiBootManagerPolicyNetworkGuid = { 0xD04159DC, 0xE15F, 0x11E3, { 0xB2, 0x61, 0xB8, 0xE8, 0x56, 0x2C, 0xBA, 0xFA }}
gEfiBootManagerPolicyConnectAllGuid = { 0x113B2126, 0xFC8A, 0x11E3, { 0xBD, 0x6C, 0xB8, 0xE8, 0x56, 0x2C, 0xBA, 0xFA }}
gEfiBootManagerPolicyStorageGuid = { 0xCD68FE79, 0xD3CB, 0x436E, { 0xA8, 0x50, 0xF4, 0x43, 0xC8, 0x8C, 0xFB, 0x49 }}

## Include/Protocol/DevicePath.h
gEfiVirtualDiskGuid = { 0x77AB535A, 0x45FC, 0x624B, {0x55, 0x60, 0xF7, 0xB2, 0x81, 0xD1, 0xF9, 0x6E }}
Expand Down

0 comments on commit cef65b2

Please sign in to comment.