WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] user -> kernel syscall path must enable interrupts after

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] user -> kernel syscall path must enable interrupts after all, since
From: BitKeeper Bot <riel@xxxxxxxxxxx>
Date: Fri, 10 Jun 2005 09:34:30 +0000
Delivery-date: Fri, 10 Jun 2005 10:01:46 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: Xen Development List <xen-devel@xxxxxxxxxxxxxxxxxxx>
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
ChangeSet 1.1715, 2005/06/10 10:34:30+01:00, kaf24@xxxxxxxxxxxxxxxxxxxx

        user -> kernel syscall path must enable interrupts after all, since
        it calls create_bounce_frame which can potentially fault. Thus we must
        also test_all_events.
        Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>



 entry.S |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)


diff -Nru a/xen/arch/x86/x86_64/entry.S b/xen/arch/x86/x86_64/entry.S
--- a/xen/arch/x86/x86_64/entry.S       2005-06-10 06:02:44 -04:00
+++ b/xen/arch/x86/x86_64/entry.S       2005-06-10 06:02:44 -04:00
@@ -19,15 +19,16 @@
         movq (reg),reg;
 
         ALIGN
-/* %rbx: struct vcpu, interrupts disabled */
+/* %rbx: struct vcpu */
 switch_to_kernel:
         leaq  VCPU_trap_bounce(%rbx),%rdx
         movq  VCPU_syscall_addr(%rbx),%rax
         movq  %rax,TRAPBOUNCE_eip(%rdx)
         movw  $0,TRAPBOUNCE_flags(%rdx)
         call  create_bounce_frame
+        jmp   test_all_events
 
-/* %rbx: struct vcpu */
+/* %rbx: struct vcpu, interrupts disabled */
 restore_all_guest:
         RESTORE_ALL
         testw $TRAP_syscall,4(%rsp)
@@ -38,7 +39,6 @@
         popq  %r11                    # CS
         cmpw  $__GUEST_CS32,%r11
         popq  %r11                    # RFLAGS
-        cli                           # No interrupts after stack switch
         popq  %rsp                    # RSP
         je    1f
         sysretq
@@ -107,6 +107,7 @@
  */
         ALIGN
 ENTRY(syscall_enter)
+        sti
         movl  $__GUEST_SS,24(%rsp)
         pushq %rcx
         pushq $0
@@ -117,7 +118,6 @@
         jz    switch_to_kernel
 
 /*hypercall:*/
-        sti
         movq  %r10,%rcx
         andq  $(NR_hypercalls-1),%rax
         leaq  hypercall_table(%rip),%r10

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] user -> kernel syscall path must enable interrupts after all, since, BitKeeper Bot <=