aboutsummaryrefslogtreecommitdiff
path: root/website/static/security/patches/SA-08:07/amd64.patch
blob: 9e910317cef244548bc99127bb29550fd046aee7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
Index: sys/amd64/amd64/exception.S
===================================================================
RCS file: /home/ncvs/src/sys/amd64/amd64/exception.S,v
retrieving revision 1.132
retrieving revision 1.133
diff -u -d -r1.132 -r1.133
--- sys/amd64/amd64/exception.S	24 May 2008 06:32:26 -0000	1.132
+++ sys/amd64/amd64/exception.S	18 Aug 2008 08:47:27 -0000	1.133
@@ -636,13 +636,10 @@
 	.globl	doreti_iret_fault
 doreti_iret_fault:
 	subq	$TF_RIP,%rsp		/* space including tf_err, tf_trapno */
-	testb	$SEL_RPL_MASK,TF_CS(%rsp) /* Did we come from kernel? */
-	jz	1f			/* already running with kernel GS.base */
-	swapgs
-1:	testl	$PSL_I,TF_RFLAGS(%rsp)
-	jz	2f
+	testl	$PSL_I,TF_RFLAGS(%rsp)
+	jz	1f
 	sti
-2:	movq	%rdi,TF_RDI(%rsp)
+1:	movq	%rdi,TF_RDI(%rsp)
 	movq	%rsi,TF_RSI(%rsp)
 	movq	%rdx,TF_RDX(%rsp)
 	movq	%rcx,TF_RCX(%rsp)