Re: Some notes on RootOnZFS article in wiki

From: James R. Van Artsdalen <james-freebsd-current_at_jrv.org>
Date: Tue, 22 Dec 2009 07:42:11 -0600
Dag-Erling Smørgrav wrote:
> Both of these are arguably poor design and / or sloppy implementation,
> but they are not bugs.  The BIOS performed just like its authors
> expected under the circumstances they had expected; they just hadn't
> anticipated the circumstances under which their code failed.
As a day job I wrote and architected PC-compatible BIOS for 15 years in
the 80's and 90's so I have some idea what works and what will break
things in a BIOS.

It definitely breaks things *when booting* to depend in any way on a
partition table since there may not be one.  By the mid 90's nearly
every OS was putting in at least dummy partition tables for the same
reason GPT does - to lessen the risk of accidental clobbering of the
disk - but that's just a convention.  I'm sure there are still a few
customized VAR-things out there that don't bother with a partition table.

A number of vendors have taken to putting "hidden" system partitions on
the disk with various utilities that can be run via a hotkey press
during POST.  These schemes have to use MBR-like code from the BIOS ROM
to boot their system partition and that pseudo-MBR must read and
interpret the partition table to find the system partition.  But during
system boot itself the MBR sector is read and if the last word in that
sector is 0xAA55 then the BIOS executes the MBR code blind as to what is
on the disk.  It's the MBR code that's read from the disk that scans the
partition table, if there is one.

There were attempts for a time to check for boot sector virii before
booting but those were always so problematic that I never did that, and
I don't the the other main BIOS teams did it either.

Someone probably decided to save space and consolidate the two BIOS boot
routines but forgot to bypass the partition table code in the INT 19 case.
Received on Tue Dec 22 2009 - 12:42:16 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:59 UTC