mirror of https://github.com/ipxe/ipxe.git
[efi] Add flattened device tree header and GUID definitions
Signed-off-by: Michael Brown <mcb30@ipxe.org>pull/1437/head
parent
ec8c5a5fbb
commit
f0caf90a72
|
@ -0,0 +1,24 @@
|
|||
/** @file
|
||||
*
|
||||
* Copyright (c) 2013-2014, ARM Limited. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||
*
|
||||
**/
|
||||
|
||||
#ifndef __FDT_H__
|
||||
#define __FDT_H__
|
||||
|
||||
FILE_LICENCE ( BSD2_PATENT );
|
||||
|
||||
#define FDT_TABLE_GUID \
|
||||
{ 0xb1b621d5, 0xf19c, 0x41a5, { 0x83, 0x0b, 0xd9, 0x15, 0x2c, 0x69, 0xaa, 0xe0 } }
|
||||
|
||||
extern EFI_GUID gFdtTableGuid;
|
||||
|
||||
#define FDT_VARIABLE_GUID \
|
||||
{ 0x25a4fd4a, 0x9703, 0x4ba9, { 0xa1, 0x90, 0xb7, 0xc8, 0x4e, 0xfb, 0x3e, 0x57 } }
|
||||
|
||||
extern EFI_GUID gFdtVariableGuid;
|
||||
|
||||
#endif /* __FDT_H__ */
|
|
@ -248,6 +248,7 @@ extern EFI_GUID efi_vlan_config_protocol_guid;
|
|||
|
||||
extern EFI_GUID efi_acpi_10_table_guid;
|
||||
extern EFI_GUID efi_acpi_20_table_guid;
|
||||
extern EFI_GUID efi_fdt_table_guid;
|
||||
extern EFI_GUID efi_smbios_table_guid;
|
||||
extern EFI_GUID efi_smbios2_table_guid;
|
||||
|
||||
|
|
|
@ -71,7 +71,7 @@ sub try_import_file {
|
|||
push @dependencies, $2;
|
||||
}
|
||||
# Check for BSD licence statement
|
||||
if ( /^\s*SPDX-License-Identifier: BSD-2-Clause-Patent$/ ) {
|
||||
if ( /\s*SPDX-License-Identifier: BSD-2-Clause-Patent$/ ) {
|
||||
die "Licence detected after header guard\n" if $guard;
|
||||
$licence = "BSD2_PATENT";
|
||||
}
|
||||
|
@ -119,7 +119,7 @@ my $edktop = shift;
|
|||
|
||||
# Identify edk import directories
|
||||
my $edkdirs = [ "MdePkg/Include", "MdeModulePkg/Include",
|
||||
"NetworkPkg/Include" ];
|
||||
"NetworkPkg/Include", "EmbeddedPkg/Include" ];
|
||||
foreach my $edkdir ( @$edkdirs ) {
|
||||
die "Directory \"$edktop\" does not appear to contain the EFI EDK2 "
|
||||
."(missing \"$edkdir\")\n" unless -d catdir ( $edktop, $edkdir );
|
||||
|
|
|
@ -25,8 +25,9 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
|||
|
||||
#include <string.h>
|
||||
#include <ipxe/fdt.h>
|
||||
#include <ipxe/efi/efi.h>
|
||||
#include <ipxe/init.h>
|
||||
#include <ipxe/efi/efi.h>
|
||||
#include <ipxe/efi/Guid/Fdt.h>
|
||||
|
||||
/** @file
|
||||
*
|
||||
|
@ -34,13 +35,9 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
|||
*
|
||||
*/
|
||||
|
||||
#define DEVICE_TREE_TABLE_GUID \
|
||||
{ 0xb1b621d5, 0xf19c, 0x41a5, \
|
||||
{ 0x83, 0x0b, 0xd9, 0x15, 0x2c, 0x69, 0xaa, 0xe0 } }
|
||||
|
||||
/** EFI Flattened Device Tree configuration table */
|
||||
static struct fdt_header *efi_fdt;
|
||||
EFI_USE_TABLE ( DEVICE_TREE_TABLE, &efi_fdt, 0 );
|
||||
EFI_USE_TABLE ( FDT_TABLE, &efi_fdt, 0 );
|
||||
|
||||
/**
|
||||
* Initialise EFI Flattened Device Tree
|
||||
|
|
|
@ -85,6 +85,7 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
|||
#include <ipxe/efi/Protocol/UsbIo.h>
|
||||
#include <ipxe/efi/Protocol/VlanConfig.h>
|
||||
#include <ipxe/efi/Guid/Acpi.h>
|
||||
#include <ipxe/efi/Guid/Fdt.h>
|
||||
#include <ipxe/efi/Guid/FileInfo.h>
|
||||
#include <ipxe/efi/Guid/FileSystemInfo.h>
|
||||
#include <ipxe/efi/Guid/GlobalVariable.h>
|
||||
|
@ -411,6 +412,10 @@ EFI_GUID efi_acpi_10_table_guid
|
|||
EFI_GUID efi_acpi_20_table_guid
|
||||
= EFI_ACPI_20_TABLE_GUID;
|
||||
|
||||
/** FDT table GUID */
|
||||
EFI_GUID efi_fdt_table_guid
|
||||
= FDT_TABLE_GUID;
|
||||
|
||||
/** SMBIOS table GUID */
|
||||
EFI_GUID efi_smbios_table_guid
|
||||
= SMBIOS_TABLE_GUID;
|
||||
|
@ -524,6 +529,8 @@ static struct efi_well_known_guid efi_well_known_guids[] = {
|
|||
"Dns6" },
|
||||
{ &efi_dns6_service_binding_protocol_guid,
|
||||
"Dns6Sb" },
|
||||
{ &efi_fdt_table_guid,
|
||||
"Fdt" },
|
||||
{ &efi_global_variable,
|
||||
"GlobalVar" },
|
||||
{ &efi_graphics_output_protocol_guid,
|
||||
|
|
Loading…
Reference in New Issue