summaryrefslogtreecommitdiff
path: root/DuetPkg/CreateBootDisk.sh
diff options
context:
space:
mode:
authoreric_tian <eric_tian@6f19259b-4bc3-4df7-8a09-765794883524>2010-01-19 08:28:28 +0000
committereric_tian <eric_tian@6f19259b-4bc3-4df7-8a09-765794883524>2010-01-19 08:28:28 +0000
commite843cdd7d9ed9e72e0df61f46e5a073a0797615e (patch)
tree6a74c4f5488988289007ad6875a0add39f21464f /DuetPkg/CreateBootDisk.sh
parent1ccdbf2a3e61fe9494fcd39432107ba0eb74f584 (diff)
downloadedk2-platforms-e843cdd7d9ed9e72e0df61f46e5a073a0797615e.tar.xz
1. update bat file to generate right bootia32.efi/bootx64.efi file according to command line parameters.
2. fix a print error in which a %x in format string exists but the corresponding variable argument is not present! 3. fix CONSUME_MEMORY too small issue. In X64 arch, cpu may cause the paging table is too big and beyond the pei memory scope between EfiMemoryTop and EfimemoryBottom. for example, a cpu support 44bits addressing memory space may occupied ~64M paging table. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9794 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'DuetPkg/CreateBootDisk.sh')
-rwxr-xr-xDuetPkg/CreateBootDisk.sh46
1 files changed, 37 insertions, 9 deletions
diff --git a/DuetPkg/CreateBootDisk.sh b/DuetPkg/CreateBootDisk.sh
index fb54a31b0d..bfe1abd83e 100755
--- a/DuetPkg/CreateBootDisk.sh
+++ b/DuetPkg/CreateBootDisk.sh
@@ -14,8 +14,8 @@ if [ \
"$*" = "--help" \
]
then
- echo "Usage: CreateBootDisk [usb|floppy|ide] MediaPath DevicePath [FAT12|FAT16|FAT32]"
- echo "e.g. : CreateBootDisk floppy /media/floppy0 /dev/fd0 FAT12 "
+ echo "Usage: CreateBootDisk [usb|floppy|ide] MediaPath DevicePath [FAT12|FAT16|FAT32] [IA32|X64]"
+ echo "e.g. : CreateBootDisk floppy /media/floppy0 /dev/fd0 FAT12 IA32"
PROCESS_MARK=FALSE
fi
@@ -44,9 +44,17 @@ then
mkdir -p $EFI_BOOT_MEDIA/efi
mkdir -p $EFI_BOOT_MEDIA/efi/boot
-
- cp $WORKSPACE/EdkShellBinPkg/MinimumShell/Ia32/Shell.efi $EFI_BOOT_MEDIA/efi/boot/bootia32.efi
-
+ if [ "$5" = IA32 ]
+ then
+ cp $WORKSPACE/EdkShellBinPkg/MinimumShell/Ia32/Shell.efi $EFI_BOOT_MEDIA/efi/boot/bootia32.efi
+ else
+ if [ "$5" = X64 ]
+ then
+ cp $WORKSPACE/EdkShellBinPkg/MinimumShell/X64/Shell.efi $EFI_BOOT_MEDIA/efi/boot/bootx64.efi
+ else
+ echo Wrong Arch!
+ fi
+ fi
echo Done.
else
echo "Wrong FAT type $4 for floppy!"
@@ -73,11 +81,21 @@ then
if [ "$4" = FAT16 ]
then
- if [ "$5" = step2 ]
+ if [ "$6" = step2 ]
then
cp $BUILD_DIR/FV/Efildr16 $EFI_BOOT_MEDIA
mkdir $EFI_BOOT_MEDIA/efi/boot
- cp $WORKSPACE/EdkShellBinPkg/MinimumShell/ia32/Shell.efi $EFI_BOOT_MEDIA/efi/boot/bootia32.efi
+ if [ "$5" = IA32 ]
+ then
+ cp $WORKSPACE/EdkShellBinPkg/MinimumShell/Ia32/Shell.efi $EFI_BOOT_MEDIA/efi/boot/bootia32.efi
+ else
+ if [ "$5" = X64 ]
+ then
+ cp $WORKSPACE/EdkShellBinPkg/MinimumShell/X64/Shell.efi $EFI_BOOT_MEDIA/efi/boot/bootx64.efi
+ else
+ echo Wrong Arch!
+ fi
+ fi
echo "step2 Done!"
else
echo Format $EFI_BOOT_DEVICE ...
@@ -93,11 +111,21 @@ then
fi
elif [ "$4" = FAT32 ]
then
- if [ "$5" = step2 ]
+ if [ "$6" = step2 ]
then
cp $BUILD_DIR/FV/Efildr20 $EFI_BOOT_MEDIA
mkdir $EFI_BOOT_MEDIA/efi/boot
- cp $WORKSPACE/EdkShellBinPkg/MinimumShell/ia32/Shell.efi $EFI_BOOT_MEDIA/efi/boot/bootia32.efi
+ if [ "$5" = IA32 ]
+ then
+ cp $WORKSPACE/EdkShellBinPkg/MinimumShell/Ia32/Shell.efi $EFI_BOOT_MEDIA/efi/boot/bootia32.efi
+ else
+ if [ "$5" = X64 ]
+ then
+ cp $WORKSPACE/EdkShellBinPkg/MinimumShell/X64/Shell.efi $EFI_BOOT_MEDIA/efi/boot/bootx64.efi
+ else
+ echo Wrong Arch!
+ fi
+ fi
echo "step2 Done!"
else
echo Format $EFI_BOOT_DEVICE ...