Skip to contentSkip to conversation

boot from diskonchip millenium

DISCUSSION Glen 2 participants 6 messages Aug 5, 2002 – Aug 6, 2002 Memory technology devices (MTD)

lore
Share & tools
lore

Glen

author
#0 lore raw

I'm having trouble finding a solution to boot from the diskonchip millenium.
The available grub patches seem to do absolutely nothing useful, and the only lilo references I can find assume you are using msys's software.

If someone can point me in the right direction, I would appreciate it.

-g

#1 lore raw
Quoted 1 line · Glen

The available grub patches seem to do absolutely nothing useful,

Interesting. Are there any messages on screen during the system boot?

Are there any errors in compiling and setting up the bootloader as explained in README_DiskOnChip? The latter file can be seen only after applying the patch, sorry.

Have you tried the --enable-diskonchip-biosnetboot configuration parameter and toggled the BIOS network boot option?

Quoted 2 lines

the only lilo references I can find assume you are using msys's software.

One has to implement a simple BIOS INT 13h interface. I guess you can re-use the GRUB MTD firmware open source code including its bdev_diskonchip.c NFTL driver.

Once this is done, you would erase all /dev/mtd0 blocks preceding the NFTL layer and run lilo against /dev/mtd0 so that it can install itself and the list of filesystem block numbers relative to device /dev/nftla. These numbers are persistent. This is unlike to locations of flash erase blocks abstracted by the NFTL layer.

Ilguiz

author
#2 lore raw

Well, I've gotten a bit farther.
Since I would prefer grub, we'll go that route.

For description, we'll say I have the mtd-source in /mtd and grub in /grub-0.92.

First, I compiled grub with --enable-diskonchip-mil, --enable-ext2fs, and --enable-vfat

# cp /grub-0.92/stage2/pre_stage2 /mtd/grub
# /mtd/util/doc_loadbios /dev/mtd/0 /mtd/grub/grub_firmware  

This didn't seem to present any results, as the bios didn't recognize a bootloader at all.

Then I tried running doc_loadbios with the grub_firmware generated from within /grub-0.92/stage1.

Now the bios recognizes and runs the boot loader, but it can't seem to read my diskonchip filesystem.

I've been loosely following the directions at:
http://lists.infradead.org/pipermail/linux-mtd/2001-October/003475.html

I'm a bit confused.
What's the difference between the grub_firmware generated by grub and grub_firmware generated by mtd?

-g

First, I tried loading the grub_firmware that was generated from <mtd source>/grub.

Quoted 34 lines · Ilguiz Latypov
Quoted 1 line · Glen

The available grub patches seem to do absolutely nothing useful,

Interesting. Are there any messages on screen during the system boot?

Are there any errors in compiling and setting up the bootloader as explained in README_DiskOnChip? The latter file can be seen only after applying the patch, sorry.

Have you tried the --enable-diskonchip-biosnetboot configuration parameter and toggled the BIOS network boot option?

Quoted 2 lines

the only lilo references I can find assume you are using msys's software.

One has to implement a simple BIOS INT 13h interface. I guess you can re-use the GRUB MTD firmware open source code including its bdev_diskonchip.c NFTL driver.

Once this is done, you would erase all /dev/mtd0 blocks preceding the NFTL layer and run lilo against /dev/mtd0 so that it can install itself and the list of filesystem block numbers relative to device /dev/nftla. These numbers are persistent. This is unlike to locations of flash erase blocks abstracted by the NFTL layer.

Ilguiz

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

#3 lore raw
Quoted 2 lines · Glen

Now the bios recognizes and runs the boot loader, but it can't seem to read my diskonchip filesystem.

Great, now on to the next step: what are the informational and error messages? Have you set up an NFTL layer on the chip? Perhaps, you are trying to install JFFS2 not NFTL? Can you mount a flash filesystem when booted from hard disk? What is the content of your menu.lst file?

Quoted 2 lines

I've been loosely following the directions at:
http://lists.infradead.org/pipermail/linux-mtd/2001-October/003475.html

There is a newer instruction at

http://lists.infradead.org/pipermail/linux-mtd/2002-June/005240.html

Quoted 2 lines

What's the difference between the grub_firmware generated by grub and grub_firmware generated by mtd?

I believe the original patch to GRUB worked only with DoC 2000.

Ilguiz

author
#4 lore raw

Ok.
When the machine boots up, several lines scroll by...unfortunately too fast for me to see.

Then, about 50 lines scroll that say:
Attempting to open /boot/grub/menu.lst 0x0 0x0
Attempting to open /boot/grub/menu.lst 0x0 0x1
Attempting to open /boot/grub/menu.lst 0x0 0x2
...and so on...

I then get a grub> prompt

"grub> geometry" reports:
Error 11: Unrecognized device string

"grub> root" reports:
(dc0): Filesystem type unknown, using whole disk

I am using nftl_format to prepare the DOC (I don't even know what jffs2 is at this point).
The command used was nftl_format /dev/mtd/0 98304
After the nftl_format, I fdisk, format the partition, mount it, and copy the kernel and grub conf.

I've tried using both ext2 and vfat filesystems, with the same results.

/boot/grub/menu.lst (on the DOC) is as follows:

default 0
timeout 5
title DOC Linux

	kernel (dc0,0)/boot/vmlinuz-2.4.18 root=/dev/nftl/disc0/part1

I've also tried:

default 0
timeout 5
title DOC Linux

	kernel (dc0,0)/boot/vmlinuz-2.4.18 root=/dev/nftla1

and:

default 0
timeout 5
title DOC Linux

	kernel (dc0)/boot/vmlinuz-2.4.18 root=/dev/nftl/disc0/part1

Ideas??

-g

Quoted 30 lines · Ilguiz Latypov
Quoted 2 lines · Glen

Now the bios recognizes and runs the boot loader, but it can't seem to read my diskonchip filesystem.

Great, now on to the next step: what are the informational and error messages? Have you set up an NFTL layer on the chip? Perhaps, you are trying to install JFFS2 not NFTL? Can you mount a flash filesystem when booted from hard disk? What is the content of your menu.lst file?

Quoted 2 lines

I've been loosely following the directions at:
http://lists.infradead.org/pipermail/linux-mtd/2001-October/003475.html

There is a newer instruction at

   http://lists.infradead.org/pipermail/linux-mtd/2002-June/005240.html
Quoted 2 lines

What's the difference between the grub_firmware generated by grub and grub_firmware generated by mtd?

I believe the original patch to GRUB worked only with DoC 2000.

Ilguiz

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

#5 lore raw
Quoted 2 lines · Glen

Attempting to open /boot/grub/menu.lst 0x0 0x0
Attempting to open /boot/grub/menu.lst 0x0 0x1

I believe there were attempts to open configuration file on disk 0xe0 (DiskOnChip fake BIOS drive number just for the GRUB's internal BIOS disk access API). This always happens when the grub_firmware was compiled by running aclocal/autoconf/automake commands from README_DiskOnChip and specifying the --enable-diskonchip-mil option. [The latest patches are 0.92 and 2002-07-29].

Quoted 1 line

Ideas??

If you created a partition within NFTL layer, the "root (dc0,0)" command would be worth trying.

Ilguiz