On Sun, Aug 7, 2011 at 9:29 AM, Hermann Gottschalk <[email protected]> wrote:
> Hi,
> i installed voyage 0.7.5 via PXE on a soekris 4501 and after the first
> reboot, the system could not mount the rootfs an felt into initramfs.
>
> I figured out that the problem ist, that the ide_generic module is not
> loaded in the initrd.
>
> So my workaround:
>

heres another way to do it.

patch adds a BOOTARGS line to etc/voyage-profile/4801.pro
and alters setboot.sh to add it to the boot-configs.
This approach makes kernel-boot args customizable per board.
I didnt add a line for your board, but it would be close to that for
the net4801.
Id appreciate it if you try it out, and tune the BOOTARGS accordingly.

For the 4801, I found that ide_core.nodma was the critical option.
Ive got 2 CFs, one appears as hda, other as hdb, so I added =0.0, =0.1.
all_generic_ide doesnt fix the boot w/o the former.  But I added it anyway.



> After having installed voyage like described here
> http://linux.voyage.hk/content/getting-started-pxe-boot-v07x and BEFORE
> the first reboot mount /dev/hda1 again on /tmp/cf (rw), then chroot to
> /tmp/cf.
>
> $ mount /dev/hda1 /tmp/cf
> $ chroot /tmp/cf
>
> Here edit /etc/initramfs-tools/modules in adding 'ide_generic'. Then do
> a update-initramfs -u (don't worry about the absense of the mtab-file
> which is complained).
>
> $ update-initramfs -u
>
> Now do the first reboot and the soekris should boot.
>
> Greetings
> Hermann
>
> --
> Hermann Gottschalk
> [email protected]
> PGP 0x0B2D8EEA --- www.openbsd.org
>
> _______________________________________________
> Voyage-linux mailing list
> [email protected]
> http://list.voyage.hk/mailman/listinfo/voyage-linux
>
From 863ea3d2db9dfbe8e8ba478f88be46b05d41dfb9 Mon Sep 17 00:00:00 2001
From: Jim Cromie <[email protected]>
Date: Fri, 19 Aug 2011 10:52:05 -0600
Subject: [PATCH 2/3] add BOOTARGS to grub and lilo configs

add BOOTARGS="all_generic_ide ide_core.nodma=0.0 ide_core.nodma=0.1"
to 4801.pro(file), and change setboot.sh to add it to the boot configs.

The soekris needs the nodma to boot, I have 2 CFs that appear as
hda, hdb, so I added both.  all_generic_ide doesnt seem to matter,
but I added it due to received wisdom.
---
 etc/voyage-profiles/4801.pro     |    4 ++++
 usr/local/sbin/setboot.sh        |   10 +++++++---
 usr/local/sbin/voyage-install.sh |    4 ++++
 3 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/etc/voyage-profiles/4801.pro b/etc/voyage-profiles/4801.pro
index 1606ee2..fde550c 100755
--- a/etc/voyage-profiles/4801.pro
+++ b/etc/voyage-profiles/4801.pro
@@ -3,3 +3,7 @@ VOYAGE_SYSTEM_CONSOLE=serial
 VOYAGE_SYSTEM_SERIAL=19200
 VOYAGE_SYSTEM_PCMCIA=no
 VOYAGE_SYSTEM_MODULES="wd1100 sysctl_wd_graceful=0 sysctl_wd_timeout=30; scx200_acb base=0x810,0x820; pc87360 init=2; pc8736x_gpio; scx200_hrt; scx200_gpio"
+
+# net4801 doesnt work with DMA, despite kernel thinking so
+# my 2 CFs appear as hda, hdb, so suppress DMA for both
+BOOTARGS="all_generic_ide ide_core.nodma=0.0 ide_core.nodma=0.1"
diff --git a/usr/local/sbin/setboot.sh b/usr/local/sbin/setboot.sh
index 95b9bf5..16ab483 100755
--- a/usr/local/sbin/setboot.sh
+++ b/usr/local/sbin/setboot.sh
@@ -47,13 +47,13 @@ image=/vmlinuz
 	label=Linux
 	initrd=/initrd.img
 	read-only
-	append="root=LABEL=ROOT_FS ${serapp}reboot=bios"
+	append="root=LABEL=ROOT_FS ${serapp}reboot=bios" ${BOOTARGS}"
 
 image=/vmlinuz.old
 	label=LinuxOLD
 	initrd=/initrd.img.old
 	read-only
-	append="root=LABEL=ROOT_FS ${serapp}reboot=bios"
+	append="root=LABEL=ROOT_FS ${serapp}reboot=bios" ${BOOTARGS}"
 	optional
 EOM
 	sed -e "/disk =/d;/bios =/d" -e "s#${TARGET_DISK}#/dev/hda#" \
@@ -192,7 +192,7 @@ EOM
 
 title voyage-linux-$datestr
 root (hd0,$(($TARGET_PART-1)))
-kernel /vmlinuz root=LABEL=ROOT_FS ${console}
+kernel /vmlinuz root=LABEL=ROOT_FS ${console} ${BOOTARGS}
 ${VOYAGE_INITRD}
 
 EOM
@@ -211,6 +211,10 @@ EOM
 		select_target_boot
 	fi
 
+	if [ -n "$BOOTARGS" ]; then
+		echo "adding bootargs: $BOOTARGS"
+	fi
+
 	if [ $SYSTEM_BOOTSTRAP == lilo ]; then
 		echo "Installing lilo"
 		make_lilo_conf
diff --git a/usr/local/sbin/voyage-install.sh b/usr/local/sbin/voyage-install.sh
index 9c492ed..051b5af 100755
--- a/usr/local/sbin/voyage-install.sh
+++ b/usr/local/sbin/voyage-install.sh
@@ -15,6 +15,10 @@ set -a
 
 CONFIGFILE=.voyage-install.conf
 
+if [ "$BOOTARGS" != "" ]; then
+	echo "adding bootargs: $BOOTARGS"
+fi
+
 #
 #	Function select_target_disk
 #	Sets the environment variables TARGET_DISK, TARGET_PART
-- 
1.7.4.4

_______________________________________________
Voyage-linux mailing list
[email protected]
http://list.voyage.hk/mailman/listinfo/voyage-linux

Reply via email to