Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys Add a bool to pcu_state_save which indicates whether the...
details: https://anonhg.NetBSD.org/src/rev/3c21d59be274
branches: trunk
changeset: 762222:3c21d59be274
user: matt <matt%NetBSD.org@localhost>
date: Thu Feb 17 18:44:54 2011 +0000
description:
Add a bool to pcu_state_save which indicates whether the PCU is going to be
released after the save is done.
diffstat:
sys/kern/subr_pcu.c | 8 ++++----
sys/sys/pcu.h | 4 ++--
2 files changed, 6 insertions(+), 6 deletions(-)
diffs (54 lines):
diff -r c4740c687122 -r 3c21d59be274 sys/kern/subr_pcu.c
--- a/sys/kern/subr_pcu.c Thu Feb 17 18:35:35 2011 +0000
+++ b/sys/kern/subr_pcu.c Thu Feb 17 18:44:54 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: subr_pcu.c,v 1.1 2011/02/17 18:32:29 rmind Exp $ */
+/* $NetBSD: subr_pcu.c,v 1.2 2011/02/17 18:44:54 matt Exp $ */
/*-
* Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -57,7 +57,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: subr_pcu.c,v 1.1 2011/02/17 18:32:29 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_pcu.c,v 1.2 2011/02/17 18:44:54 matt Exp $");
#include <sys/param.h>
#include <sys/cpu.h>
@@ -98,7 +98,7 @@
return;
}
if (flags & PCU_SAVE) {
- pcu->pcu_state_save(l);
+ pcu->pcu_state_save(l, (flags & PCU_RELEASE) != 0);
}
if (flags & PCU_RELEASE) {
ci->ci_pcu_curlwp[id] = NULL;
@@ -131,7 +131,7 @@
KASSERT(ci->ci_pcu_curlwp[id] == l);
if (flags & PCU_SAVE) {
- pcu->pcu_state_save(l);
+ pcu->pcu_state_save(l, (flags & PCU_RELEASE) != 0);
}
if (flags & PCU_RELEASE) {
ci->ci_pcu_curlwp[id] = NULL;
diff -r c4740c687122 -r 3c21d59be274 sys/sys/pcu.h
--- a/sys/sys/pcu.h Thu Feb 17 18:35:35 2011 +0000
+++ b/sys/sys/pcu.h Thu Feb 17 18:44:54 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pcu.h,v 1.1 2011/02/17 18:32:29 rmind Exp $ */
+/* $NetBSD: pcu.h,v 1.2 2011/02/17 18:44:54 matt Exp $ */
/*-
* Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -45,7 +45,7 @@
typedef struct {
u_int pcu_id;
- void (*pcu_state_save)(lwp_t *);
+ void (*pcu_state_save)(lwp_t *, bool);
void (*pcu_state_load)(lwp_t *, bool);
} pcu_ops_t;
Home |
Main Index |
Thread Index |
Old Index