[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Extending flash-kernel to support KuroBox Pro



* Per Andersson <avtobiff@gmail.com> [2008-06-09 08:50]:
> +	# KuroBox Pro
> +	"MV-88fxx81")

This is what the default kernel in the Kurobox Pro uses, but the
mainline kernel from kernel.org (and hence the Debian kernel) will use
something different.  The script has to work with the Debian kernel,
not with the original kernel (which we will replace).

The string is: Buffalo/Revogear Kurobox Pro

> +		check_subarch "orion5x"
> +		check_mtd
> +		kmtd=$(mtdblock uImage)
> +		if [ -z "$kmtd" ]; then
> +			error "Cannot find mtd partition 'uImage'"
> +		fi
> +		kmtdsize=$(mtdsize "uImage")
> +		check_size "uImage" $(($kfilesize + 8 + 64)) $kmtdsize
> +		printf "Generating kernel u-boot image... " >&2
> +		tmp=$(tempfile)
> +		devio > $tmp 'wl 0xe3a01c05,4' 'wl 0xe38110e5,4'

ok, that's the right machine id.

> +		cat $kfile >> $tmp
> +		mkimage -A arm -O linux -T kernel -C none -a 0x00008000 \
> +			-e 0x00008000 -n "$desc" -d $tmp $tmp.uboot >&2 1>/dev/null

You have to check what address the Kurobox actually uses.  When you
connect the serial console and load the default kernel, you'll see the
values.

> +		echo "done." >&2
> +		printf "Flashing kernel... " >&2
> +		cat $tmp.uboot > $kmtd || error "failed."
> +		echo "done." >&2
> +		rm -f $tmp.uboot $tmp
> +	;;

So you flash the kernel but not the ramdisk.  You'll also have to
figure out how the ramdisk should be written to flash (in particular,
in which format).  See the previous mail I sent you about this.

-- 
Martin Michlmayr
http://www.cyrius.com/


Reply to: