VirtualBox

Changeset 5263 in vbox for trunk/src/VBox/Devices/PC


Ignore:
Timestamp:
Oct 12, 2007 3:43:33 PM (17 years ago)
Author:
vboxsync
Message:

drop the whole bootchk bit if it's not supposed to be used.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/PC/BIOS/rombios.c

    r5206 r5263  
    40024002#ifdef VBOX
    40034003  case 0x89:
    4004     // Switch to Protected Mode. 
     4004    // Switch to Protected Mode.
    40054005    // ES:DI points to user-supplied GDT
    40064006    // BH/BL contains starting interrupt numbers for PIC0/PIC1
     
    79777977  Bit8u  bootlan;
    79787978#endif /* VBOX */
     7979#ifndef VBOX
    79797980  Bit8u  bootchk;
     7981#endif /* !VBOX */
    79807982  Bit16u bootseg;
    79817983  Bit16u status;
     
    81748176    }
    81758177
    8176   // check signature if instructed by cmos reg 0x38, only for floppy
    8177   // bootchk = 1 : signature check disabled
    8178   // bootchk = 0 : signature check enabled
    8179   if (bootdrv != 0) bootchk = 0;
    81808178#ifdef VBOX
    8181   // Don't check boot sectors on floppies and don't read CMOS - byte 
     8179  // Don't check boot sectors on floppies and don't read CMOS - byte
    81828180  // 0x38 in CMOS always has the low bit clear.
    81838181  // There is *no* requirement whatsoever for a valid boot sector to
     
    81878185  // in one of the first few bytes, absence of long sequences of identical
    81888186  // bytes at the start or beginning or boot sector etc.
    8189   // The risk of attempting to boot an invalid floppy is low, certainly 
     8187  // The risk of attempting to boot an invalid floppy is low, certainly
    81908188  // lower than the risk of refusing to boot a valid floppy.
    8191   bootchk = 1;
    8192 #else
     8189#else /* !VBOX */
     8190  // check signature if instructed by cmos reg 0x38, only for floppy
     8191  // bootchk = 1 : signature check disabled
     8192  // bootchk = 0 : signature check enabled
     8193  if (bootdrv != 0) bootchk = 0;
    81938194  else bootchk = inb_cmos(0x38) & 0x01;
    8194 #endif
    81958195
    81968196#if BX_ELTORITO_BOOT
     
    82108210      }
    82118211    }
     8212#endif /* !VBOX */
    82128213
    82138214#if BX_ELTORITO_BOOT
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette