mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Alexander Kurz <akurz@blala.de>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: barebox@lists.infradead.org
Subject: Re: [RFC / PATCH]: Add support for Kindle3
Date: Sat, 9 Jul 2016 16:04:47 +0200 (CEST)	[thread overview]
Message-ID: <alpine.DEB.2.00.1607091529130.31760@blala.de> (raw)
In-Reply-To: <20160707064745.GV20657@pengutronix.de>



On Thu, 7 Jul 2016, Sascha Hauer wrote:
> > +
> > +echo -n "Hit any key to stop autoboot: "
> > +timeout -a $global.autoboot_timeout
> > +if [ $? != 0 ]; then
> > +	echo
> > +	echo
> > +	exit
> > +fi
> > +
> > +boot
> > diff --git a/arch/arm/boards/kindle3/env/bin/set_serials b/arch/arm/boards/kindle3/env/bin/set_serials
> 
> Move this to /env/init/set_serials to let it automatically execute.
> 
> > new file mode 100644
> > index 0000000..e7e0881
> > --- /dev/null
> > +++ b/arch/arm/boards/kindle3/env/bin/set_serials
> > @@ -0,0 +1,18 @@
> > +#!/bin/sh
> > +
> > +# 16-byte alphanumeric containing the serial number
> > +# SN is the first 16 bytes before the bootloader
> > +if test -b /dev/disk0.serial; then
> > +	if memcpy -s /dev/disk0.serial -d tmp_serial16 -b 0 0 16; then
> > +		readf tmp_serial16 global.board.serial16
> > +	fi
> > +fi
> > +[ -f tmp_serial16 ] && rm tmp_serial16
> > +
> > +# 16-byte alphanumeric containing the board revision
> > +if test -b /dev/disk0.imx_header; then
> > +	if memcpy -s /dev/disk0.imx_header -d tmp_revision16 -b 2032 0 16; then
> > +		readf tmp_revision16 global.board.revision16
> > +	fi
> > +fi
> > +[ -f tmp_revision16 ] && rm tmp_revision16
> > diff --git a/arch/arm/boards/kindle3/env/boot/mmc_kernel b/arch/arm/boards/kindle3/env/boot/mmc_kernel
> > new file mode 100644
> > index 0000000..c6145b8
> > --- /dev/null
> > +++ b/arch/arm/boards/kindle3/env/boot/mmc_kernel
> > @@ -0,0 +1,7 @@
> > +#!/bin/sh
> > +# Boot the Amazon factory-shipped kernel uimage stored on
> > +# the eMMC at MOVINAND_OFFSET_KERNEL=266240.
> > +
> > +global linux.bootargs.dyn.root="root=/dev/mmcblk0p1 ro"
> > +
> > +bootm -c -a 0x80008000 /dev/disk0.kernel
> > diff --git a/arch/arm/boards/kindle3/env/config b/arch/arm/boards/kindle3/env/config
> > new file mode 100644
> > index 0000000..9b95330
> > --- /dev/null
> > +++ b/arch/arm/boards/kindle3/env/config
> > @@ -0,0 +1,15 @@
> > +#!/bin/sh
> > +
> > +# timeout in seconds before the default boot entry is started
> > +global.autoboot_timeout=3
> > +
> > +# list of boot entries. These are executed in order until one
> > +# succeeds. An entry can be:
> > +# - a filename in /env/boot/
> > +# - a full path to a directory. All files in this directory are
> > +#   treated as boot files and executed in alphabetical order
> > +global.boot.default=mmc_kernel
> > +
> > +global.linux.bootargs.base="mem=256M ip=none lpj=2555904"
> > +global.linux.bootargs.console="console=ttymxc0,115200"
> 
> Create files under /env/nv named after the variables with the content of
> the variables:
> 
> /env/nv/boot.default should contain "mmc_kernel"
> /env/nv/linux.bootargs.base should contain "mem=256M ip=none lpj=2555904"
> 
> and so on.
Thanks for your hints how to use defaultenv-2, this was an easy way 
how to eleminate the redundant passages in my previous env/bin/ subdir.
Cheers, Alexander

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

      reply	other threads:[~2016-07-09 14:07 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-05 21:28 Alexander Kurz
2016-07-07  6:47 ` Sascha Hauer
2016-07-09 14:04   ` Alexander Kurz [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.DEB.2.00.1607091529130.31760@blala.de \
    --to=akurz@blala.de \
    --cc=barebox@lists.infradead.org \
    --cc=s.hauer@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox