Show Mobile Navigation

Saturday, October 08, 2016

, , ,

Why Must A Computer Have A BIOS?

Oyetoke Tobi - Saturday, October 08, 2016

BIOS is simply the abbreviation for Basic Input Output System. It does more functions than the name suggests. People might think that BIOS controls input and output system only. But in reality the BIOS does much more and it is impossible for any operating system to continue without a proper BIOS in place. 

The BIOS software is built into the PC, and it is the first code run by a PC when powered on ('boot firmware'). When the PC starts up, the first job for the BIOS is the power-on self-test, which initializes and identifies system devices such as the CPU, RAM, video display card, keyboard and mouse, hard disk drive, optical disc drive and other hardware.

The BIOS then locates boot loader software held on a peripheral device (designated as a 'boot device'), such as a hard disk or a CD/DVD, and loads and executes that software, giving it control of the PC.

BIOS is a hardware dependent piece of code stored on the motherboard itself. Every different motherboard needs a custom BIOS written for it, so it would be impossible to have a generic BIOS/OS all-in-one (although the BIOS is technically just stored code, so you could theoretically write an OS for one particular motherboard).

Note that you can still start a computer without any external storage - which is why the BIOS is a requirement for a computer. In other terms, the BIOS provides a common software interface to allow a stored computer program to communicate with various hardware devices connected to the motherboard.

It should be noted that the BIOS is also used to make modifications to the computer hardware configurations, and store them in the on-board EEPROM (so your computer remembers the changes next time you start it up). 

Operating system is located on the hard disk, if a computer is being turned on, it won't magically start reading from that hard disk. It is the BIOS that loads the boot loader from the hard disk, as well as do some testing and allowing the user to configure certain settings of the BIOS.

The OS can't do that because it is on the hard disk and not in the ROM.

BIOS is also a firmware, in a simple manner. It is stored on a chip on a part of the computer motherboard and is basically, a set of instructions that run to help load the operating system. Operating System would fail to load, if not for the BIOS!

Hence, you need a BIOS on an Operating System.

The BIOS is usually developed by a hardware manufacturer. The hardware has to make sure, that a basic functionality is present, for example that a disk drive can be read from and that a basic display for diagnostics and errors is shown. Thus the name "Basic Input Output System".

This can be done, to some extent, without further knowledge of the actual components really present on the specific system, since they all have to support a certain small BIOS standard. This enables vendors to custom-build a complete system. The BIOS just has to do enough to start the OS. There are some conventions to where this start-points are, so it just tries one after the other. This also enables the use of different operating systems on the same hardware. (there is flexibility, again)

Once the operation system (or at least it's bootloader) ist found and started by the BIOS, the BIOS itself becomes largely obsolete. Modern OS use very little to nothing of the BIOS functionalitly after loading.

If you wanted to make the OS do all the work you'd have to put the OS in a place where it can be accessed by the hardware without the preliminary help of a software (ROM). This may be possible for some closed systems, where flexibility is no concern. If you think about building hardware support into some other hardware, you're basically building a kind of BIOS again...

If a CPU had the ability to address a hard drive directly, without relying on BIOS, or EFI or other code in ROM (or NVRAM or what have you), then in theory such a CPU could load an OS from disk into RAM and begin executing it.

Actually, in theory, such a CPU could even execute instructions without loading them to RAM. There is no theoretical reason that a computer couldn't use a hard drive as primary storage. But this would be very, very slow.

This would mean having extra code in the CPU to access the disk, and hard-wiring some concepts about disks, like partition tables and file systems into the CPU. CPUs these days are big enough to do this, but it would not be a very flexible or efficient approach to designing a CPU.

Bios does the below functions which has to executed while the system is being turned on

It checks the CMOS Setup for custom settings.
It enumerates the RAM by checking each compartment to see if all of them are working.
It loads the interrupt handlers and device drivers.
It initializes registers and power management
It performs the power-on self-test (POST).
Bios determines which devices are bootable.
It initiates the bootstrap sequence.
It checks for bootstraps on the devices in the order you or the machine vendor configured the BIOS.
It passes reigns of the computer to operating system by loading the essential parts of the OS into the random access memory (RAM) reserved for the OS, after bootstrap is located.


3 comments:

  1. Without a BIOS system, computer can not boot. Computer experts and companies are trying to build better version or alternative of BIOS. Lets see when we will be able to see it. web application development company

    ReplyDelete