diff options
author | Jan Beulich <JBeulich@novell.com> | 2010-09-02 09:04:16 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-09-03 02:14:10 -0400 |
commit | a34107b5577968dc53cf9c2195c7c2d4a2caf9ce (patch) | |
tree | 7aaff7564ed14eb14044d8ee4b9ece47921ceca1 /arch/x86/kernel/entry_32.S | |
parent | b1cccb1bb01dc1cb89f58723a58c3d4988d44d94 (diff) |
i386: Add unwind directives to syscall ptregs stubs
When these stubs are actual functions (i.e. having a return
instruction) and have stack manipulation instructions in them,
they should also be annotated to allow unwinding through them.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Acked-by: Alexander van Heukelum <heukelum@fastmail.fm>
LKML-Reference: <4C7FBCF00200007800013F99@vpn.id2.novell.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/entry_32.S')
-rw-r--r-- | arch/x86/kernel/entry_32.S | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/arch/x86/kernel/entry_32.S b/arch/x86/kernel/entry_32.S index 227d00920d2f..d9b950ee5590 100644 --- a/arch/x86/kernel/entry_32.S +++ b/arch/x86/kernel/entry_32.S | |||
@@ -750,14 +750,18 @@ ptregs_##name: \ | |||
750 | #define PTREGSCALL3(name) \ | 750 | #define PTREGSCALL3(name) \ |
751 | ALIGN; \ | 751 | ALIGN; \ |
752 | ptregs_##name: \ | 752 | ptregs_##name: \ |
753 | CFI_STARTPROC; \ | ||
753 | leal 4(%esp),%eax; \ | 754 | leal 4(%esp),%eax; \ |
754 | pushl %eax; \ | 755 | pushl_cfi %eax; \ |
755 | movl PT_EDX(%eax),%ecx; \ | 756 | movl PT_EDX(%eax),%ecx; \ |
756 | movl PT_ECX(%eax),%edx; \ | 757 | movl PT_ECX(%eax),%edx; \ |
757 | movl PT_EBX(%eax),%eax; \ | 758 | movl PT_EBX(%eax),%eax; \ |
758 | call sys_##name; \ | 759 | call sys_##name; \ |
759 | addl $4,%esp; \ | 760 | addl $4,%esp; \ |
760 | ret | 761 | CFI_ADJUST_CFA_OFFSET -4; \ |
762 | ret; \ | ||
763 | CFI_ENDPROC; \ | ||
764 | ENDPROC(ptregs_##name) | ||
761 | 765 | ||
762 | PTREGSCALL1(iopl) | 766 | PTREGSCALL1(iopl) |
763 | PTREGSCALL0(fork) | 767 | PTREGSCALL0(fork) |
@@ -772,15 +776,19 @@ PTREGSCALL1(vm86old) | |||
772 | /* Clone is an oddball. The 4th arg is in %edi */ | 776 | /* Clone is an oddball. The 4th arg is in %edi */ |
773 | ALIGN; | 777 | ALIGN; |
774 | ptregs_clone: | 778 | ptregs_clone: |
779 | CFI_STARTPROC | ||
775 | leal 4(%esp),%eax | 780 | leal 4(%esp),%eax |
776 | pushl %eax | 781 | pushl_cfi %eax |
777 | pushl PT_EDI(%eax) | 782 | pushl_cfi PT_EDI(%eax) |
778 | movl PT_EDX(%eax),%ecx | 783 | movl PT_EDX(%eax),%ecx |
779 | movl PT_ECX(%eax),%edx | 784 | movl PT_ECX(%eax),%edx |
780 | movl PT_EBX(%eax),%eax | 785 | movl PT_EBX(%eax),%eax |
781 | call sys_clone | 786 | call sys_clone |
782 | addl $8,%esp | 787 | addl $8,%esp |
788 | CFI_ADJUST_CFA_OFFSET -8 | ||
783 | ret | 789 | ret |
790 | CFI_ENDPROC | ||
791 | ENDPROC(ptregs_clone) | ||
784 | 792 | ||
785 | .macro FIXUP_ESPFIX_STACK | 793 | .macro FIXUP_ESPFIX_STACK |
786 | /* | 794 | /* |