[Soekris] Is anyone having trouble with 128MB CF's?

Soren Kristensen soren at soekris.com
Sat Jun 26 22:07:54 UTC 2004


Hi Gunner & List,

Gunnar Flygt wrote:
> I have great problems with getting some 128MB SanDisk CF's to work.
> When I load m0n0wall on them FreeBSD rightly detects the geometry,
> same as bios does, but it panics right after the detection of the
> disk during boot.

Installing an operating system image using dd (as you apperently do with 
m0n0wall) can cause complications on bigger CF modules, that probably 
what you're seeing.

A little info about booting CF modules using FreeBSD on net4xxx devices 
(might apply to other *nix's too...)

The comBIOS autodectect IDE devices and decide how to handle old style 
INT13 CHS BIOS calls based on:

A) If less than 1024 cylinders, use CHS directly, that usually happens 
on small CF modules, typically of 64M and less, nice and simple.

B) If 1024 cylinders or more, use LBA translation, happens at between 
64M and 512M depending of mfg and type, indicated by "Xlt" in the 
comBIOS IDE device info.

C) If the CF module supports LBA as most do, "LBA" is indicated in the 
comBIOS IDE device info.

D) The comBIOS support both old INT13 CHS and the new LBA bios calls, 
translating as needed depending of CF module geometry and capabilities.

For some reason FreeBSD's MBR (boot0) as default use CHS disk access for 
loading the next stage loader (boot1) on drives less than 2G or 
something, instead of automatically detecting LBA and use that if 
available. If it always used LBA if possible, there wouldn't be all 
these problems. It also seems clouded to me how FreeBSD decide on the 
geometry to use, but maybe I should look more into it.

So because of that you can't just dd an image and expect it to work. It 
often work on very small CF modules, as they're don't need translation, 
but bigger one gives complications....

So far I have always believed that those problems was avoided when 
installing using PXE, but least week I PXE installed a stock FreeBSD 
4.10 on a 1 Gbyte CF module, and it couldn't boot until I forced boot0 
to use LBA by:

# boot0cfg -B -o packet /dev/ad0

A quick experiment is to use the comBIOS builtin boot loader as that 
always use LBA:

 > boot :1


Best Regards,


Soren Kristensen




More information about the Soekris-tech mailing list