Mailinglist Archive: opensuse-arm (74 mails)

< Previous Next >
Re: [opensuse-arm] Reboot on Pandaboard
Hi,

I think I can't boot with root on LVM w/o initrd in uboot.
How can I generate a new initrd, before reboot?

Ah, right, lvm root. Marcus patched mkinitrd to get it working with arm/uboot.

Marcus, mind to post your patch here? :)

no problem, attached :-)

Have fun

Regards,
Marcus
--
Public Key available
gpg --keyserver gpg-keyserver.de --recv-keys 0xCCE3C6A2
-------------------------------------------------------
Marcus Schäfer (Res. & Dev.) SUSE LINUX Products GmbH
Tel: 0911-740 53 0 Maxfeldstrasse 5
FAX: 0911-740 53 479 D-90409 Nürnberg
GF: Jeff Hawn,Jennifer Guild, Felix Imendörffer
HRB: 21284 (AG Nürnberg) Germany
http://www.suse.de
-------------------------------------------------------
--- sbin/mkinitrd 2012-02-04 14:38:32.000000000 +0100
+++ sbin/mkinitrd 2012-02-14 10:56:08.000000000 +0100
@@ -155,6 +155,9 @@
i386|x86_64)
regex='vmlinuz'
;;
+ arm*)
+ regex='uImage'
+ ;;
*) regex='vmlinu.'
;;
esac
@@ -178,6 +181,11 @@
[ "${kernel_image%%.gz}" != "$kernel_image" ] && continue
kernel_version=$(/sbin/get_kernel_version \
/boot/$kernel_image 2> /dev/null)
+ if [ -z "$kernel_version" ];then
+ kernel_image_gz=${kernel_image//uImage/vmlinux}.gz
+ kernel_version=$(/sbin/get_kernel_version \
+ /boot/$kernel_image_gz 2> /dev/null)
+ fi
initrd_image=$(echo $kernel_image | sed -e "s|${regex}|initrd|")
if [ "$kernel_image" != "$initrd_image" -a \
-n "$kernel_version" -a \
--- scripts/setup-prepare.sh 2012-02-01 17:18:20.000000000 +0100
+++ scripts/setup-prepare.sh 2012-02-14 10:56:27.000000000 +0100
@@ -114,6 +114,10 @@
fi

kernel_version=$(/sbin/get_kernel_version $kernel_image)
+if [ -z "$kernel_version" ];then
+ kernel_image_gz=${kernel_image//uImage/vmlinux}.gz
+ kernel_version=$(/sbin/get_kernel_version $kernel_image_gz)
+fi
modules_dir=$root_dir/lib/modules/$kernel_version

#echo -e "Kernel version:\t$kernel_version"
--- scripts/setup-done.sh 2012-02-01 17:18:20.000000000 +0100
+++ scripts/setup-done.sh 2012-02-14 10:55:56.000000000 +0100
@@ -17,6 +17,14 @@
then
oops 8 "Failed to build initrd"
fi
+
+arch=$(uname -i)
+if [[ $arch =~ arm ]];then
+ mkimage -A arm -O linux -T ramdisk -C none -a 0x0 -e 0x0 \
+ -n 'Initrd' -d $tmp_initrd $tmp_initrd.uboot
+ rm -f $tmp_initrd
+ tmp_initrd=$tmp_initrd.uboot
+fi
popd > /dev/null 2>&1
if ! cp -f $tmp_initrd $initrd_image ; then
oops 8 "Failed to install initrd"
< Previous Next >
Follow Ups