]> git.hungrycats.org Git - linux/commitdiff
[PATCH] i386 entry.S cleanups
authorIngo Molnar <mingo@elte.hu>
Mon, 18 Oct 2004 15:52:55 +0000 (08:52 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Mon, 18 Oct 2004 15:52:55 +0000 (08:52 -0700)
Remove the unused lcall7/lcall27 code.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/i386/kernel/entry.S
arch/i386/kernel/traps.c

index 5c1f205e589bdcf136b379aa4f0475965fb437af..b158ceb8b126abef494c86e639747dfae37e9e6c 100644 (file)
@@ -140,40 +140,6 @@ VM_MASK            = 0x00020000
 .previous
 
 
-
-ENTRY(lcall7)
-       pushfl                  # We get a different stack layout with call
-                               # gates, which has to be cleaned up later..
-       pushl %eax
-       SAVE_ALL
-       movl %esp, %ebp
-       pushl %ebp
-       pushl $0x7
-do_lcall:
-       movl EIP(%ebp), %eax    # due to call gates, this is eflags, not eip..
-       movl CS(%ebp), %edx     # this is eip..
-       movl EFLAGS(%ebp), %ecx # and this is cs..
-       movl %eax,EFLAGS(%ebp)  #
-       movl %edx,EIP(%ebp)     # Now we move them to their "normal" places
-       movl %ecx,CS(%ebp)      #
-       GET_THREAD_INFO_WITH_ESP(%ebp)  # GET_THREAD_INFO
-       movl TI_exec_domain(%ebp), %edx # Get the execution domain
-       call *EXEC_DOMAIN_handler(%edx) # Call the handler for the domain
-       addl $4, %esp
-       popl %eax
-       jmp resume_userspace
-
-ENTRY(lcall27)
-       pushfl                  # We get a different stack layout with call
-                               # gates, which has to be cleaned up later..
-       pushl %eax
-       SAVE_ALL
-       movl %esp, %ebp
-       pushl %ebp
-       pushl $0x27
-       jmp do_lcall
-
-
 ENTRY(ret_from_fork)
        pushl %eax
        call schedule_tail
index e8889024ff2835557ee2637a8c8ae11eb1c23ef2..6529d61a5bd7bcbb717622de35c3df69b61d70a2 100644 (file)
@@ -57,8 +57,6 @@
 #include "mach_traps.h"
 
 asmlinkage int system_call(void);
-asmlinkage void lcall7(void);
-asmlinkage void lcall27(void);
 
 struct desc_struct default_ldt[] = { { 0, 0 }, { 0, 0 }, { 0, 0 },
                { 0, 0 }, { 0, 0 } };
@@ -1015,11 +1013,6 @@ static void __init set_system_gate(unsigned int n, void *addr)
        _set_gate(idt_table+n,15,3,addr,__KERNEL_CS);
 }
 
-static void __init set_call_gate(void *a, void *addr)
-{
-       _set_gate(a,12,3,addr,__KERNEL_CS);
-}
-
 static void __init set_task_gate(unsigned int n, unsigned int gdt_entry)
 {
        _set_gate(idt_table+n,5,0,0,(gdt_entry<<3));
@@ -1063,13 +1056,6 @@ void __init trap_init(void)
 
        set_system_gate(SYSCALL_VECTOR,&system_call);
 
-       /*
-        * default LDT is a single-entry callgate to lcall7 for iBCS
-        * and a callgate to lcall27 for Solaris/x86 binaries
-        */
-       set_call_gate(&default_ldt[0],lcall7);
-       set_call_gate(&default_ldt[4],lcall27);
-
        /*
         * Should be a barrier for any external CPU state.
         */