|
|
eb7fe6 |
From b8d3656a9f79d481c4897422b3898f30145d281a Mon Sep 17 00:00:00 2001
|
|
|
eb7fe6 |
From: Laszlo Ersek <lersek@redhat.com>
|
|
|
eb7fe6 |
Date: Wed, 29 Mar 2017 12:26:18 +0200
|
|
|
eb7fe6 |
Subject: [PATCH 06/11] EmbeddedPkg: introduce EDKII Platform Has Device Tree
|
|
|
eb7fe6 |
GUID
|
|
|
eb7fe6 |
|
|
|
eb7fe6 |
Message-id: <20170329102623.11570-7-lersek@redhat.com>
|
|
|
eb7fe6 |
Patchwork-id: 74573
|
|
|
eb7fe6 |
O-Subject: [RHEL-7.4 ovmf PATCH 06/11] EmbeddedPkg: introduce EDKII Platform Has
|
|
|
eb7fe6 |
Device Tree GUID
|
|
|
eb7fe6 |
Bugzilla: 1430262
|
|
|
eb7fe6 |
Acked-by: Andrew Jones <drjones@redhat.com>
|
|
|
eb7fe6 |
Acked-by: Al Stone <ahs3@redhat.com>
|
|
|
eb7fe6 |
Acked-by: Vitaly Kuznetsov <vkuznets@redhat.com>
|
|
|
eb7fe6 |
|
|
|
eb7fe6 |
The presence of this GUID in the PPI database, and/or in the DXE protocol
|
|
|
eb7fe6 |
database (as dictated by the platform's needs in these firmware phases)
|
|
|
eb7fe6 |
implies that the platform provides the operating system with a Device
|
|
|
eb7fe6 |
Tree-based hardware description. This is not necessarily exclusive with
|
|
|
eb7fe6 |
other types of hardware description (for example, an ACPI-based one).
|
|
|
eb7fe6 |
|
|
|
eb7fe6 |
A platform PEIM and/or DXE driver is supposed to produce a single instance
|
|
|
eb7fe6 |
of the PPI and/or protocol (with NULL contents), if appropriate. The
|
|
|
eb7fe6 |
decision to produce the PPI and/or protocol is platform specific; for
|
|
|
eb7fe6 |
example, in the DXE phase, it could depend on an HII checkbox / underlying
|
|
|
eb7fe6 |
non-volatile UEFI variable.
|
|
|
eb7fe6 |
|
|
|
eb7fe6 |
In the DXE phase, the protocol is meant to be consumed by the platform
|
|
|
eb7fe6 |
driver that
|
|
|
eb7fe6 |
- owns the Device Tree description of the hardware, and
|
|
|
eb7fe6 |
- is responsible for installing it as a system configuration table.
|
|
|
eb7fe6 |
|
|
|
eb7fe6 |
Said FDT-owner driver can wait for the protocol via DEPEX or protocol
|
|
|
eb7fe6 |
notify.
|
|
|
eb7fe6 |
|
|
|
eb7fe6 |
Because this GUID is not standard, it is prefixed with EDKII / Edkii, as
|
|
|
eb7fe6 |
seen elsewhere (for example in MdeModulePkg and SecurityPkg).
|
|
|
eb7fe6 |
|
|
|
eb7fe6 |
Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
|
|
|
eb7fe6 |
Cc: Leif Lindholm <leif.lindholm@linaro.org>
|
|
|
eb7fe6 |
Contributed-under: TianoCore Contribution Agreement 1.0
|
|
|
eb7fe6 |
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
|
|
|
eb7fe6 |
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
|
|
|
eb7fe6 |
(cherry picked from commit 65a69b21484056794165e5a884e3142120ad61fc)
|
|
|
eb7fe6 |
---
|
|
|
eb7fe6 |
EmbeddedPkg/EmbeddedPkg.dec | 3 ++
|
|
|
eb7fe6 |
EmbeddedPkg/Include/Guid/PlatformHasDeviceTree.h | 35 ++++++++++++++++++++++++
|
|
|
eb7fe6 |
2 files changed, 38 insertions(+)
|
|
|
eb7fe6 |
create mode 100644 EmbeddedPkg/Include/Guid/PlatformHasDeviceTree.h
|
|
|
eb7fe6 |
|
|
|
eb7fe6 |
diff --git a/EmbeddedPkg/EmbeddedPkg.dec b/EmbeddedPkg/EmbeddedPkg.dec
|
|
|
eb7fe6 |
index d078bf7..29736fb 100644
|
|
|
eb7fe6 |
--- a/EmbeddedPkg/EmbeddedPkg.dec
|
|
|
eb7fe6 |
+++ b/EmbeddedPkg/EmbeddedPkg.dec
|
|
|
eb7fe6 |
@@ -59,6 +59,9 @@
|
|
|
eb7fe6 |
## Include/Guid/PlatformHasAcpi.h
|
|
|
eb7fe6 |
gEdkiiPlatformHasAcpiGuid = { 0xf0966b41, 0xc23f, 0x41b9, { 0x96, 0x04, 0x0f, 0xf7, 0xe1, 0x11, 0x96, 0x5a } }
|
|
|
eb7fe6 |
|
|
|
eb7fe6 |
+ ## Include/Guid/PlatformHasDeviceTree.h
|
|
|
eb7fe6 |
+ gEdkiiPlatformHasDeviceTreeGuid = { 0x7ebb920d, 0x1aaf, 0x46d9, { 0xb2, 0xaf, 0x54, 0x1e, 0x1d, 0xce, 0x14, 0x8b } }
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
[Protocols.common]
|
|
|
eb7fe6 |
gHardwareInterruptProtocolGuid = { 0x2890B3EA, 0x053D, 0x1643, { 0xAD, 0x0C, 0xD6, 0x48, 0x08, 0xDA, 0x3F, 0xF1 } }
|
|
|
eb7fe6 |
gEfiDebugSupportPeriodicCallbackProtocolGuid = { 0x9546e07c, 0x2cbb, 0x4c88, { 0x98, 0x6c, 0xcd, 0x34, 0x10, 0x86, 0xf0, 0x44 } }
|
|
|
eb7fe6 |
diff --git a/EmbeddedPkg/Include/Guid/PlatformHasDeviceTree.h b/EmbeddedPkg/Include/Guid/PlatformHasDeviceTree.h
|
|
|
eb7fe6 |
new file mode 100644
|
|
|
eb7fe6 |
index 0000000..a9bc512
|
|
|
eb7fe6 |
--- /dev/null
|
|
|
eb7fe6 |
+++ b/EmbeddedPkg/Include/Guid/PlatformHasDeviceTree.h
|
|
|
eb7fe6 |
@@ -0,0 +1,35 @@
|
|
|
eb7fe6 |
+/** @file
|
|
|
eb7fe6 |
+ EDKII Platform Has Device Tree GUID
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
+ A NULL protocol instance with this GUID in the DXE protocol database, and/or
|
|
|
eb7fe6 |
+ a NULL PPI with this GUID in the PPI database, implies that the platform
|
|
|
eb7fe6 |
+ provides the operating system with a Device Tree-based hardware description.
|
|
|
eb7fe6 |
+ Note that this is not necessarily exclusive with different kinds of hardware
|
|
|
eb7fe6 |
+ description (for example, an ACPI-based one). A platform driver and/or PEIM
|
|
|
eb7fe6 |
+ is supposed to produce a single instance of the protocol and/or PPI (with
|
|
|
eb7fe6 |
+ NULL contents), if appropriate.
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
+ Copyright (C) 2017, Red Hat, Inc.
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
+ This program and the accompanying materials are licensed and made available
|
|
|
eb7fe6 |
+ under the terms and conditions of the BSD License that accompanies this
|
|
|
eb7fe6 |
+ distribution. The full text of the license may be found at
|
|
|
eb7fe6 |
+ http://opensource.org/licenses/bsd-license.php.
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT
|
|
|
eb7fe6 |
+ WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
|
|
eb7fe6 |
+**/
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
+#ifndef __EDKII_PLATFORM_HAS_DEVICE_TREE_H__
|
|
|
eb7fe6 |
+#define __EDKII_PLATFORM_HAS_DEVICE_TREE_H__
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
+#define EDKII_PLATFORM_HAS_DEVICE_TREE_GUID \
|
|
|
eb7fe6 |
+ { \
|
|
|
eb7fe6 |
+ 0x7ebb920d, 0x1aaf, 0x46d9, \
|
|
|
eb7fe6 |
+ { 0xb2, 0xaf, 0x54, 0x1e, 0x1d, 0xce, 0x14, 0x8b } \
|
|
|
eb7fe6 |
+ }
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
+extern EFI_GUID gEdkiiPlatformHasDeviceTreeGuid;
|
|
|
eb7fe6 |
+
|
|
|
eb7fe6 |
+#endif
|
|
|
eb7fe6 |
--
|
|
|
eb7fe6 |
1.8.3.1
|
|
|
eb7fe6 |
|