diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1996-09-25 12:27:02 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1996-09-25 12:27:02 +0000 |
commit | 60acbc220237566e9da2f6c79d66e944b6e8face (patch) | |
tree | 2d72bcaed79cdb818fffe5f10be4329fce91b1ef /sys/arch/i386/boot/start.S | |
parent | 9fc54e0a08eee1d79d1bfc0070c83b56af072791 (diff) |
prefer DOSPTYP_386BSD MBR partition; from tholo
Diffstat (limited to 'sys/arch/i386/boot/start.S')
-rw-r--r-- | sys/arch/i386/boot/start.S | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/sys/arch/i386/boot/start.S b/sys/arch/i386/boot/start.S index 288c75326ad..dfb383cc2de 100644 --- a/sys/arch/i386/boot/start.S +++ b/sys/arch/i386/boot/start.S @@ -62,7 +62,8 @@ LOADSZ = 15 # size of unix boot PARTSTART = 0x1be # starting address of partition table NUMPART = 4 # number of partitions in partition table PARTSZ = 16 # each partition table entry is 16 bytes -BSDPART = 0xA5 # value of boot_ind, means bootable partition +BSDPART = 0xA6 # OpenBSD partition identification +OLDBSDPART = 0xA5 # 386/Net/FreeBSD partition identification BOOTABLE = 0x80 # value of boot_ind, means bootable partition .text @@ -179,6 +180,16 @@ again: addl $PARTSZ, %ebx data32 loop again +again2: + addr32 + movb %es:4(%ebx), %al + cmpb $OLDBSDPART, %al + data32 + je found + data32 + addl $PARTSZ, %ebx + data32 + loop again2 data32 movl $enoboot, %esi data32 @@ -378,6 +389,7 @@ endofcode: /* throw in a partition in case we are block0 as well */ /* flag, head, sec, cyl, typ, ehead, esect, ecyl, start, len */ . = _C_LABEL(boot1) + PARTSTART +startoflabel: .byte 0x0,0,0,0,0,0,0,0 .long 0,0 .byte 0x0,0,0,0,0,0,0,0 |