[PATCH] ARM: mx27: Print silicon revision on boot
Marek Vasut
marek.vasut at gmail.com
Mon Aug 22 14:21:33 EDT 2011
On Monday, August 22, 2011 07:09:11 PM Sascha Hauer wrote:
> On Mon, Aug 22, 2011 at 01:10:46PM -0300, Fabio Estevam wrote:
> > On Mon, Aug 22, 2011 at 1:05 PM, Marek Vasut <marek.vasut at gmail.com>
> > wrote: ...
> >
> > > I didn't check really, but can't you just do some kind of a numeric
> > > transformation instead of storing strings ?
> >
> > I am using the same approach used by other i.MX processors.
>
> How about
>
> imx_print_silicon_rev(const char *cpu, int srev)
> {
> if (srev == IMX_CHIP_REVISION_UNKNOWN)
> pr_info("CPU identified as %s, unknown revision\n");
> else
> pr_info("CPU identified as %s, silicon rev %d.%d\n",
> cpu, (srev >> 4) & 0xf, srev & 0xf);
> }
>
> Sascha
Looks good
More information about the linux-arm-kernel
mailing list