[ELDK] ppc boot fails at PCI detection.
Larry Johnson
lrj at acm.org
Tue Mar 3 03:07:23 CET 2009
renjith kumar wrote:
> hi ,
>
> I get kernel hanging problem after "*Uncompressing Kernel Image ... OK*".
> message. (Not always , but most of the time :( ..)
> I use the ppc_4xxFP based Sequoia board with 2 PCI slots.
>
> When I remove/comment the function , sequoia_setup_hose() for PCI card
> detection ,
> the kernel boots without any problem (But without PCI support).
>
> I was just wondering , Has anybody experienced similar problem ??
> Was there any problem with PCI part, for power PC reported before ??
There is a known bug in the latest version of Linux kernel file
arch/powerpc/sysdev/ppc4xx_pci.c that causes the PCI to fail for at
least some PPC440 processors, including the PPC440EPx. Until a general
solution is added to the Linux distribution, I have been using the
following patch on my PPC440EPx board:
diff --git a/arch/powerpc/sysdev/ppc4xx_pci.c b/arch/powerpc/sysdev/ppc4xx_pci.c
index 77fae5f..1d87e5e 100644
--- a/arch/powerpc/sysdev/ppc4xx_pci.c
+++ b/arch/powerpc/sysdev/ppc4xx_pci.c
@@ -204,8 +204,9 @@ static int __init ppc4xx_setup_one_pci_PMM(struct pci_controller *hose,
{
u32 ma, pcila, pciha;
- if ((plb_addr + size) > 0xffffffffull || !is_power_of_2(size) ||
- size < 0x1000 || (plb_addr & (size - 1)) != 0) {
+ if ((plb_addr + size - (1ull << 32)) > (1ull << 32) - 1ull ||
+ !is_power_of_2(size) || size < 0x1000 ||
+ (plb_addr & (size - 1)) != 0) {
printk(KERN_WARNING "%s: Resource out of range\n",
hose->dn->full_name);
return -1;
Please note that I have no idea whether this patch would work for
processors other than the EPx/GPx. I'd recommend that you apply this
patch and rebuild your kernel to see if it helps.
Best regards,
Larry Johnson
More information about the eldk
mailing list