Module Name:    src
Committed By:   ryo
Date:           Sat Oct 20 05:53:22 UTC 2018

Modified Files:
        src/sys/arch/arm/broadcom: bcm283x_platform.c

Log Message:
- fix AP spinup on bcm283x
- "brcm,bcm2836-smp" is a enable-method for only 32bit bcm2836.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/arch/arm/broadcom/bcm283x_platform.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/arm/broadcom/bcm283x_platform.c
diff -u src/sys/arch/arm/broadcom/bcm283x_platform.c:1.20 src/sys/arch/arm/broadcom/bcm283x_platform.c:1.21
--- src/sys/arch/arm/broadcom/bcm283x_platform.c:1.20	Thu Oct 18 09:01:52 2018
+++ src/sys/arch/arm/broadcom/bcm283x_platform.c	Sat Oct 20 05:53:22 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm283x_platform.c,v 1.20 2018/10/18 09:01:52 skrll Exp $	*/
+/*	$NetBSD: bcm283x_platform.c,v 1.21 2018/10/20 05:53:22 ryo Exp $	*/
 
 /*-
  * Copyright (c) 2017 Jared D. McNeill <jmcne...@invisible.ca>
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm283x_platform.c,v 1.20 2018/10/18 09:01:52 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm283x_platform.c,v 1.21 2018/10/20 05:53:22 ryo Exp $");
 
 #include "opt_arm_debug.h"
 #include "opt_bcm283x.h"
@@ -729,6 +729,8 @@ static void
 bcm2836_mpstart(void)
 {
 #ifdef MULTIPROCESSOR
+#ifdef __arm__
+	/* implementation dependent string "brcm,bcm2836-smp" for ARM 32-bit */
 	const char *method;
 
 	const int cpus = OF_finddevice("/cpus");
@@ -738,7 +740,6 @@ bcm2836_mpstart(void)
 		return;
 	}
 
-	/* implementation dependent string "brcm,bcm2836-smp" for ARM 32-bit */
 	method = fdtbus_get_string(cpus, "enable-method");
 	if ((method != NULL) && (strcmp(method, "brcm,bcm2836-smp") == 0)) {
 		arm_cpu_max = RPI_CPU_MAX;
@@ -772,9 +773,10 @@ bcm2836_mpstart(void)
 		}
 		return;
 	}
+#endif /* __arm__ */
 
 	/* try enable-method each cpus */
-	arm_fdt_cpu_bootstrap();
+	arm_fdt_cpu_mpstart();
 #endif /* MULTIPROCESSOR */
 }
 
@@ -1183,6 +1185,7 @@ bcm2836_platform_bootstrap(void)
 
 #ifdef MULTIPROCESSOR
 	arm_cpu_max = RPI_CPU_MAX;
+	arm_fdt_cpu_bootstrap();
 #endif
 }
 #endif

Reply via email to