[i.MX] add function to determine chip revision
This commit is contained in:
parent
bb6d50805a
commit
2ae190a9dd
|
@ -1,6 +1,6 @@
|
|||
obj-y += clocksource.o
|
||||
obj-$(CONFIG_ARCH_IMX1) += speed-imx1.o gpio.o
|
||||
obj-$(CONFIG_ARCH_IMX27) += speed-imx27.o gpio.o
|
||||
obj-$(CONFIG_ARCH_IMX27) += speed-imx27.o gpio.o imx27.o
|
||||
obj-$(CONFIG_ARCH_IMX31) += speed-imx31.o gpio-imx31.o
|
||||
obj-y += speed.o
|
||||
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
/*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <asm/arch/imx-regs.h>
|
||||
|
||||
int imx_silicon_revision(void)
|
||||
{
|
||||
return CID >> 28;
|
||||
}
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
int imx_silicon_revision(void);
|
||||
#define IMX27_CHIP_REVISION_1_0 0
|
||||
#define IMX27_CHIP_REVISION_2_0 1
|
Loading…
Reference in New Issue