diff options
author | 2018-03-29 19:48:14 +0000 | |
---|---|---|
committer | 2018-03-29 19:48:14 +0000 | |
commit | 8305eac4ddf7381b5f2e4c9cd145a9e8f6f32ca9 (patch) | |
tree | 3819c9460f64c2defef5cff285a457feca6ae98f | |
parent | Check the result of strdup not the argument for NULL to report malloc (diff) | |
download | wireguard-openbsd-8305eac4ddf7381b5f2e4c9cd145a9e8f6f32ca9.tar.xz wireguard-openbsd-8305eac4ddf7381b5f2e4c9cd145a9e8f6f32ca9.zip |
Initialize the secondary core's schedstate before spinning them up.
ok kettenis@
-rw-r--r-- | sys/arch/arm64/arm64/cpu.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/arch/arm64/arm64/cpu.c b/sys/arch/arm64/arm64/cpu.c index b88d4e81a15..e0fedfdc1b0 100644 --- a/sys/arch/arm64/arm64/cpu.c +++ b/sys/arch/arm64/arm64/cpu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.c,v 1.16 2018/02/24 09:45:10 kettenis Exp $ */ +/* $OpenBSD: cpu.c,v 1.17 2018/03/29 19:48:14 patrick Exp $ */ /* * Copyright (c) 2016 Dale Rahn <drahn@dalerahn.com> @@ -265,6 +265,7 @@ cpu_attach(struct device *parent, struct device *dev, void *aux) "cpu-release-addr", 0); } + sched_init_cpu(ci); if (cpu_hatch_secondary(ci, spinup_method, spinup_data)) { atomic_setbits_int(&ci->ci_flags, CPUF_IDENTIFY); __asm volatile("dsb sy; sev"); @@ -333,7 +334,6 @@ cpu_boot_secondary_processors(void) continue; ci->ci_randseed = (arc4random() & 0x7fffffff) + 1; - sched_init_cpu(ci); cpu_boot_secondary(ci); } } |