Re: crash in init_ipic_sysfs on efika
flat view
From: Kumar Gala <hidden>
Date: 2008-03-20 15:16:00
On Mar 17, 2008, at 2:53 PM, Olaf Hering wrote:
quoted hunk ↗ jump to hunk
I cant reproduce this bug on my board, but: The global primary_ipic in arch/powerpc/sysdev/ipic.c can remain NULL if ipic_init() fails. init_ipic_sysfs() will crash in that case. Something like this may fix it: Index: linux-2.6.25-rc6/arch/powerpc/sysdev/ipic.c ===================================================================--- linux-2.6.25-rc6.orig/arch/powerpc/sysdev/ipic.c +++ linux-2.6.25-rc6/arch/powerpc/sysdev/ipic.c@@ -906,7 +906,7 @@ static int __init init_ipic_sysfs(void){ int rc; - if (!primary_ipic->regs) + if (!primary_ipic || !primary_ipic->regs) return -ENODEV; printk(KERN_DEBUG "Registering ipic with sysfs...\n");
We should look and see if we can change init_ipic_sysfs() from a subsys_initcall() to just getting called at the end of ipic_init(). - k