mbr: enable packet mode by default
authorSimon Schubert <corecode@dragonflybsd.org>
Fri, 16 Jan 2009 01:25:16 +0000 (02:25 +0100)
committerSimon Schubert <corecode@dragonflybsd.org>
Fri, 16 Jan 2009 01:27:02 +0000 (02:27 +0100)
Make mbr always use packet mode if supported.
Define AVOID_PACKET_MODE to only use packet mode if necessary.

sys/boot/pc32/mbr/mbr.S

index 58ba8bf..e0ba45b 100644 (file)
@@ -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 */