This commit is here to remind about the importance of development environment.

While developing the FAT32 driver I realized the hd image that was supposedly FAT32 was actually a FAT12 drive. It took some pain to get a working disk drive with a FAT32 partition and Grub Legacy.

Here are the stes to create a FAT32 file system disk image that boots with grub legacy, for future reference:

1. Create the disk image:
% bximage -> flat hd, 100 megs

2. Partition it
% fdisk -u -C203 -S63 -H16 c.img, press -> o -> n -> a -> t 0C -> w

note geometry from fdisk:
c.img1   *        2048      204623      101288   83  W95 LBA

3. Format the disk image as FAT32 using the loopback device
losetup -o1048576 /dev/loop0 c.img # 1048576 equals to 2048*512
mkdosfs -F32 /dev/loop0
losetup -d /dev/loop0

4. Boot systemrescuecd or some other linux live cd together with newly created c.img. Install grub from there:
% mount /dev/sda1 /mnt
% grub-install --no-floppy --root-directory=/mnt /dev/sda

5. Copy a proper menu.lst and the kernel image to the disk image and you're done!