Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
BIOS
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Boot process === [[File:Legacy BIOS boot process fixed.png|thumb|493x493px|Boot process|none]] After the POST completes and, in a BIOS that supports option ROMs, after the option ROM scan is completed and all detected [[Read-only memory|ROM]] modules with valid [[Checksum|checksums]] have been called, the BIOS calls [[BIOS interrupt call#Interrupt table|interrupt 19h]] to start boot processing. Post-boot, programs loaded can also call interrupt 19h to reboot the system, but they must be careful to disable interrupts and other asynchronous hardware processes that may interfere with the BIOS rebooting process, or else the system may hang or crash while it is rebooting. When interrupt 19h is called, the BIOS attempts to locate [[boot loader]] software on a "boot device", such as a [[hard disk]], a [[floppy disk]], [[CD]], or [[DVD]]. It loads and executes the first boot [[software]] it finds, giving it control of the PC.<ref name="hsw1"/> The BIOS uses the boot devices set in [[Nonvolatile BIOS memory]] ([[CMOS]]), or, in the earliest PCs, [[DIP switch]]es. The BIOS checks each device in order to see if it is bootable by attempting to load the first sector ([[boot sector]]). If the sector cannot be read, the BIOS proceeds to the next device. If the sector is read successfully, some BIOSes will also check for the boot sector signature 0x55 0xAA in the last two bytes of the sector (which is 512 bytes long), before accepting a boot sector and considering the device bootable.{{efn|The signature at offset <code>+0x1FE</code> in boot sectors is <code>0x55 0xAA</code>, that is <code>0x55</code> at offset <code>+0x1FE</code> and <code>0xAA</code> at offset <code>+0x1FF</code>. Since [[little-endian]] representation must be assumed in the context of [[IBM PC–compatible]] compatible, this can be written as 16-bit word <code>0xAA55</code> in programs for [[Intel x86|x86]] processors (note the swapped order), whereas it would have to be written as <code>0x55AA</code> in programs for other CPU architectures using a [[big-endian]] representation. Since this has been mixed up numerous times in books and even in original Microsoft reference documents,<!-- one example of many: http://technet.microsoft.com/en-us/library/cc977219.aspx as of 2012-01-14 --> this article uses the offset-based byte-wise on-disk representation to avoid any possible misinterpretation.}} When a bootable device is found, the BIOS transfers control to the loaded sector. The BIOS does not interpret the contents of the boot sector other than to possibly check for the boot sector signature in the last two bytes. Interpretation of data structures like partition tables and BIOS Parameter Blocks is done by the boot program in the boot sector itself or by other programs loaded through the boot process. A non-disk device such as a [[network adapter]] attempts booting by a procedure that is defined by its [[option ROM]] or the equivalent integrated into the motherboard BIOS ROM. As such, option ROMs may also influence or supplant the boot process defined by the motherboard BIOS ROM. With the [[El Torito (CD-ROM standard)|El Torito optical media boot standard]], the optical drive actually emulates a 3.5" high-density floppy disk to the BIOS for boot purposes. Reading the "first sector" of a CD-ROM or DVD-ROM is not a simply defined operation like it is on a floppy disk or a hard disk. Furthermore, the complexity of the medium makes it difficult to write a useful boot program in one sector. The bootable virtual floppy disk can contain software that provides access to the optical medium in its native format. If an expansion ROM wishes to change the way the system boots (such as from a network device or a SCSI adapter) in a cooperative way, it can use the ''BIOS Boot Specification'' (BBS) [[API]] to register its ability to do so. Once the expansion ROMs have registered using the BBS APIs, the user can select among the available boot options from within the BIOS's user interface. This is why most BBS compliant PC BIOS implementations will not allow the user to enter the BIOS's user interface until the expansion ROMs have finished executing and registering themselves with the BBS API.{{Citation needed|date=October 2008}} Also, if an expansion ROM wishes to change the way the system boots unilaterally, it can simply hook interrupt 19h or other interrupts normally called from interrupt 19h, such as interrupt 13h, the BIOS disk service, to intercept the BIOS boot process. Then it can replace the BIOS boot process with one of its own, or it can merely modify the boot sequence by inserting its own boot actions into it, by preventing the BIOS from detecting certain devices as bootable, or both. Before the BIOS Boot Specification was promulgated, this was the only way for expansion ROMs to implement boot capability for devices not supported for booting by the native BIOS of the motherboard.{{Citation needed|date=October 2014}} ==== Boot priority ==== The user can select the boot priority implemented by the BIOS. For example, most computers have a hard disk that is bootable, but sometimes there is a removable-media drive that has higher boot priority, so the user can cause a removable disk to be booted. In most modern BIOSes, the boot priority order can be configured by the user. In older BIOSes, limited boot priority options are selectable; in the earliest BIOSes, a fixed priority scheme was implemented, with floppy disk drives first, fixed disks (i.e., hard disks) second, and typically no other boot devices supported, subject to modification of these rules by installed option ROMs. The BIOS in an early PC also usually would only boot from the first floppy disk drive or the first hard disk drive, even if there were two drives installed. ==== Boot failure ==== On the original [[IBM PC]] and XT, if no bootable disk was found, the BIOS would try to start [[IBM BASIC|ROM BASIC]] with the interrupt call to [[BIOS interrupt call#INT 18h: execute BASIC|interrupt 18h]]. Since few programs used BASIC in ROM, clone PC makers left it out; then a computer that failed to boot from a disk would display "No ROM BASIC" and halt (in response to interrupt 18h). Later computers would display a message like "No bootable disk found"; some would prompt for a disk to be inserted and a key to be pressed to retry the boot process. A modern BIOS may display nothing or may automatically enter the BIOS configuration utility when the boot process fails.
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
BIOS
(section)
Add topic