AnsweredAssumed Answered

How to know working cpus on imx8

Question asked by mrigendra chaubey on Jun 10, 2019
Latest reply on Jun 12, 2019 by CarlosCasillas

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



I get return as 1, but if I use


I get 0.


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