From: Simon Schubert Date: Fri, 16 Jan 2009 01:25:16 +0000 (+0100) Subject: mbr: enable packet mode by default X-Git-Tag: v2.3.0~31^2~2 X-Git-Url: https://gitweb.dragonflybsd.org/dragonfly.git/commitdiff_plain/74911cecaa8285bfba6653bc1f070a2c9b6725a9 mbr: enable packet mode by default Make mbr always use packet mode if supported. Define AVOID_PACKET_MODE to only use packet mode if necessary. --- diff --git a/sys/boot/pc32/mbr/mbr.S b/sys/boot/pc32/mbr/mbr.S index 58ba8bfca5..e0ba45bc87 100644 --- a/sys/boot/pc32/mbr/mbr.S +++ b/sys/boot/pc32/mbr/mbr.S @@ -92,10 +92,12 @@ main.5: movw %sp,%di /* Save stack pointer */ movb 0x1(%si),%dh /* Load head */ movw 0x2(%si),%cx /* Load cylinder:sector */ movw $LOAD,%bx /* Transfer buffer */ +#ifdef AVOID_PACKET_MODE cmpb $0xff,%dh /* Might we need to use LBA? */ jnz main.7 /* No. */ cmpw $0xffff,%cx /* Do we need to use LBA? */ jnz main.7 /* No. */ +#endif pushw %cx /* Save %cx */ pushw %bx /* Save %bx */ movw $0x55aa,%bx /* Magic */