diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2007-11-11 13:05:29 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2007-11-11 13:05:29 +0000 |
commit | 6e2507a2ef2860ca4ab69b1256b04468b9592ea4 (patch) | |
tree | 769da9d538d5da5a780c45ee888831e8f28291e3 | |
parent | 967c67876324858a356573173e882a8ea5c0781b (diff) |
In dma_cachectl(), flush unconditionnaly on all processors, regardless of the
cpu bitmask of the pmap.
-rw-r--r-- | sys/arch/m88k/m88k/m8820x_machdep.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/sys/arch/m88k/m88k/m8820x_machdep.c b/sys/arch/m88k/m88k/m8820x_machdep.c index c3b9e509596..a9b11b00c03 100644 --- a/sys/arch/m88k/m88k/m8820x_machdep.c +++ b/sys/arch/m88k/m88k/m8820x_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: m8820x_machdep.c,v 1.28 2007/11/09 22:47:21 miod Exp $ */ +/* $OpenBSD: m8820x_machdep.c,v 1.29 2007/11/11 13:05:28 miod Exp $ */ /* * Copyright (c) 2004, Miodrag Vallat. * @@ -712,7 +712,6 @@ m8820x_dma_cachectl(pmap_t pmap, vaddr_t _va, vsize_t _size, int op) int cpu; #ifdef MULTIPROCESSOR struct cpu_info *ci = curcpu(); - u_int32_t cpumask; #endif vaddr_t va; paddr_t pa; @@ -737,9 +736,7 @@ m8820x_dma_cachectl(pmap_t pmap, vaddr_t _va, vsize_t _size, int op) break; } -#ifdef MULTIPROCESSOR - cpumask = pmap->pm_cpus & ~(1 << ci->ci_cpuid); -#else +#ifndef MULTIPROCESSOR cpu = cpu_number(); #endif @@ -758,10 +755,9 @@ m8820x_dma_cachectl(pmap_t pmap, vaddr_t _va, vsize_t _size, int op) /* invalidate on all... */ if (flusher != m8820x_cmmu_sync_cache) { - for (cpu = 0; cpumask != 0; cpu++) { - if (((1 << cpu) & cpumask) == 0) + for (cpu = 0; cpu < MAX_CPUS; cpu++) { + if (m88k_cpus[cpu].ci_alive == 0) continue; - cpumask ^= 1 << cpu; (*flusher)(cpu, pa, count); } } |