summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2015-07-03 15:12:50 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2015-07-03 15:12:50 +0000
commitb7af9eed82e7206506b6da976e71f8ca1b0bc99a (patch)
tree228d93d6f65206cc041861dfe9ce504450385777 /sys
parent4566f813f43dfbb2f48cb78dc61d9262b8329070 (diff)
Rename mtx_cpu to mtx_owner for consistency with the other platforms.
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/m88k/include/mutex.h4
-rw-r--r--sys/arch/m88k/m88k/genassym.cf6
-rw-r--r--sys/arch/m88k/m88k/mutex.S20
3 files changed, 15 insertions, 15 deletions
diff --git a/sys/arch/m88k/include/mutex.h b/sys/arch/m88k/include/mutex.h
index 726a02c77e8..73cd600b766 100644
--- a/sys/arch/m88k/include/mutex.h
+++ b/sys/arch/m88k/include/mutex.h
@@ -1,6 +1,6 @@
#ifndef _M88K_MUTEX_H_
#define _M88K_MUTEX_H_
-/* $OpenBSD: mutex.h,v 1.3 2015/07/02 08:58:16 dlg Exp $ */
+/* $OpenBSD: mutex.h,v 1.4 2015/07/03 15:12:49 miod Exp $ */
/*
* Copyright (c) 2005, Miodrag Vallat.
@@ -31,7 +31,7 @@ struct mutex {
volatile int mtx_lock; /* mutex.S relies upon this field being first */
int mtx_wantipl;
int mtx_oldipl;
- void *mtx_cpu;
+ void *mtx_owner;
};
/*
diff --git a/sys/arch/m88k/m88k/genassym.cf b/sys/arch/m88k/m88k/genassym.cf
index 270e36d06b6..092d365ae9f 100644
--- a/sys/arch/m88k/m88k/genassym.cf
+++ b/sys/arch/m88k/m88k/genassym.cf
@@ -1,4 +1,4 @@
-# $OpenBSD: genassym.cf,v 1.23 2011/10/09 17:01:34 miod Exp $
+# $OpenBSD: genassym.cf,v 1.24 2015/07/03 15:12:49 miod Exp $
#
# Copyright (c) 1982, 1990 The Regents of the University of California.
# All rights reserved.
@@ -28,7 +28,7 @@
# SUCH DAMAGE.
#
# @(#)genassym.c 7.8 (Berkeley) 5/7/91
-# $Id: genassym.cf,v 1.23 2011/10/09 17:01:34 miod Exp $
+# $Id: genassym.cf,v 1.24 2015/07/03 15:12:49 miod Exp $
#
include <sys/param.h>
@@ -161,4 +161,4 @@ struct mutex
member mtx_lock
member mtx_wantipl
member mtx_oldipl
-member mtx_cpu
+member mtx_owner
diff --git a/sys/arch/m88k/m88k/mutex.S b/sys/arch/m88k/m88k/mutex.S
index 16796216c88..aed2cc9f189 100644
--- a/sys/arch/m88k/m88k/mutex.S
+++ b/sys/arch/m88k/m88k/mutex.S
@@ -1,4 +1,4 @@
-/* $OpenBSD: mutex.S,v 1.13 2014/02/02 20:31:10 kettenis Exp $ */
+/* $OpenBSD: mutex.S,v 1.14 2015/07/03 15:12:49 miod Exp $ */
/*
* Copyright (c) 2005, Miodrag Vallat.
@@ -40,7 +40,7 @@ ENTRY(__mtx_init)
st %r0, %r2, MTX_OLDIPL /* mtx->mtx_oldipl = IPL_NONE */
st %r3, %r2, MTX_WANTIPL /* mtx->mtx_wantipl = ipl */
jmp.n %r1
- st %r0, %r2, MTX_CPU /* mtx->mtx_cpu = NULL */
+ st %r0, %r2, MTX_OWNER /* mtx->mtx_owner = NULL */
/*
* void mtx_enter(struct mutex *mtx)
@@ -64,7 +64,7 @@ enter_again:
ldcr %r3, CPU
st %r2, %r4, MTX_OLDIPL /* save into mtx_oldipl */
- st %r3, %r4, MTX_CPU /* mtx->mtx_cpu = curcpu() */
+ st %r3, %r4, MTX_OWNER /* mtx->mtx_owner = curcpu() */
#ifdef DIAGNOSTIC
ld %r2, %r3, CI_MUTEX_LEVEL
addu %r2, %r2, 1 /* curcpu()->ci_mutex_level++ */
@@ -88,7 +88,7 @@ enter_failed: /* the lock is not ours... */
enter_spin:
#ifdef DIAGNOSTIC
ldcr %r3, CPU
- ld %r4, %r2, MTX_CPU
+ ld %r4, %r2, MTX_OWNER
cmp %r5, %r3, %r4
bcnd eq0, %r5, enter_panic
#endif
@@ -122,7 +122,7 @@ enter_panic:
#ifdef DIAGNOSTIC
/* necessary for MUTEX_ASSERT_LOCKED */
- st %r3, %r4, MTX_CPU /* mtx->mtx_cpu = curcpu() */
+ st %r3, %r4, MTX_OWNER /* mtx->mtx_owner = curcpu() */
ld %r2, %r3, CI_MUTEX_LEVEL
addu %r2, %r2, 1 /* curcpu()->ci_mutex_level++ */
@@ -157,7 +157,7 @@ enter_try_again:
ldcr %r3, CPU
st %r2, %r4, MTX_OLDIPL /* save into mtx_oldipl */
- st %r3, %r4, MTX_CPU /* mtx->mtx_cpu = curcpu() */
+ st %r3, %r4, MTX_OWNER /* mtx->mtx_owner = curcpu() */
#ifdef DIAGNOSTIC
ld %r2, %r3, CI_MUTEX_LEVEL
addu %r2, %r2, 1 /* curcpu()->ci_mutex_level++ */
@@ -181,7 +181,7 @@ enter_try_failed: /* the lock is not ours... */
#ifdef DIAGNOSTIC
ld %r2, %r31, 0 /* restore mtx */
ldcr %r3, CPU
- ld %r4, %r2, MTX_CPU
+ ld %r4, %r2, MTX_OWNER
cmp %r5, %r3, %r4
bcnd eq0, %r5, enter_try_panic
#endif
@@ -215,7 +215,7 @@ enter_try_panic:
#ifdef DIAGNOSTIC
/* necessary for MUTEX_ASSERT_LOCKED */
- st %r3, %r4, MTX_CPU /* mtx->mtx_cpu = curcpu() */
+ st %r3, %r4, MTX_OWNER /* mtx->mtx_owner = curcpu() */
ld %r2, %r3, CI_MUTEX_LEVEL
addu %r2, %r2, 1 /* curcpu()->ci_mutex_level++ */
@@ -236,12 +236,12 @@ ENTRY(mtx_leave)
ld %r3, %r2, MTX_OLDIPL
ld %r4, %r2, MTX_WANTIPL
#ifdef DIAGNOSTIC
- ld %r5, %r2, MTX_CPU
+ ld %r5, %r2, MTX_OWNER
ld %r6, %r5, CI_MUTEX_LEVEL
subu %r6, %r6, 1 /* curcpu()->ci_mutex_level++ */
st %r6, %r5, CI_MUTEX_LEVEL
#endif
- st %r0, %r2, MTX_CPU /* mtx->mtx_cpu = NULL */
+ st %r0, %r2, MTX_OWNER /* mtx->mtx_owner = NULL */
bcnd.n eq0, %r4, 2f
st %r0, %r2, MTX_LOCK /* mtx->mtx_lock = 0 */