Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull cpu idle fixes from Thomas Gleixner:
- Add a missing irq enable. Fallout of the idle conversion
- Fix stackprotector wreckage caused by the idle conversion

* 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
idle: Enable interrupts in the weak arch_cpu_idle() implementation
idle: Add the stack canary init to cpu_startup_entry()

+17 -12
-12
arch/x86/kernel/process.c
··· 277 277 } 278 278 #endif 279 279 280 - void arch_cpu_idle_prepare(void) 281 - { 282 - /* 283 - * If we're the non-boot CPU, nothing set the stack canary up 284 - * for us. CPU0 already has it initialized but no harm in 285 - * doing it again. This is a good place for updating it, as 286 - * we wont ever return from this function (so the invalid 287 - * canaries already on the stack wont ever trigger). 288 - */ 289 - boot_init_stack_canary(); 290 - } 291 - 292 280 void arch_cpu_idle_enter(void) 293 281 { 294 282 local_touch_nmi();
+17
kernel/cpu/idle.c
··· 5 5 #include <linux/cpu.h> 6 6 #include <linux/tick.h> 7 7 #include <linux/mm.h> 8 + #include <linux/stackprotector.h> 8 9 9 10 #include <asm/tlb.h> 10 11 ··· 59 58 void __weak arch_cpu_idle(void) 60 59 { 61 60 cpu_idle_force_poll = 1; 61 + local_irq_enable(); 62 62 } 63 63 64 64 /* ··· 114 112 115 113 void cpu_startup_entry(enum cpuhp_state state) 116 114 { 115 + /* 116 + * This #ifdef needs to die, but it's too late in the cycle to 117 + * make this generic (arm and sh have never invoked the canary 118 + * init for the non boot cpus!). Will be fixed in 3.11 119 + */ 120 + #ifdef CONFIG_X86 121 + /* 122 + * If we're the non-boot CPU, nothing set the stack canary up 123 + * for us. The boot CPU already has it initialized but no harm 124 + * in doing it again. This is a good place for updating it, as 125 + * we wont ever return from this function (so the invalid 126 + * canaries already on the stack wont ever trigger). 127 + */ 128 + boot_init_stack_canary(); 129 + #endif 117 130 current_set_polling(); 118 131 arch_cpu_idle_prepare(); 119 132 cpu_idle_loop();