aboutsummaryrefslogtreecommitdiffstats
path: root/mbr/gptmbr.S
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2009-04-04 15:32:24 -0700
committerH. Peter Anvin <hpa@zytor.com>2009-04-04 15:32:24 -0700
commitf7b5a2254ab7c8aa87679c1b731d2ea285c22e80 (patch)
tree08e1e00576717e1ca557101164b7e6639e0172a1 /mbr/gptmbr.S
parentdd51053bbd4a1613d1e3384928a7da7bb164562f (diff)
downloadsyslinux-f7b5a2254ab7c8aa87679c1b731d2ea285c22e80.tar.gz
syslinux-f7b5a2254ab7c8aa87679c1b731d2ea285c22e80.tar.xz
syslinux-f7b5a2254ab7c8aa87679c1b731d2ea285c22e80.zip
mbr: generate normal versions, force-80 versions, and ctrl-80 versions
Produce MBR variants with normal (DL) behavior, force to drive 80 behavior, and force to 80 on Ctrl pressed behavior. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'mbr/gptmbr.S')
-rw-r--r--mbr/gptmbr.S13
1 files changed, 6 insertions, 7 deletions
diff --git a/mbr/gptmbr.S b/mbr/gptmbr.S
index 6df67f42..8d42e8b8 100644
--- a/mbr/gptmbr.S
+++ b/mbr/gptmbr.S
@@ -26,6 +26,8 @@
*
* ----------------------------------------------------------------------- */
+#include "adjust.h"
+
.code16
.text
@@ -74,11 +76,8 @@ _start:
ljmpw $0, $next
next:
- /* Escape for the user: if Ctrl is pressed, assume drive hd0 */
- testb $0x04, BIOS_kbdflags /* Ctrl pressed */
- jz 1f
- movb $0x80, %dl
-1:
+
+ ADJUST_DRIVE
pushw %dx /* 0(%bp) = %dl -> drive number */
/* Check to see if we have EBIOS */
@@ -170,10 +169,10 @@ find_part:
found_part:
xchgw %ax,%cx /* Set up %cx for rep movsb further down */
-
+
movw $dssi_out,%di
pushw %di
-
+
/* 80 00 00 00 ee 00 00 00
- bootable partition, type EFI (EE), no CHS information */
xorl %eax,%eax