summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordavidxu <davidxu@FreeBSD.org>2003-04-22 08:12:03 +0000
committerdavidxu <davidxu@FreeBSD.org>2003-04-22 08:12:03 +0000
commit0a01dd83c56a11d1a584072305bdeab3d3518c20 (patch)
tree2f51b2f58013cd269e159aa4cae6e8e4515b1e0d
parent80dc2cd82df7e97741cfb48380c966c170866a8f (diff)
downloadFreeBSD-src-0a01dd83c56a11d1a584072305bdeab3d3518c20.zip
FreeBSD-src-0a01dd83c56a11d1a584072305bdeab3d3518c20.tar.gz
Move down intr level testing code a bit, cpu_switch_load_gs fault can be at
interrupt nested time.
-rw-r--r--sys/amd64/amd64/trap.c6
-rw-r--r--sys/i386/i386/trap.c6
2 files changed, 6 insertions, 6 deletions
diff --git a/sys/amd64/amd64/trap.c b/sys/amd64/amd64/trap.c
index f8662b2..a0f8508 100644
--- a/sys/amd64/amd64/trap.c
+++ b/sys/amd64/amd64/trap.c
@@ -470,9 +470,6 @@ trap(frame)
if (PCPU_GET(curpcb)->pcb_flags & PCB_VM86CALL)
break;
- if (td->td_intr_nesting_level != 0)
- break;
-
/*
* Invalid %fs's and %gs's can be created using
* procfs or PT_SETREGS or by invalidating the
@@ -495,6 +492,9 @@ trap(frame)
goto out;
}
+ if (td->td_intr_nesting_level != 0)
+ break;
+
/*
* Invalid segment selectors and out of bounds
* %eip's and %esp's can be set up in user mode.
diff --git a/sys/i386/i386/trap.c b/sys/i386/i386/trap.c
index f8662b2..a0f8508 100644
--- a/sys/i386/i386/trap.c
+++ b/sys/i386/i386/trap.c
@@ -470,9 +470,6 @@ trap(frame)
if (PCPU_GET(curpcb)->pcb_flags & PCB_VM86CALL)
break;
- if (td->td_intr_nesting_level != 0)
- break;
-
/*
* Invalid %fs's and %gs's can be created using
* procfs or PT_SETREGS or by invalidating the
@@ -495,6 +492,9 @@ trap(frame)
goto out;
}
+ if (td->td_intr_nesting_level != 0)
+ break;
+
/*
* Invalid segment selectors and out of bounds
* %eip's and %esp's can be set up in user mode.
OpenPOWER on IntegriCloud