How to know working cpus on imx8

cancel
Showing results for 
Search instead for 
Did you mean: 

How to know working cpus on imx8

220 Views
mrigendra_chaub
Contributor III

Hi All,

I have a imx8qm based board and I want to know cpus on it, as it have a cortex a53 and cortex a72 cpus
We have this api

static inline unsigned int read_midr(void)
{
unsigned long val;

asm volatile("mrs %0, midr_el1" : "=r" (val));

return val;
}

#define is_cortex_a35() (((read_midr() & MIDR_PARTNUM_MASK) >> MIDR_PARTNUM_SHIFT) == MIDR_PARTNUM_CORTEX_A35)
#define is_cortex_a53() (((read_midr() & MIDR_PARTNUM_MASK) >> MIDR_PARTNUM_SHIFT) == MIDR_PARTNUM_CORTEX_A53)
#define is_cortex_a72() (((read_midr() & MIDR_PARTNUM_MASK) >> MIDR_PARTNUM_SHIFT) == MIDR_PARTNUM_CORTEX_A72)

The problem here is if I use

is_cortex_a72()

I get return as 1, but if I use

is_cortex_a53()

I get 0.

Does that mean there is no a53 cpu or we need to modify something here?

0 Kudos
1 Reply

139 Views
CarlosCasillas
NXP Employee
NXP Employee

Hi,

The i.MX8QM is still on preproduction, so, no additional information/support could be provided yet. In case of having doubts, please refer with your Sales/FAE.

Hope this will be useful for you. Best regards! /Carlos


Hope this will be useful for you.
Best regards!
/Carlos
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

-------------------------------------------------------------------------------

0 Kudos