summaryrefslogtreecommitdiff
path: root/ArmPlatformPkg/Bds/Bds.c
diff options
context:
space:
mode:
authorOlivier Martin <Olivier.Martin@arm.com>2015-07-14 14:36:49 +0000
committeroliviermartin <oliviermartin@Edk2>2015-07-14 14:36:49 +0000
commit8b129b7b390107d258bd004eda8514976534408a (patch)
treeb159f5e50303feb398fff7b7ee15f899423217ec /ArmPlatformPkg/Bds/Bds.c
parentc75d3eb6be41867cc3bfea9f567bf20cdead8966 (diff)
downloadedk2-platforms-8b129b7b390107d258bd004eda8514976534408a.tar.xz
ArmPlatformPkg/Bds: Remove Linux specific boot path
Since the embedded Linux Loader has been removed from BdsLib there is no more Linux specific boot option. All the boot options are now expected to be arguments for EFI applications. 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@17970 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'ArmPlatformPkg/Bds/Bds.c')
-rw-r--r--ArmPlatformPkg/Bds/Bds.c36
1 files changed, 3 insertions, 33 deletions
diff --git a/ArmPlatformPkg/Bds/Bds.c b/ArmPlatformPkg/Bds/Bds.c
index 1fab43976f..3ee866c9f2 100644
--- a/ArmPlatformPkg/Bds/Bds.c
+++ b/ArmPlatformPkg/Bds/Bds.c
@@ -220,12 +220,6 @@ DefineDefaultBootEntries (
EFI_STATUS Status;
EFI_DEVICE_PATH_FROM_TEXT_PROTOCOL* EfiDevicePathFromTextProtocol;
EFI_DEVICE_PATH* BootDevicePath;
- UINT8* OptionalData;
- UINTN OptionalDataSize;
- ARM_BDS_LOADER_ARGUMENTS* BootArguments;
- ARM_BDS_LOADER_TYPE BootType;
- EFI_DEVICE_PATH* InitrdPath;
- UINTN InitrdSize;
UINTN CmdLineSize;
UINTN CmdLineAsciiSize;
CHAR16* DefaultBootArgument;
@@ -269,8 +263,6 @@ DefineDefaultBootEntries (
// Create the entry is the Default values are correct
if (BootDevicePath != NULL) {
- BootType = (ARM_BDS_LOADER_TYPE)PcdGet32 (PcdDefaultBootType);
-
// We do not support NULL pointer
ASSERT (PcdGetPtr (PcdDefaultBootArgument) != NULL);
@@ -308,33 +300,11 @@ DefineDefaultBootEntries (
AsciiStrToUnicodeStr (AsciiDefaultBootArgument, DefaultBootArgument);
}
- if ((BootType == BDS_LOADER_KERNEL_LINUX_ATAG) || (BootType == BDS_LOADER_KERNEL_LINUX_FDT)) {
- InitrdPath = EfiDevicePathFromTextProtocol->ConvertTextToDevicePath ((CHAR16*)PcdGetPtr(PcdDefaultBootInitrdPath));
- InitrdSize = GetDevicePathSize (InitrdPath);
-
- OptionalDataSize = sizeof(ARM_BDS_LOADER_ARGUMENTS) + CmdLineAsciiSize + InitrdSize;
- BootArguments = (ARM_BDS_LOADER_ARGUMENTS*)AllocatePool (OptionalDataSize);
- if (BootArguments == NULL) {
- return EFI_OUT_OF_RESOURCES;
- }
- BootArguments->LinuxArguments.CmdLineSize = CmdLineAsciiSize;
- BootArguments->LinuxArguments.InitrdSize = InitrdSize;
-
- CopyMem ((VOID*)(BootArguments + 1), AsciiDefaultBootArgument, CmdLineAsciiSize);
- CopyMem ((VOID*)((UINTN)(BootArguments + 1) + CmdLineAsciiSize), InitrdPath, InitrdSize);
-
- OptionalData = (UINT8*)BootArguments;
- } else {
- OptionalData = (UINT8*)DefaultBootArgument;
- OptionalDataSize = CmdLineSize;
- }
-
BootOptionCreate (LOAD_OPTION_ACTIVE | LOAD_OPTION_CATEGORY_BOOT,
- (CHAR16*)PcdGetPtr(PcdDefaultBootDescription),
+ (CHAR16*)PcdGetPtr (PcdDefaultBootDescription),
BootDevicePath,
- BootType,
- OptionalData,
- OptionalDataSize,
+ (UINT8 *)DefaultBootArgument, // OptionalData
+ CmdLineSize, // OptionalDataSize
&BdsLoadOption
);
FreePool (BdsLoadOption);