From: Sascha Hauer <s.hauer@pengutronix.de>
To: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 1/3] at91: add boot mode detection support
Date: Wed, 6 Feb 2013 19:27:50 +0100 [thread overview]
Message-ID: <20130206182750.GH1906@pengutronix.de> (raw)
In-Reply-To: <1360087380-5700-1-git-send-email-plagnioj@jcrosoft.com>
+1 for getting something common. On i.MX we currently use the
barebox_loc environment variable. Not that I you should do the same for
Atmel, but we should come up with something both i.MX and Atmel can be
converted to.
> +
> + dev = add_generic_device_res("bootloc", DEVICE_ID_SINGLE, NULL, 0, NULL);
I know you are concerned about performance when the single 'global'
device has many variables. I think the performance can be greatly
improved by making sure the global device is the first one to be
registered.
IMO adding a new device for every fart in the system does not improve the
situation.
> +enum at91_soc_boot_from {
> + AT91_BOOT_FROM_UNKNOWN,
> + AT91_BOOT_FROM_SPI,
> + AT91_BOOT_FROM_MCI,
> + AT91_BOOT_FROM_SMC,
> + AT91_BOOT_FROM_TWD,
> +};
> +
> +enum at91_soc_boot_media {
> + AT91_BOOT_MEDIA_UNKNOWN,
> + AT91_BOOT_MEDIA_SD,
> + AT91_BOOT_MEDIA_MMC,
> + AT91_BOOT_MEDIA_EMMC,
> + AT91_BOOT_MEDIA_AT45,
> + AT91_BOOT_MEDIA_AT25,
> + AT91_BOOT_MEDIA_NAND,
> + AT91_BOOT_MEDIA_NOR,
> +};
Hm. For NAND/NOR the first array does not contain useful information,
for MCI the second array does not contain useful information. For
I2C/SPI both arrays seem redundant.
Why not merge them into one?
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2013-02-06 18:27 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-05 17:59 [PATCH 0/3] " Jean-Christophe PLAGNIOL-VILLARD
2013-02-05 18:02 ` [PATCH 1/3] " Jean-Christophe PLAGNIOL-VILLARD
2013-02-05 18:02 ` [PATCH 2/3] sama5d3: add boot mode supprot Jean-Christophe PLAGNIOL-VILLARD
2013-02-05 18:03 ` [PATCH 3/3] sama5d3: detect boot mode Jean-Christophe PLAGNIOL-VILLARD
2013-02-06 10:05 ` Alexander Aring
2013-02-06 13:14 ` Jean-Christophe PLAGNIOL-VILLARD
2013-02-05 18:08 ` [PATCH 1/3] at91: add boot mode detection support Marc Kleine-Budde
2013-02-06 18:27 ` Sascha Hauer [this message]
2013-02-06 18:45 ` Jean-Christophe PLAGNIOL-VILLARD
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=20130206182750.GH1906@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=plagnioj@jcrosoft.com \
/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