summaryrefslogtreecommitdiff
path: root/sys/arch/i386
diff options
context:
space:
mode:
authorTobias Weingartner <weingart@cvs.openbsd.org>1997-08-08 22:46:14 +0000
committerTobias Weingartner <weingart@cvs.openbsd.org>1997-08-08 22:46:14 +0000
commit1dd63a139a62d2e3f73a0c504617201c5543cf9b (patch)
tree01ba3c1818f8502f99271ba212e852799b42e5a3 /sys/arch/i386
parent9ea96ed5f54d283c1c44fcb21098926d2b535d27 (diff)
Sync up
Diffstat (limited to 'sys/arch/i386')
-rw-r--r--sys/arch/i386/stand/mbr/mbr.S50
1 files changed, 18 insertions, 32 deletions
diff --git a/sys/arch/i386/stand/mbr/mbr.S b/sys/arch/i386/stand/mbr/mbr.S
index 128ceb8a7b2..08e9f567555 100644
--- a/sys/arch/i386/stand/mbr/mbr.S
+++ b/sys/arch/i386/stand/mbr/mbr.S
@@ -1,4 +1,4 @@
-/* $OpenBSD: mbr.S,v 1.6 1997/08/08 17:13:13 weingart Exp $ */
+/* $OpenBSD: mbr.S,v 1.7 1997/08/08 22:46:13 weingart Exp $ */
/*
* Copyright (c) 1997 Michael Shalayeff and Tobias Weingartner
@@ -207,43 +207,21 @@ err_stop:
found:
DBGMSG(CHAR_B)
#if 0
- pushl %edx
- pushl %esi
- pushl %ecx
-
- /* Print out drive and partition */
- data32
- movl $drive, %esi
- data32
- call message
-
+ pushl %ax
+ /* Save drive and partition */
movl %dx, %ax
andl $0x0F, %ax
orl $0x30, %ax
- data32
- call chr
-
- data32
- movl $partn, %esi
- data32
- call message
+ movb %al, adrive
- popl %eax
+ movl %cx, %ax
decl %ax
xor $0x03, %ax
andl $0x0F, %ax
orl $0x30, %ax
- data32
- call chr
-
- data32
- movl $newln, %esi
- data32
- call message
+ movb %al, aprtn
- /* Restore %esi and %edx */
- popl %esi
- popl %edx
+ popl %ax
#endif
/* Load values from active partition table entry */
@@ -280,6 +258,12 @@ found:
1:
DBGMSG(CHAR_G)
+#if 1
+ data32
+ movl $info, %esi
+ data32
+ call message
+#endif
# jump to the new code (%ds:%si is at he right point)
data32
@@ -343,9 +327,11 @@ message:
ret
/* Info messages */
-drive: .asciz "Using Drive: "
-partn: .asciz " Partition: "
-newln: .asciz "\r\n"
+info: .ascii "Using Drive: "
+adrive: .byte 'X'
+ .ascii " Partition: "
+aprtn: .byte 'Y'
+ .asciz "\r\n"
/* Error messages */
fdmbr: .asciz "MBR on floppy or old BIOS\r\n"