mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-06-26 08:31:28 +00:00
arm: mx6: add get_cpu_type()
Define get_cpu_type(). Reuse it in is_cpu_type(). Cc: Igor Grinberg <grinberg@compulab.co.il> Cc: Stefano Babic <sbabic@denx.de> Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
This commit is contained in:
parent
07ee927d2c
commit
ea818ae748
1 changed files with 3 additions and 2 deletions
|
@ -20,8 +20,9 @@ u32 get_cpu_rev(void);
|
||||||
/* returns MXC_CPU_ value */
|
/* returns MXC_CPU_ value */
|
||||||
#define cpu_type(rev) (((rev) >> 12)&0xff)
|
#define cpu_type(rev) (((rev) >> 12)&0xff)
|
||||||
|
|
||||||
/* use with MXC_CPU_ constants */
|
/* both macros return/take MXC_CPU_ constants */
|
||||||
#define is_cpu_type(cpu) (cpu_type(get_cpu_rev()) == cpu)
|
#define get_cpu_type() (cpu_type(get_cpu_rev()))
|
||||||
|
#define is_cpu_type(cpu) (get_cpu_type() == cpu)
|
||||||
|
|
||||||
const char *get_imx_type(u32 imxtype);
|
const char *get_imx_type(u32 imxtype);
|
||||||
unsigned imx_ddr_size(void);
|
unsigned imx_ddr_size(void);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue