summaryrefslogtreecommitdiff
path: root/ArmPlatformPkg/Bds/BdsInternal.h
diff options
context:
space:
mode:
authorOlivier Martin <Olivier.Martin@arm.com>2015-07-14 14:41:46 +0000
committeroliviermartin <oliviermartin@Edk2>2015-07-14 14:41:46 +0000
commit5d9e9d1a1c0aac8d3a1f60be50b2f504dac8d761 (patch)
tree64ba48f5ab76bb7bea0e671473a0e6dffb17f34e /ArmPlatformPkg/Bds/BdsInternal.h
parenta81ccae41acfb4905d9b06c1f3223d43226c0152 (diff)
downloadedk2-platforms-5d9e9d1a1c0aac8d3a1f60be50b2f504dac8d761.tar.xz
ArmPlatformPkg/Bds: Added support for booting legacy kernel from BDS
When PcdBdsLinuxSupport is enabled, users can create boot entries for the legacy EFI Linux loader. The ARM BDS detects if the image is a EFI image if not then it assumes it is a legacy Linux kernel (a kernel without EFI Stub). If the Boot Manager did not manage to load the binary (it could happen when the binary is on the network or not present on the media yet). Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Olivier Martin <Olivier.Martin@arm.com> Reviewed-by: Ronald Cron <Ronald.Cron@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17974 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'ArmPlatformPkg/Bds/BdsInternal.h')
-rw-r--r--ArmPlatformPkg/Bds/BdsInternal.h26
1 files changed, 20 insertions, 6 deletions
diff --git a/ArmPlatformPkg/Bds/BdsInternal.h b/ArmPlatformPkg/Bds/BdsInternal.h
index fe4fd79289..ddf5308e8b 100644
--- a/ArmPlatformPkg/Bds/BdsInternal.h
+++ b/ArmPlatformPkg/Bds/BdsInternal.h
@@ -1,6 +1,6 @@
/** @file
*
-* Copyright (c) 2011-2014, ARM Limited. All rights reserved.
+* Copyright (c) 2011-2015, ARM Limited. All rights reserved.
*
* This program and the accompanying materials
* are licensed and made available under the terms and conditions of the BSD License
@@ -79,6 +79,12 @@ typedef struct _BDS_LOAD_OPTION_SUPPORT {
#define LOAD_OPTION_ENTRY_FROM_LINK(a) BASE_CR(a, BDS_LOAD_OPTION_ENTRY, Link)
#define LOAD_OPTION_FROM_LINK(a) ((BDS_LOAD_OPTION_ENTRY*)BASE_CR(a, BDS_LOAD_OPTION_ENTRY, Link))->BdsLoadOption
+// GUID of the EFI Linux Loader
+extern CONST EFI_GUID mLinuxLoaderAppGuid;
+
+// Device path of the EFI Linux Loader in the Firmware Volume
+extern EFI_DEVICE_PATH* mLinuxLoaderDevicePath;
+
EFI_STATUS
BootDeviceListSupportedInit (
IN OUT LIST_ENTRY *SupportedDeviceList
@@ -141,11 +147,6 @@ GetHIInputBoolean (
OUT BOOLEAN *Value
);
-BOOLEAN
-HasFilePathEfiExtension (
- IN CHAR16* FilePath
- );
-
EFI_DEVICE_PATH*
GetLastDevicePathNode (
IN EFI_DEVICE_PATH* DevicePath
@@ -260,4 +261,17 @@ EmptyCallbackFunction (
IN VOID *Context
);
+/**
+ * This function check if the DevicePath defines an EFI binary
+ *
+ * This function is used when the BDS support Linux loader to
+ * detect if the binary is an EFI application or potentially a
+ * Linux kernel.
+ */
+EFI_STATUS
+IsEfiBinary (
+ IN EFI_DEVICE_PATH* DevicePath,
+ OUT BOOLEAN *EfiBinary
+ );
+
#endif /* _BDSINTERNAL_H_ */