Compatibility with older computers

Top  Previous  Next

Ideally, all computers should support LBA interface for accessing boot USB storage devices, present bootable USB thumbdrive as first storage device, and provide full access to all its data, without remapping and shifting sectors in firmware.

 

But unfortunately, many real world BIOSes, especially on older computers, have bugs and quirks in implementation of this interface for USB boot devices. For specific formatting scenarios (related to Windows XP and DOS), when compatibility with older computers really matters, FlashBoot goes great length to take care of these issues by installing special stage1 and stage2 loaders.

 

Sometimes disk CHS geometry is different from BIOS to BIOS. E.g., when formatted on the workstation, the USB disk sometimes is not bootable on the embedded hardware because of different CHS geometry on Windows and under embedded BIOS.

FlashBoot allows to specify disk CHS geometry explicitly at format time, and stage2 loader will force it to predefined values at run time.

Some BIOSes cut off MBR track from USB disk when booting (especially for A:-mapped boots). E.g., they map only partition 1 of USB disk via int 13h.

FlashBoot stage2 loader emulates MBR track in such cases, thus hiding firmware diversity and avoiding OS confusion when it switches to native hardware drivers to access USB disk.

Some BIOSes provide int 13h extended API for USB disks, some do not. Some BIOSes do not provide these services in USB-ZIP mode, but provide ones in USB-HDD mode.

To unify runtime environment, FlashBoot stage2 loader always provides LBA and CHS disk access to USB device it boots from.

When BIOS boots from ordinary, non-FlashBoot formatted USB disk, this disk is mapped to A: or C: at BIOS discretion, quite randomly. In the majority of real world cases USB-ZIP formatted disks are mapped to A: and USB-HDD disks are mapped to C:.

 

But there are some exceptions.

 

For example, ASUS P5GDC-V BIOS in Auto mode maps 0-512Mb USB disks to A: and 512+ Mb disks to C:.

 

ASUS P6T BIOS in Auto mode maps 0-1024Mb USB disks to A: and 1024+ Mb disks to C:.

 

ASUS netbooks show similar behavior, but unfortunately there is no setting in their BIOS setups to override such "Auto mode" when choice between A: / C: is made by BIOS depending on disk size

All this diversity is no more a problem for FlashBoot user. When formatting USB disk, you'll be able to specify target drive letter, e.g. A: or C:, and stage2 loader of FlashBoot will take care of this problem at run time.

 

At boot time, stage1 and stage2 loaders execute the following algorithm:

 

1) Stage1 loader loads stage2 loader via CHS or LBA interface in slow (single-sector transfer) mode and verifies its checksum. If something does wrong at this step, then the following error message is displayed:

 

Boot from USB disk failed, status <000000000>.

Press Ctrl+Alt+Del to reboot.

 

Each status digit corresponds to certain BIOS disk.

 

  x x x x x x x x x

  | | | | | | | | |

  | | | | | | | | +----- Status digit of boot disk DL

  | | | | | | | +------- Status digit of disk 0x80

  | | | | | | +--------- Status digit of disk 0

  | | | | | +----------- Status digit of disk 0x81

  | | | | +------------- Status digit of disk 1

  | | | +--------------- Status digit of disk 0x82

  | | +----------------- Status digit of disk 2

  | +------------------- Status digit of disk 0x83

  +--------------------- Status digit of disk 3

 

Meaning of each status digit:

 

0

No single sector of stage2 loader was read from disk, neither in CHS nor in LBA mode

1

Should not happen (internal error in stage1 loader)

2

Some sectors of stage2 loader were read from disk in LBA mode, but not all.

No single sector could be read from disk in CHS mode.

3

All sectors of stage2 loader were read from disk in LBA mode,

but checksum or signature does not mach the expected one.

4

Some sectors of stage2 loader were read from disk in CHS mode, but not all.

No single sector could be read from disk in LBA mode.

5

All sectors of stage2 loader were read from disk in CHS mode,

but checksum or signature does not mach the expected one.

6

Some sectors of stage2 loader were read from disk in LBA mode, but not all.

Some sectors of stage2 loader were read from disk in CHS mode, but not all.

7

Some sectors of stage2 loader were read from disk in LBA mode,

some other sectors of stage2 loader were read from disk in CHS mode,

but checksum or signature does not mach the expected one.

 

2) FlashBoot stage2 loader tries to read first 128 sectors of the File Allocation Table via CHS and LBA interfaces. If either fails, stage2 loader switches to single-sector transfer mode and retries. If that interface fails again, stage2 loader prints "LBA not available" or "CHS not available". If LBA was unavailable in stage1, it is not tried here again, then only CHS is tried.

 

3) If both interfaces have failed, stage2 loader prints "Press Ctrl+Alt+Del to reboot" and softly halts machine.

 

4) Once FAT#1 and FAT#2 is loaded into the memory via CHS and/or LBA, stage2 loader compares FAT#1 versus FAT#2 to verify each BIOS interface. If FAT#1 does not match FAT#2 for LBA-originated data, stage2 loader prints "FAT#1 != FAT#2 for LBA on this BIOS". If FAT#1 does not match FAT#2 for CHS-originated data, FlashBoot prints "FAT#1 != FAT#2 for CHS on this BIOS".

 

5) If both interfaces have failed, stage2 loader prints "Press Ctrl+Alt+Del to reboot" and softly halts machine.

 

6) stage2 loader chooses LBA if available, otherwise it falls back to CHS. Then it prints either "LBA mode" or "CHS mode". If single-sector transfer mode is active, it adds " (slow)".

 

7) If BIOS hides MBR track, then stage2 loader prints the following message:

BIOS hides MBR track of USB boot disk (emulating)