summaryrefslogtreecommitdiff
path: root/sys/arch/arm64
diff options
context:
space:
mode:
authorMartin Pieuchot <mpi@cvs.openbsd.org>2018-01-13 15:18:12 +0000
committerMartin Pieuchot <mpi@cvs.openbsd.org>2018-01-13 15:18:12 +0000
commit5e38460a283b5e53bdcbf4b00933915a75bf00f7 (patch)
tree79aa3b5c8b0406750ace928f81748cd69fcc0d7c /sys/arch/arm64
parentaf0cdb69df549f230a3fb994f6fbf59996bf290d (diff)
Define and use IPL_MPFLOOR in our common mutex implementation.
ok kettenis@, visa@
Diffstat (limited to 'sys/arch/arm64')
-rw-r--r--sys/arch/arm64/include/intr.h3
-rw-r--r--sys/arch/arm64/include/mutex.h4
2 files changed, 4 insertions, 3 deletions
diff --git a/sys/arch/arm64/include/intr.h b/sys/arch/arm64/include/intr.h
index 2858a29b626..2bab7cda56d 100644
--- a/sys/arch/arm64/include/intr.h
+++ b/sys/arch/arm64/include/intr.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: intr.h,v 1.6 2017/03/09 14:23:59 kettenis Exp $ */
+/* $OpenBSD: intr.h,v 1.7 2018/01/13 15:18:11 mpi Exp $ */
/*
* Copyright (c) 2001-2004 Opsycon AB (www.opsycon.se / www.opsycon.com)
@@ -59,6 +59,7 @@
#define IPL_IPI 12 /* interprocessor interrupt */
#define NIPL 13 /* number of levels */
+#define IPL_MPFLOOR IPL_TTY
/* Interrupt priority 'flags'. */
#define IPL_MPSAFE 0 /* no "mpsafe" interrupts */
diff --git a/sys/arch/arm64/include/mutex.h b/sys/arch/arm64/include/mutex.h
index c42ef1cf233..5247385e106 100644
--- a/sys/arch/arm64/include/mutex.h
+++ b/sys/arch/arm64/include/mutex.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: mutex.h,v 1.3 2018/01/12 09:19:33 mpi Exp $ */
+/* $OpenBSD: mutex.h,v 1.4 2018/01/13 15:18:11 mpi Exp $ */
/*
* Copyright (c) 2004 Artur Grabowski <art@openbsd.org>
@@ -48,7 +48,7 @@ struct mutex {
*/
#ifdef MULTIPROCESSOR
#define __MUTEX_IPL(ipl) \
- (((ipl) > IPL_NONE && (ipl) < IPL_TTY) ? IPL_TTY : (ipl))
+ (((ipl) > IPL_NONE && (ipl) < IPL_MPFLOOR) ? IPL_MPFLOOR : (ipl))
#else
#define __MUTEX_IPL(ipl) (ipl)
#endif