All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH kvm-unit-tests] x86: fix last commit
@ 2015-07-30 13:38 Paolo Bonzini
  2015-08-01 15:41 ` Shih-Wei Li
  0 siblings, 1 reply; 7+ messages in thread
From: Paolo Bonzini @ 2015-07-30 13:38 UTC (permalink / raw)
  To: kvm; +Cc: shihwei, bsd

Keeping the selector that was loaded from the 32-bit GDT is okay, because
only code segment descriptors differ between 32- and 64-bit mode.  In
fact the same is true for %ss as well, so let's just remove the whole
segment loading from load_tss.

Thanks to Bandan Das for debugging.

Reported-by: Shih-Wei Li <shihwei@cs.columbia.edu>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 x86/cstart64.S | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/x86/cstart64.S b/x86/cstart64.S
index 8d5ee2d..e947888 100644
--- a/x86/cstart64.S
+++ b/x86/cstart64.S
@@ -213,12 +213,6 @@ idt_descr:
 
 load_tss:
 	lidtq idt_descr
-	mov $0x10, %eax
-	mov %ax, %ds
-	mov %ax, %es
-	mov %ax, %fs
-	mov %ax, %gs
-	mov %ax, %ss
 	mov $(APIC_DEFAULT_PHYS_BASE + APIC_ID), %eax
 	mov (%rax), %eax
 	shr $24, %eax
-- 
1.8.3.1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2015-08-02  7:47 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-30 13:38 [PATCH kvm-unit-tests] x86: fix last commit Paolo Bonzini
2015-08-01 15:41 ` Shih-Wei Li
2015-08-01 19:05   ` Bandan Das
2015-08-01 20:49     ` Paolo Bonzini
2015-08-01 21:20       ` Bandan Das
2015-08-01 21:59         ` Shih-Wei Li
2015-08-02  7:47         ` Paolo Bonzini

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.