Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/powerpc/oea when switching CPU speed using DFS, onl...
details: https://anonhg.NetBSD.org/src/rev/958bd217a0a0
branches: trunk
changeset: 319736:958bd217a0a0
user: macallan <macallan%NetBSD.org@localhost>
date: Fri Jun 08 23:40:44 2018 +0000
description:
when switching CPU speed using DFS, only use xcalls on MULTIPROCESSOR kernels
diffstat:
sys/arch/powerpc/oea/cpu_subr.c | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
diffs (41 lines):
diff -r 76529f8006bd -r 958bd217a0a0 sys/arch/powerpc/oea/cpu_subr.c
--- a/sys/arch/powerpc/oea/cpu_subr.c Fri Jun 08 23:39:31 2018 +0000
+++ b/sys/arch/powerpc/oea/cpu_subr.c Fri Jun 08 23:40:44 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cpu_subr.c,v 1.95 2018/06/01 18:06:58 macallan Exp $ */
+/* $NetBSD: cpu_subr.c,v 1.96 2018/06/08 23:40:44 macallan Exp $ */
/*-
* Copyright (c) 2001 Matt Thomas.
@@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cpu_subr.c,v 1.95 2018/06/01 18:06:58 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpu_subr.c,v 1.96 2018/06/08 23:40:44 macallan Exp $");
#include "opt_ppcparam.h"
#include "opt_ppccache.h"
@@ -1144,7 +1144,6 @@
void
cpu_set_dfs(int div)
{
- uint64_t where;
u_int dfs_mask, pvr, vers;
pvr = mfpvr();
@@ -1162,9 +1161,13 @@
return;
}
-
+#ifdef MULTIPROCESSOR
+ uint64_t where;
where = xc_broadcast(0, (xcfunc_t)cpu_set_dfs_xcall, &div, &dfs_mask);
xc_wait(where);
+#else
+ cpu_set_dfs_xcall(&div, &dfs_mask);
+#endif
}
static void
Home |
Main Index |
Thread Index |
Old Index