Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch fix i386 build - missed sources migration in previo...
details: https://anonhg.NetBSD.org/src/rev/dd8d52d366df
branches: trunk
changeset: 446923:dd8d52d366df
user: cherry <cherry%NetBSD.org@localhost>
date: Tue Dec 25 09:00:26 2018 +0000
description:
fix i386 build - missed sources migration in previous commit.
allow xen_intr.c to build by bringing in static support functions for
-D INTRSTACKSIZE
This should fix the i386 build now.
diffstat:
sys/arch/i386/i386/i386_trap.S | 12 ++++++------
sys/arch/i386/i386/spl.S | 12 ++++++------
sys/arch/xen/x86/xen_intr.c | 24 ++++++++++++++++++++++--
3 files changed, 34 insertions(+), 14 deletions(-)
diffs (122 lines):
diff -r 1c93314db5b5 -r dd8d52d366df sys/arch/i386/i386/i386_trap.S
--- a/sys/arch/i386/i386/i386_trap.S Tue Dec 25 08:59:06 2018 +0000
+++ b/sys/arch/i386/i386/i386_trap.S Tue Dec 25 09:00:26 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: i386_trap.S,v 1.15 2018/07/14 14:29:40 maxv Exp $ */
+/* $NetBSD: i386_trap.S,v 1.16 2018/12/25 09:00:26 cherry Exp $ */
/*
* Copyright 2002 (c) Wasabi Systems, Inc.
@@ -66,7 +66,7 @@
#if 0
#include <machine/asm.h>
-__KERNEL_RCSID(0, "$NetBSD: i386_trap.S,v 1.15 2018/07/14 14:29:40 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: i386_trap.S,v 1.16 2018/12/25 09:00:26 cherry Exp $");
#endif
/*
@@ -447,12 +447,12 @@
movl $.Lalltraps_resume,%esi /* address to resume loop at */
.Lalltraps_resume:
movl %ebx,%eax /* get cpl */
- movl CPUVAR(IUNMASK)(,%eax,4),%eax
- andl CPUVAR(IPENDING),%eax /* any non-masked bits left? */
+ movl CPUVAR(XUNMASK)(,%eax,4),%eax
+ andl CPUVAR(XPENDING),%eax /* any non-masked bits left? */
jz 7f
bsrl %eax,%eax
- btrl %eax,CPUVAR(IPENDING)
- movl CPUVAR(ISOURCES)(,%eax,4),%eax
+ btrl %eax,CPUVAR(XPENDING)
+ movl CPUVAR(XSOURCES)(,%eax,4),%eax
jmp *IS_RESUME(%eax)
7: movl %ebx,CPUVAR(ILEVEL) /* restore cpl */
jmp _C_LABEL(trapreturn)
diff -r 1c93314db5b5 -r dd8d52d366df sys/arch/i386/i386/spl.S
--- a/sys/arch/i386/i386/spl.S Tue Dec 25 08:59:06 2018 +0000
+++ b/sys/arch/i386/i386/spl.S Tue Dec 25 09:00:26 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: spl.S,v 1.44 2018/12/25 06:50:11 cherry Exp $ */
+/* $NetBSD: spl.S,v 1.45 2018/12/25 09:00:26 cherry Exp $ */
/*
* Copyright (c) 1998, 2007, 2008 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <machine/asm.h>
-__KERNEL_RCSID(0, "$NetBSD: spl.S,v 1.44 2018/12/25 06:50:11 cherry Exp $");
+__KERNEL_RCSID(0, "$NetBSD: spl.S,v 1.45 2018/12/25 09:00:26 cherry Exp $");
#include "opt_ddb.h"
#include "opt_spldebug.h"
@@ -290,12 +290,12 @@
2: /* Check for ASTs on exit to user mode. */
#if defined(XEN)
movl %ebx,%eax
- movl CPUVAR(IUNMASK)(,%eax,4),%eax
- andl CPUVAR(IPENDING),%eax
+ movl CPUVAR(XUNMASK)(,%eax,4),%eax
+ andl CPUVAR(XPENDING),%eax
jz 3f
bsrl %eax,%eax /* slow, but not worth optimizing */
- btrl %eax,CPUVAR(IPENDING)
- movl CPUVAR(ISOURCES)(,%eax, 4),%eax
+ btrl %eax,CPUVAR(XPENDING)
+ movl CPUVAR(XSOURCES)(,%eax, 4),%eax
jmp *IS_RESUME(%eax)
#endif
3:
diff -r 1c93314db5b5 -r dd8d52d366df sys/arch/xen/x86/xen_intr.c
--- a/sys/arch/xen/x86/xen_intr.c Tue Dec 25 08:59:06 2018 +0000
+++ b/sys/arch/xen/x86/xen_intr.c Tue Dec 25 09:00:26 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: xen_intr.c,v 1.11 2018/12/25 06:50:12 cherry Exp $ */
+/* $NetBSD: xen_intr.c,v 1.12 2018/12/25 09:00:26 cherry Exp $ */
/*-
* Copyright (c) 1998, 2001 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: xen_intr.c,v 1.11 2018/12/25 06:50:12 cherry Exp $");
+__KERNEL_RCSID(0, "$NetBSD: xen_intr.c,v 1.12 2018/12/25 09:00:26 cherry Exp $");
#include <sys/param.h>
#include <sys/kernel.h>
@@ -40,6 +40,8 @@
#include <xen/evtchn.h>
+#include <uvm/uvm.h>
+
#include <machine/cpu.h>
#include <machine/intr.h>
@@ -302,6 +304,24 @@
}
/* MD - called by x86/cpu.c */
+#if defined(INTRSTACKSIZE)
+static inline bool
+redzone_const_or_false(bool x)
+{
+#ifdef DIAGNOSTIC
+ return x;
+#else
+ return false;
+#endif /* !DIAGNOSTIC */
+}
+
+static inline int
+redzone_const_or_zero(int x)
+{
+ return redzone_const_or_false(true) ? x : 0;
+}
+#endif
+
void
cpu_intr_init(struct cpu_info *ci)
{
Home |
Main Index |
Thread Index |
Old Index