Changeset View
Changeset View
Standalone View
Standalone View
head/sys/powerpc/powerpc/mp_machdep.c
Show First 20 Lines • Show All 176 Lines • ▼ Show 20 Lines | if (cpu.cr_cpuid != bsp.cr_cpuid) { | ||||
pcpu_init(pc, cpu.cr_cpuid, sizeof(*pc)); | pcpu_init(pc, cpu.cr_cpuid, sizeof(*pc)); | ||||
dpcpu_init(dpcpu, cpu.cr_cpuid); | dpcpu_init(dpcpu, cpu.cr_cpuid); | ||||
} else { | } else { | ||||
pc = pcpup; | pc = pcpup; | ||||
pc->pc_cpuid = bsp.cr_cpuid; | pc->pc_cpuid = bsp.cr_cpuid; | ||||
pc->pc_bsp = 1; | pc->pc_bsp = 1; | ||||
} | } | ||||
pc->pc_hwref = cpu.cr_hwref; | pc->pc_hwref = cpu.cr_hwref; | ||||
if (vm_ndomains > 1) | |||||
pc->pc_domain = cpu.cr_domain; | |||||
else | |||||
pc->pc_domain = 0; | |||||
CPU_SET(pc->pc_cpuid, &cpuset_domain[pc->pc_domain]); | |||||
KASSERT(pc->pc_domain < MAXMEMDOM, ("bad domain value %d\n", | |||||
pc->pc_domain)); | |||||
CPU_SET(pc->pc_cpuid, &all_cpus); | CPU_SET(pc->pc_cpuid, &all_cpus); | ||||
next: | next: | ||||
error = platform_smp_next_cpu(&cpu); | error = platform_smp_next_cpu(&cpu); | ||||
} | } | ||||
#ifdef SMP | #ifdef SMP | ||||
platform_smp_probe_threads(); | platform_smp_probe_threads(); | ||||
#endif | #endif | ||||
} | } | ||||
void | void | ||||
cpu_mp_announce(void) | cpu_mp_announce(void) | ||||
{ | { | ||||
struct pcpu *pc; | struct pcpu *pc; | ||||
int i; | int i; | ||||
if (!bootverbose) | if (!bootverbose) | ||||
return; | return; | ||||
CPU_FOREACH(i) { | CPU_FOREACH(i) { | ||||
pc = pcpu_find(i); | pc = pcpu_find(i); | ||||
if (pc == NULL) | if (pc == NULL) | ||||
continue; | continue; | ||||
printf("cpu%d: dev=%x", i, (int)pc->pc_hwref); | printf("cpu%d: dev=%x domain=%d ", i, (int)pc->pc_hwref, pc->pc_domain); | ||||
if (pc->pc_bsp) | if (pc->pc_bsp) | ||||
printf(" (BSP)"); | printf(" (BSP)"); | ||||
printf("\n"); | printf("\n"); | ||||
} | } | ||||
} | } | ||||
static void | static void | ||||
cpu_mp_unleash(void *dummy) | cpu_mp_unleash(void *dummy) | ||||
▲ Show 20 Lines • Show All 170 Lines • Show Last 20 Lines |