summaryrefslogtreecommitdiffstats
path: root/src/include
diff options
context:
space:
mode:
authorMichael Brown2025-03-28 15:20:44 +0100
committerMichael Brown2025-03-28 16:29:53 +0100
commitb20f506a7217ce18f08ec007467365f9e118c445 (patch)
tree8f87d3d8da72a85485e689bf30022560b92f2088 /src/include
parent[fdt] Provide the ability to create a device tree for a booted OS (diff)
downloadipxe-b20f506a7217ce18f08ec007467365f9e118c445.tar.gz
ipxe-b20f506a7217ce18f08ec007467365f9e118c445.tar.xz
ipxe-b20f506a7217ce18f08ec007467365f9e118c445.zip
[efi] Install a device tree for the booted OS, if available
If we have a device tree available (e.g. because the user has explicitly downloaded a device tree using the "fdt" command), then provide it to the booted operating system as an EFI configuration table. Since x86 does not typically use device trees, we create weak symbols for efi_fdt_install() and efi_fdt_uninstall() to avoid dragging FDT support into all x86 UEFI binaries. Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/include')
-rw-r--r--src/include/ipxe/efi/efi_fdt.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/include/ipxe/efi/efi_fdt.h b/src/include/ipxe/efi/efi_fdt.h
new file mode 100644
index 000000000..a9b7eac8b
--- /dev/null
+++ b/src/include/ipxe/efi/efi_fdt.h
@@ -0,0 +1,17 @@
+#ifndef _IPXE_EFI_FDT_H
+#define _IPXE_EFI_FDT_H
+
+/** @file
+ *
+ * EFI Flattened Device Tree
+ *
+ */
+
+FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
+
+#include <ipxe/efi/efi.h>
+
+extern int efi_fdt_install ( void );
+extern int efi_fdt_uninstall ( void );
+
+#endif /* _IPXE_EFI_FDT_H */