Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/mips/mips Update to use new pcu_state_{load, save, re...
details: https://anonhg.NetBSD.org/src/rev/564b8b5b64bb
branches: trunk
changeset: 783506:564b8b5b64bb
user: matt <matt%NetBSD.org@localhost>
date: Wed Dec 26 19:09:07 2012 +0000
description:
Update to use new pcu_state_{load,save,release} definitions.
diffstat:
sys/arch/mips/mips/mips_fpu.c | 18 +++++++++---------
1 files changed, 9 insertions(+), 9 deletions(-)
diffs (67 lines):
diff -r 1ac705f6cec3 -r 564b8b5b64bb sys/arch/mips/mips/mips_fpu.c
--- a/sys/arch/mips/mips/mips_fpu.c Wed Dec 26 19:05:03 2012 +0000
+++ b/sys/arch/mips/mips/mips_fpu.c Wed Dec 26 19:09:07 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mips_fpu.c,v 1.8 2012/02/27 15:57:21 matt Exp $ */
+/* $NetBSD: mips_fpu.c,v 1.9 2012/12/26 19:09:07 matt Exp $ */
/*-
* Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: mips_fpu.c,v 1.8 2012/02/27 15:57:21 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: mips_fpu.c,v 1.9 2012/12/26 19:09:07 matt Exp $");
#include "opt_multiprocessor.h"
@@ -46,9 +46,9 @@
#include <mips/regnum.h>
#include <mips/pcb.h>
-static void mips_fpu_state_save(lwp_t *);
-static void mips_fpu_state_load(lwp_t *, bool);
-static void mips_fpu_state_release(lwp_t *);
+static void mips_fpu_state_save(lwp_t *, u_int);
+static void mips_fpu_state_load(lwp_t *, u_int);
+static void mips_fpu_state_release(lwp_t *, u_int);
const pcu_ops_t mips_fpu_ops = {
.pcu_id = PCU_FPU,
@@ -82,7 +82,7 @@
}
void
-mips_fpu_state_save(lwp_t *l)
+mips_fpu_state_save(lwp_t *l, u_int flags)
{
struct trapframe * const tf = l->l_md.md_utf;
struct pcb * const pcb = lwp_getpcb(l);
@@ -205,7 +205,7 @@
}
void
-mips_fpu_state_load(lwp_t *l, bool used)
+mips_fpu_state_load(lwp_t *l, u_int flags)
{
struct trapframe * const tf = l->l_md.md_utf;
struct pcb * const pcb = lwp_getpcb(l);
@@ -218,7 +218,7 @@
/*
* If this is the first time the state is being loaded, zero it first.
*/
- if (__predict_false(!used)) {
+ if (__predict_false(!(flags & PCU_LOADED) == 0)) {
memset(&pcb->pcb_fpregs, 0, sizeof(pcb->pcb_fpregs));
}
@@ -343,7 +343,7 @@
}
void
-mips_fpu_state_release(lwp_t *l)
+mips_fpu_state_release(lwp_t *l, u_int flags)
{
l->l_md.md_utf->tf_regs[_R_SR] &= ~MIPS_SR_COP_1_BIT;
Home |
Main Index |
Thread Index |
Old Index