x86 fixes
Subsystems (2)
Linus,
Please pull the latest x86-fixes-for-linus git tree from:
git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git x86-fixes-for-linus
Thanks,
Ingo
------------------>
Eric Dumazet (1):
percpu, x86: Fix percpu_xchg_op()
Jesper Juhl (1):
x86-64: Don't use pointer to out-of-scope variable in dump_trace()
Yinghai Lu (1):
x86: Remove left over system_64.h
arch/x86/include/asm/percpu.h | 24 ++++++++++++------------ arch/x86/include/asm/system_64.h | 22 ---------------------- arch/x86/kernel/dumpstack_64.c | 2 +- 3 files changed, 13 insertions(+), 35 deletions(-) delete mode 100644 arch/x86/include/asm/system_64.h
arch/x86/include/asm/percpu.h +12 -12
@@ -273,34 +273,34 @@ do { \typeof (var) pxo_new__ = (nval); \switch (sizeof (var)) { \case 1 : \ - asm("\n1:mov "__percpu_arg(1)",%%al" \ - "\n\tcmpxchgb %2, "__percpu_arg(1) \ + asm("\n\tmov "__percpu_arg(1)",%%al" \ + "\n1:\tcmpxchgb %2, "__percpu_arg(1) \ "\n\tjnz 1b" \ - : "=a" (pxo_ret__), "+m" (var) \ + : "=&a" (pxo_ret__), "+m" (var) \ : "q" (pxo_new__) \ : "memory"); \ break; \ case 2: \ - asm("\n1:mov "__percpu_arg(1)",%%ax" \ - "\n\tcmpxchgw %2, "__percpu_arg(1) \ + asm("\n\tmov "__percpu_arg(1)",%%ax" \ + "\n1:\tcmpxchgw %2, "__percpu_arg(1) \ "\n\tjnz 1b" \ - : "=a" (pxo_ret__), "+m" (var) \ + : "=&a" (pxo_ret__), "+m" (var) \ : "r" (pxo_new__) \ : "memory"); \ break; \ case 4: \ - asm("\n1:mov "__percpu_arg(1)",%%eax" \ - "\n\tcmpxchgl %2, "__percpu_arg(1) \ + asm("\n\tmov "__percpu_arg(1)",%%eax" \ + "\n1:\tcmpxchgl %2, "__percpu_arg(1) \ "\n\tjnz 1b" \ - : "=a" (pxo_ret__), "+m" (var) \ + : "=&a" (pxo_ret__), "+m" (var) \ : "r" (pxo_new__) \ : "memory"); \ break; \ case 8: \ - asm("\n1:mov "__percpu_arg(1)",%%rax" \ - "\n\tcmpxchgq %2, "__percpu_arg(1) \ + asm("\n\tmov "__percpu_arg(1)",%%rax" \ + "\n1:\tcmpxchgq %2, "__percpu_arg(1) \ "\n\tjnz 1b" \ - : "=a" (pxo_ret__), "+m" (var) \ + : "=&a" (pxo_ret__), "+m" (var) \: " r" (pxo_new__) \ : " memory"); \ break; \
arch/x86/include/asm/system_64.h deleted +0 -22
@@ -1,22 +0,0 @@ -#ifndef _ASM_X86_SYSTEM_64_H -#define _ASM_X86_SYSTEM_64_H - -#include <asm/segment.h> -#include <asm/cmpxchg.h> - - -static inline unsigned long read_cr8 (void ) -{ -unsigned long cr8; - asmvolatile ("movq %%cr8,%0" :"=r" (cr8)); -return cr8; -} - -static inline void write_cr8 (unsigned long val) -{ - asmvolatile ("movq %0,%%cr8" ::"r" (val) :"memory" ); -} - -#include <linux/irqflags.h> - -#endif /* _ASM_X86_SYSTEM_64_H */
arch/x86/kernel/dumpstack_64.c +1 -1
@@ -149,13 +149,13 @@ void dump_trace(struct task_struct *task,unsigned used =0 ;struct thread_info *tinfo;int graph =0 ; +unsigned long dummy;unsigned long bp;if (!task) task = current;if (!stack) { -unsigned long dummy; stack = &dummy;if (task && task != current) stack = (unsigned long *)task->thread.sp;