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 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc

Pull powerpc fixes from Benjamin Herrenschmidt:
"Whenever you have a chance between two dives, you might want to
consider pulling my merge branch to pickup a few fixes for 3.8 that
have been accumulating for the last couple of weeks (I was myself
travelling then on vacation).

Nothing major, just a handful of powerpc bug fixes that I consider
worth getting in before 3.8 goes final."

And I'll have everybody know that I'm not diving for several days yet.
Snif.

* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc:
powerpc: Max next_tb to prevent from replaying timer interrupt
powerpc: kernel/kgdb.c: Fix memory leakage
powerpc/book3e: Disable interrupt after preempt_schedule_irq
powerpc/oprofile: Fix error in oprofile power7_marked_instr_event() function
powerpc/pasemi: Fix crash on reboot
powerpc: Fix MAX_STACK_TRACE_ENTRIES too low warning for ppc32

+33 -5
+2
arch/powerpc/kernel/entry_32.S
··· 439 439 ret_from_kernel_thread: 440 440 REST_NVGPRS(r1) 441 441 bl schedule_tail 442 + li r3,0 443 + stw r3,0(r1) 442 444 mtlr r14 443 445 mr r3,r15 444 446 PPC440EP_ERR42
+13
arch/powerpc/kernel/entry_64.S
··· 664 664 ld r4,TI_FLAGS(r9) 665 665 andi. r0,r4,_TIF_NEED_RESCHED 666 666 bne 1b 667 + 668 + /* 669 + * arch_local_irq_restore() from preempt_schedule_irq above may 670 + * enable hard interrupt but we really should disable interrupts 671 + * when we return from the interrupt, and so that we don't get 672 + * interrupted after loading SRR0/1. 673 + */ 674 + #ifdef CONFIG_PPC_BOOK3E 675 + wrteei 0 676 + #else 677 + ld r10,PACAKMSR(r13) /* Get kernel MSR without EE */ 678 + mtmsrd r10,1 /* Update machine state */ 679 + #endif /* CONFIG_PPC_BOOK3E */ 667 680 #endif /* CONFIG_PREEMPT */ 668 681 669 682 .globl fast_exc_return_irq
+3 -2
arch/powerpc/kernel/kgdb.c
··· 154 154 static int kgdb_singlestep(struct pt_regs *regs) 155 155 { 156 156 struct thread_info *thread_info, *exception_thread_info; 157 - struct thread_info *backup_current_thread_info = \ 158 - (struct thread_info *)kmalloc(sizeof(struct thread_info), GFP_KERNEL); 157 + struct thread_info *backup_current_thread_info; 159 158 160 159 if (user_mode(regs)) 161 160 return 0; 162 161 162 + backup_current_thread_info = (struct thread_info *)kmalloc(sizeof(struct thread_info), GFP_KERNEL); 163 163 /* 164 164 * On Book E and perhaps other processors, singlestep is handled on 165 165 * the critical exception stack. This causes current_thread_info() ··· 185 185 /* Restore current_thread_info lastly. */ 186 186 memcpy(exception_thread_info, backup_current_thread_info, sizeof *thread_info); 187 187 188 + kfree(backup_current_thread_info); 188 189 return 1; 189 190 } 190 191
+7 -2
arch/powerpc/kernel/time.c
··· 494 494 set_dec(DECREMENTER_MAX); 495 495 496 496 /* Some implementations of hotplug will get timer interrupts while 497 - * offline, just ignore these 497 + * offline, just ignore these and we also need to set 498 + * decrementers_next_tb as MAX to make sure __check_irq_replay 499 + * don't replay timer interrupt when return, otherwise we'll trap 500 + * here infinitely :( 498 501 */ 499 - if (!cpu_online(smp_processor_id())) 502 + if (!cpu_online(smp_processor_id())) { 503 + *next_tb = ~(u64)0; 500 504 return; 505 + } 501 506 502 507 /* Conditionally hard-enable interrupts now that the DEC has been 503 508 * bumped to its maximum value
+1 -1
arch/powerpc/oprofile/op_model_power4.c
··· 52 52 for (pmc = 0; pmc < 4; pmc++) { 53 53 psel = mmcr1 & (OPROFILE_PM_PMCSEL_MSK 54 54 << (OPROFILE_MAX_PMC_NUM - pmc) 55 - * OPROFILE_MAX_PMC_NUM); 55 + * OPROFILE_PMSEL_FIELD_WIDTH); 56 56 psel = (psel >> ((OPROFILE_MAX_PMC_NUM - pmc) 57 57 * OPROFILE_PMSEL_FIELD_WIDTH)) & ~1ULL; 58 58 unit = mmcr1 & (OPROFILE_PM_UNIT_MSK
+7
arch/powerpc/platforms/pasemi/cpufreq.c
··· 236 236 237 237 static int pas_cpufreq_cpu_exit(struct cpufreq_policy *policy) 238 238 { 239 + /* 240 + * We don't support CPU hotplug. Don't unmap after the system 241 + * has already made it to a running state. 242 + */ 243 + if (system_state != SYSTEM_BOOTING) 244 + return 0; 245 + 239 246 if (sdcasr_mapbase) 240 247 iounmap(sdcasr_mapbase); 241 248 if (sdcpwr_mapbase)