Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/arm/fdt No longer need to call arm_pmu_init on all ...



details:   https://anonhg.NetBSD.org/src/rev/0a969fb97367
branches:  trunk
changeset: 1023830:0a969fb97367
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Mon Sep 27 09:54:52 2021 +0000

description:
No longer need to call arm_pmu_init on all CPUs.

diffstat:

 sys/arch/arm/fdt/pmu_fdt.c |  14 +++-----------
 1 files changed, 3 insertions(+), 11 deletions(-)

diffs (48 lines):

diff -r bb1de85a3eea -r 0a969fb97367 sys/arch/arm/fdt/pmu_fdt.c
--- a/sys/arch/arm/fdt/pmu_fdt.c        Mon Sep 27 07:13:30 2021 +0000
+++ b/sys/arch/arm/fdt/pmu_fdt.c        Mon Sep 27 09:54:52 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmu_fdt.c,v 1.8 2021/01/27 03:10:19 thorpej Exp $ */
+/* $NetBSD: pmu_fdt.c,v 1.9 2021/09/27 09:54:52 jmcneill Exp $ */
 
 /*-
  * Copyright (c) 2018 Jared McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmu_fdt.c,v 1.8 2021/01/27 03:10:19 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmu_fdt.c,v 1.9 2021/09/27 09:54:52 jmcneill Exp $");
 
 #include <sys/param.h>
 #include <sys/bus.h>
@@ -113,19 +113,12 @@
 }
 
 static void
-pmu_fdt_init_cpu(void *arg1, void *arg2)
-{
-       arm_pmu_init();
-}
-
-static void
 pmu_fdt_init(device_t self)
 {
        struct pmu_fdt_softc * const sc = device_private(self);
        const int phandle = sc->sc_phandle;
        char intrstr[128];
        int error, n;
-       uint64_t xc;
        void **ih;
 
        if (pmu_fdt_uses_ppi && pmu_fdt_count > 0) {
@@ -140,8 +133,7 @@
        }
 
        if (pmu_fdt_count == 0) {
-               xc = xc_broadcast(0, pmu_fdt_init_cpu, NULL, NULL);
-               xc_wait(xc);
+               arm_pmu_init();
        }
 
        ih = kmem_zalloc(sizeof(void *) * ncpu, KM_SLEEP);



Home | Main Index | Thread Index | Old Index