mbr.S: fix loading from logical partitions
authorH. Peter Anvin <hpa@zytor.com>
Wed, 14 Nov 2007 23:01:28 +0000 (15:01 -0800)
committerH. Peter Anvin <hpa@zytor.com>
Wed, 14 Nov 2007 23:01:28 +0000 (15:01 -0800)
Fix loading from logical partitions (a push/pop pair was not done in
reverse order.)

mbr/mbr.S

index 2a318be..63622d9 100644 (file)
--- a/mbr/mbr.S
+++ b/mbr/mbr.S
@@ -207,8 +207,8 @@ scan_partition_table:
        jns     too_many_active
 
        /* No active partitions found, look for extended partitions */
-       popw    %bx             /* %bx <- ptab */
        popw    %cx             /* %cx <- 4    */
+       popw    %bx             /* %bx <- ptab */
 7:
        movb    4(%bx), %al
        cmpb    $0x0f, %al      /* 0x0f = Win9x extended */