BIOS 3/20/2016 1 Objectives • In this chapter, you will: -Learn to define the BIOS and understand how it relates to CMOS -Learn how to determine which BIOS is running on a PC -Identify and explain the key types of BIOS -Perform a BIOS upgrade -Open and manipulate the BIOS Setup 3/20/2016 2 BIOS Basics • BIOS is a term that stands for basic input/output system. BIOS is really the link between hardware and software in a system. Most people know the term BIOS by another name device drivers, or just drivers. • What can be confusing is that some of the BIOS is burned or flashed into a ROM chip that is both nonvolatile (it doesn't get erased when the power is turned off) and read-only. • The BIOS also includes ROM chips installed on adapter cards, as well as all the additional drivers loaded when your system boots up. 3/20/2016 3 BIOS • • • • • In IBM PC Compatible computers, the Basic Input/Output System (BIOS) , also known as the System BIOS. The BIOS is boot firmware, designed to be the first code run by a PC when powered on. The initial function of the BIOS is to identify, test, and initialize system devices such as the video display card, hard disk, and floppy disk and other hardware. This is to prepare the machine into a known state, so that software stored on compatible media can be loaded, executed, and given control of the PC. This process is known as booting, or booting up, which is short for bootstrapping. BIOS programs are stored on a chip and are built to work with various devices that make up the complementary chipset of the system. They provide a small library of basic input/output functions that can be called to operate and control the peripherals such as the keyboard, text display functions and so forth. 3/20/2016 4 BIOS Basics • The combination of the motherboard BIOS, the adapter card BIOS, and the device drivers loaded from disk contribute to the BIOS as a whole. • The portion of the BIOS contained in ROM chips both on the motherboard and in some adapter cards is sometimes called firmware, which is a name given to software stored in chips rather than on disk. 3/20/2016 5 BIOS Basics • In principle, the BIOS in ROM was customized to the particular manufacturer's hardware, allowing low-level services (such as reading a keystroke or writing a sector of data to diskette) to be provided in a standardized way to the operating system. • For example, an IBM PC might have had either a monochrome or a color display adapter, using different display memory addresses and hardware - but the BIOS service to print a character on the screen in text mode would be the same. 3/20/2016 6 BIOS Hardware/Software • The BIOS in a PC comes from three possible sources: -Motherboard ROM -Adapter card ROM (such as that found on a video card) -Loaded into RAM from disk (device drivers) • The motherboard ROM BIOS is most often associated with hardware rather than software. This is because the BIOS on the motherboard is contained in a ROM chip on the board, which contains the initial software drivers needed to get the system running. • The motherboard BIOS usually includes drivers for all the basic system components, including the keyboard, floppy drive, hard drive, serial and parallel ports, and more. • As systems became more complex, new hardware was added for which no motherboard BIOS drivers existed. These included devices such as newer video adapters, CD-ROM drives, SCSI hard disks, USB ports, and so on. 3/20/2016 7 BIOS Hardware/Software • Rather than requiring a new motherboard BIOS that would specifically support the new devices, it was far simpler and more practical to copy any new drivers that were necessary onto the system hard disk and configure the operating system to load them at boot time. • Some drivers must be active during boot time. For example, how could you boot from a hard disk if the drivers necessary to make the disk interface work must be loaded from that disk? • Computer manufactures designed the motherboard ROM to scan the slots looking for adapter cards with ROMs on them. • If a card was found with a ROM on it, the ROM was executed during the initial system startup phase, before the system began loading the operating system from the hard disk. 3/20/2016 8 BIOS Hardware/Software • By putting the ROM-based drivers right on the card, you didn't have to change your motherboard ROM to have built-in support for new devices. A few cards (adapter boards) almost always have a ROM onboard, including the following: -Video cards. All have an onboard BIOS. -SCSI adapters. Those that support booting from SCSI hard drives or CDROMs have an onboard BIOS. -Network cards. Those that support booting directly from a file server have what is usually called a boot ROM or IPL (initial program load) ROM onboard. This enables PCs to be configured on a LAN as diskless workstations-also called Net PCs, NCs (network computers), or even smart terminals. -IDE or floppy upgrade boards. Boards that enable you to attach more or different types of drives than what is normally supported by the motherboard alone. -Y2K boards. Boards that incorporate BIOS fixes to update the century byte in the CMOS RAM. 3/20/2016 9 BIOS and CMOS RAM • Some people confuse BIOS with the CMOS RAM in a system. This confusion is aided by the fact that the Setup program in the BIOS is used to set and store the configuration settings in the CMOS RAM. They are, in fact, two totally separate components. • The BIOS on the motherboard is stored in a fixed ROM chip. Also on the motherboard is a chip called the RTC/NVRAM chip, which stands for real-time clock/nonvolatile memory. • Although it is called nonvolatile, it is actually volatile, meaning that without power, the time/date settings and the data in the RAM portion will, in fact, be erased. • It is called nonvolatile because it is designed using complementary metal-oxide semiconductor (CMOS) technology, which results in a chip that runs on very little power. 3/20/2016 10 BIOS and CMOS RAM • A battery in the system, rather than the AC wall current, provides that power. • This is also why most people incorrectly call this chip the CMOS RAM chip; although not technically accurate, that is easier to say than the RTC/NVRAM chip. • When you enter your BIOS Setup, configure your hard disk parameters or other BIOS Setup settings and save them, these settings are written to the storage area in the RTC/NVRAM (otherwise called CMOS RAM) chip. Every time your system boots up, it reads the parameters stored in the CMOS RAM chip to determine how the system should be configured. • A relationship exists between the BIOS and CMOS RAM, but they are two distinctly different parts of the system. 3/20/2016 11 Motherboard BIOS The BIOS is a collection of programs embedded in one or more chips, depending on the design of your computer. That collection of programs is the first thing loaded when you start your computer, even before the operating system. Simply put, the BIOS in most PCs has four main functions: -POST (power on self test). The POST tests your computer's processor, memory, chipset, video adapter, disk controllers, disk drives, keyboard, and other crucial components. -Setup. System configuration and setup program. This is usually a menu-driven program activated by pressing a special key during the POST, which enables you to configure the motherboard and chipset settings along with the date and time, passwords, disk drives, and other basic system settings. -Bootstrap loader. A routine that reads the disk drives looking for a valid master boot sector. This master boot sector program then continues the boot process by loading an operating system boot sector, which then loads the operating system core files. -BIOS (basic input/output system). This refers to the collection of actual drivers used to act as a basic interface between the operating system and your hardware when the system is booted and running. 3/20/2016 12 Shadow ROM • ROM holds the BIOS, POST, and the program to boot the drives. • ROM has a much longer access time than RAM, slowing down the system. • If, on boot up, the ROM is copied into RAM, the system now can access this fast RAM that is shadowing the slow ROM, considerable speeding up the overall system operation System BIOS shadowed Video BIOS shadowed 3/20/2016 13 ROM (Read-Only Memory) Characteristics: – ROM chips contain vital, permanently stored information written to them by the manufacturer. – ROM is nonvolatile in that the information remains stored regardless of whether an electrical current is present. – ROM is non-changeable in that it can’t be written over, only read from. – This is why it’s called read-only chip. Information on a ROM chip never changes. If an error occurs on the chip, it must be replaced. 3/20/2016 14 Programmable ROM Formal name for a ROM chip that can’t be modified is mask ROM (from the chip’s manufacturing mask). PROM Chip Hybrid ROM chips: • PROM: Programmable ROM chips require a special type of machine called a “PROM programmer” or “Prom burner” and can be changed one time. The chip is shipped blank, and the programmer “burns in” specific instructions. From that point, chip can’t be changed. • EPROM: Erasable Programmable ROM chips use the PROM burner, but can be erased by shining ultraviolet (UV) light through a window in the top of the chip. EPROM Chip 3/20/2016 15 EEPROM Chip • EEPROM: Electrically erasable programmable ROM chips can be erased by an electrical charge and written to using slightly higherthan-normal voltage. Can be erased one byte at a time, rather than the entire chip. • Flash ROM: Also called flash RAM or flash memory. Stores data much like EEPROM but use a super-voltage charge to erase a block data (rather than a byte). • Most systems today use Flash memory. Flash is truly nonvolatile memory that is rewriteable, enabling users to easily update the ROM or firmware in their motherboards or any other components such as video cards, SCSI cards, peripherals, and so on. 3/20/2016 16 CMOS RAM (RTC/NVRAM ) A special chip combining a Real-Time Clock (RTC) and at least 64 bytes of Non-Volatile RAM (NVRAM) In Pentium class computers, it consumes a portion of Stores configuration the Super I/O Chip settings Original AT CMOS •Referred to as CMOS because it is on a Complementary Metal Oxide Semiconductor •Eliminates the need for jumpers and switches used for the configuration 3/20/2016 17 PnP (Plug ‘n’ Play) • Workable auto configuration process involving more than only the operating system. • Auto configurations is where the computer tries to interpret any new adapter card on the expansion bus and then to integrate the peripheral. • Once configured, PnP operating system will assign various system resources. • PnP involves intercommunication between the hardware devices in the system and operating system that controls how they work together. • Three aspects of PnP: – PnP compatible hardware. – PnP BIOS. – PnP operating system. (Win 95, Win NT5, OS/2) 3/20/2016 18 Virus attacks • There was at least one virus which was able to erase Flash ROM BIOS content, rendering computer systems unusable. CIH, also known as "Chernobyl Virus", affected systems BIOS and often they could not be fixed on their own since they were no longer able to boot at all. • To repair this, Flash ROM IC had to be ejected from the motherboard to be reprogrammed somewhere else. Damage from the CIH virus was possible since most motherboards at the time of CIH propagation used the same chip set, Intel TX, and most common operating systems such as Windows 95 allowed direct hardware access to all programs. 3/20/2016 19 ROM BIOS STARTS POST ROM BIOS 1. Check all hardware 2. Run Boot Program 3. Read Boot Record With instructions from ROM BIOS CPU tests all Hardware Components. After all components pass POST the system beeps once. 4. Load IO.SYS 3/20/2016 20 FIND BOOT RECORD ROM BIOS 1. Check all hardware ROM BIOS Instructs CPU to look for the Boot Record 2. Run Boot Program 3. Read Boot Record 4. Load IO.SYS 3/20/2016 21 LOAD BOOT RECORD ROM BIOS 1. Check all hardware 2. Run Boot Program 3. Read Boot Record 4. Load IO.SYS 3/20/2016 22 LOAD IO.SYS ROM BIOS 1. Check all hardware 2. Run Boot Program 3. Read Boot Record 4. Load IO.SYS 3/20/2016 23