- Timestamp:
- Jan 18, 2007 5:41:16 PM (18 years ago)
- Location:
- trunk/src/VBox/Devices/PC
- Files:
-
- 3 edited
-
BIOS/logo.c (modified) (1 diff)
-
BIOS/rombios.c (modified) (1 diff)
-
DevPcBios.cpp (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/PC/BIOS/logo.c
r1 r155 1097 1097 return; 1098 1098 } 1099 1100 1101 void delay_boot(secs) 1102 Bit16u secs; 1103 { 1104 Bit16u i; 1105 1106 if (!secs) 1107 return; 1108 1109 // Set PIT to 1ms ticks 1110 wait_init(); 1111 1112 printf("Delaying boot for %d seconds:", secs); 1113 for (i = secs; i > 0; i--) 1114 { 1115 printf(" %d", i); 1116 wait(1000); 1117 } 1118 printf("\n"); 1119 // Restore PIT ticks 1120 wait_uninit(); 1121 } 1122 -
trunk/src/VBox/Devices/PC/BIOS/rombios.c
r100 r155 7818 7818 if (read_byte(ebda_seg, &EbdaData->uForceBootDrive)) 7819 7819 bootseq = read_byte(ebda_seg, &EbdaData->uForceBootDrive); 7820 /* Boot delay hack. */ 7821 if (bseqnr == 1) 7822 delay_boot((inb_cmos(0x3c) & 0xf0) >> 4); /* Implemented in logo.c */ 7820 7823 #endif /* VBOX */ 7821 7824 -
trunk/src/VBox/Devices/PC/DevPcBios.cpp
r31 r155 93 93 /** The DMI tables. */ 94 94 uint8_t au8DMIPage[0x1000]; 95 95 /** The boot countdown (in seconds). */ 96 uint8_t uBootDelay; 96 97 } DEVPCBIOS, *PDEVPCBIOS; 97 98 … … 316 317 uint8_t reg38 = /* pcbiosCmosRead(pDevIns, 0x38) | */ getBiosBootCode(pData, 2) << 4; 317 318 /* This is an extension. Bochs BIOS normally supports only 3 boot devices. */ 318 uint8_t reg3c = /* pcbiosCmosRead(pDevIns, 0x3c) | */ getBiosBootCode(pData, 3);319 uint8_t reg3c = getBiosBootCode(pData, 3) | (pData->uBootDelay << 4); 319 320 pcbiosCmosWrite(pDevIns, 0x3d, reg3d); 320 321 pcbiosCmosWrite(pDevIns, 0x38, reg38); … … 873 874 "LogoTime\0" 874 875 "LogoFile\0" 875 "ShowBootMenu\0")) 876 "ShowBootMenu\0" 877 "DelayBoot\0")) 876 878 return PDMDEV_SET_ERROR(pDevIns, VERR_PDM_DEVINS_UNKNOWN_CFG_VALUES, 877 879 N_("Invalid configuraton for device pcbios device")); … … 1173 1175 if (pu8LanBoot) 1174 1176 rc = PDMDevHlpROMRegister(pDevIns, VBOX_LANBOOT_SEG << 4, cbFileLanBoot, pu8LanBoot, "Net Boot ROM"); 1177 1178 rc = CFGMR3QueryU8(pCfgHandle, "DelayBoot", &pData->uBootDelay); 1179 if (rc == VERR_CFGM_VALUE_NOT_FOUND) 1180 { 1181 pData->uBootDelay = 0; 1182 rc = VINF_SUCCESS; 1183 } 1184 else 1185 { 1186 if (VBOX_FAILURE(rc)) 1187 return PDMDEV_SET_ERROR(pDevIns, rc, 1188 N_("Configuration error: Querying \"DelayBoot\" as integer failed")); 1189 if (pData->uBootDelay > 15) 1190 pData->uBootDelay = 15; 1191 } 1175 1192 1176 1193 return rc;
Note:
See TracChangeset
for help on using the changeset viewer.

