Thursday, February 4, 2010

UEFI - An Introduction

Intro:-

In the beginning, there was BIOS (I assume reader knows what BIOS is, if not known wait for an upcoming post on BIOS). Back in those times, processors were running in 16-bit mode, and RAM was architecturally limited to 1 megabyte. As the evolution went forth, came 32-bit, and later 64-bit x86 CPUs, amount of RAM was increasing, and new ways of accessing it were being developed. But BIOS remained same. This situation was far from ideal, since BIOS code was very limited, and operating system loader had to load kernel just with using the most basic BIOS services, from 20 years ago. Creating new standard seemed impossible on such diverse market. But it was done anyway.


History:-

It all has begun when Intel decided to develop 64-bit CPU. They made decision which was very good logically, but unfortunately not as good market-wise: to get rid of all ancient x86 features, drop entire x86 backward portability, and create completely new CPU architecture, named Itanium (IA64). That also meant that old BIOSes won't be running on it, and so opportunity opened for new standard interface between OS and hardware/firmware. The converse also has to be true hence the initial EFI would not run on IA32 architectures and befores, the support was added later. This is how first steps took place, to replace BIOS by new standard, called Extended Firmware Interface (EFI).

The EFI was a proprietary of Intel and other market players in Industry like AMD, Phillips have to come up with their own. In order to avoid new branches in the BIOS technology and to Keep EFI as sole replacement for BIOS all big market players joined hands and this how a forum was born known as UEFI Forum - http://www.uefi.org/ in 2005. The Forum is solely responsible for EFI development and promotion.

UEFI - Universal Extensible Firmware Interface.

Present:-

The OSes that support Itanium processors support UEFI booting. The OSes in market for 64 bit processors support UEFI booting. for Linux the bootloaders LILO and GRUB support UEFI booting for Itanium processors from Intel, also for X86-64 - the Itanium's placeholder from AMD.

Future:-

Does this mean "bye bye" to BIOS and "Hello" to UEFI? Yes, when it is 64 bit processors it has to be UEFI. Like the evolution happened from 8 Bit processors to 16 Bit processors and then to 32 Bit processors and since the 64 Bit processors are the next things, the days of BIOS are numbered. For the people from embedded industry like me the question that poses is does this also impact the way booting happens in embedded systems, the answer is yes if the processor is 64 Bit but it is rarely possible to have such a high performance processor unless the requirement strongly recommends.

Conclusion:-

What was the necessity to shift from BIOS paradigm to UEFI?

The design constraints the make BIOS difficult are:

  1. BIOS is 16 bit based while the processors are evolved to 64 bit.
  2. BIOS presents limitation to the option ROM's execution space, making it difficult to have support for bootable device on servers both in terms of executable image size and the number of devices.
  3. BIOS depends on legacy PC-AT architecture interrupt routing and timer handling, posing difficulties with independence in designing server hardware.

Still more can be identified, the above are just few of them. The advantages of having UEFI are as follows:

  1. It is a standard in the industry and is open source.
  2. Simplicity in incorporating the new hardware, all it takes is adding new driver into the device driver model of UEFI. I think of Uboot here, since it is also open source embedded developer have contributed with configurations for various hadwares, the new hardware would be just like adding new config file for that hardware/processor.
  3. Customization is also simpler.

With all this said and done, I am signing off to the introduction of UEFI. Lets take "Getting Started with UEFI" in my next post.