Skip to contentSkip to conversation

x86/asm changes for v3.8

GIT PULL Ingo Molnar 1 participant 1 message Dec 11, 2012

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Linus,

Please pull the latest x86-asm-for-linus git tree from:

git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git x86-asm-for-linus

HEAD: 6c8d8b3c69cef1330e0c5cbc2a8b9268024927a0 x86_32: Return actual stack when requesting sp from regs

Two fixlets and a cleanup.

Thanks,

Ingo

------------------>
Ma Ling (1):
x86/asm: Clean up copy_page_*() comments and code

Salman Qazi (1):
x86: Don't clobber top of pt_regs in nested NMI

Steven Rostedt (1):
x86_32: Return actual stack when requesting sp from regs

 arch/x86/include/asm/ptrace.h |   9 ++++
 arch/x86/kernel/entry_64.S    |  41 ++++++++++-----
 arch/x86/lib/copy_page_64.S   | 120 +++++++++++++++++++++---------------------
 3 files changed, 95 insertions(+), 75 deletions(-)
arch/x86/include/asm/ptrace.h +9 -0
index dcfde52..2233713 100644
@@ -246,6 +246,15 @@ static inline unsigned long regs_get_register(struct pt_regs *regs,
 {
 	if (unlikely(offset > MAX_REG_OFFSET))
 		return 0;
+#ifdef CONFIG_X86_32
+	/*
+	 * Traps from the kernel do not save sp and ss.
+	 * Use the helper function to retrieve sp.
+	 */
+	if (offset == offsetof(struct pt_regs, sp) &&
+	    regs->cs == __KERNEL_CS)
+		return kernel_stack_pointer(regs);
+#endif
 	return *(unsigned long *)((unsigned long)regs + offset);
 }
 
arch/x86/kernel/entry_64.S +27 -14

91 lines not on this page · raw message

arch/x86/lib/copy_page_64.S +59 -61

157 lines not on this page · raw message