/* * Initialise the CPU possible map early - this describes the CPUs * which may be present or become present in the system.
*/ staticvoid __init imx_smp_init_cpus(void)
{ int i, ncores;
ncores = scu_get_core_count(scu_base);
for (i = ncores; i < NR_CPUS; i++)
set_cpu_possible(i, false);
}
/* * The diagnostic register holds the errata bits. Mostly bootloader * does not bring up secondary cores, so that when errata bits are set * in bootloader, they are set only for boot cpu. But on a SMP * configuration, it should be equally done on every single core. * Read the register from boot cpu here, and will replicate it into * secondary cores when booting them.
*/ asm("mrc p15, 0, %0, c15, c0, 1" : "=r" (g_diag_reg) : : "cc");
sync_cache_w(&g_diag_reg);
}
/* * Initialise the CPU possible map early - this describes the CPUs * which may be present or become present in the system.
*/ staticvoid __init imx7_smp_init_cpus(void)
{ struct device_node *np; int i, ncores = 0;
/* The iMX7D SCU does not report core count, get it from DT */
for_each_of_cpu_node(np)
ncores++;
for (i = ncores; i < NR_CPUS; i++)
set_cpu_possible(i, false);
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.