PCI changes 2.6.26 => 2.6.28
Gary Thomas
gary at mlbassoc.com
Fri Apr 24 08:27:54 EST 2009
Kumar Gala wrote:
>
> On Apr 23, 2009, at 9:24 AM, Gary Thomas wrote:
>
>> I have found the culprit - in arch/powerpc/kernel/pci_32.c
>>
>> static void
>> fixup_hide_host_resource_fsl(struct pci_dev *dev)
>> {
>> int i, class = dev->class >> 8;
>>
>> #if 0
>> if ((class == PCI_CLASS_PROCESSOR_POWERPC ||
>> class == PCI_CLASS_BRIDGE_OTHER) &&
>> #else
>> if ((class == PCI_CLASS_PROCESSOR_POWERPC) &&
>> #endif
>> (dev->hdr_type == PCI_HEADER_TYPE_NORMAL) &&
>> (dev->bus->parent == NULL)) {
>> for (i = 0; i < DEVICE_COUNT_RESOURCE; i++) {
>> dev->resource[i].start = 0;
>> dev->resource[i].end = 0;
>> dev->resource[i].flags = 0;
>> }
>> }
>> }
>> DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_MOTOROLA, PCI_ANY_ID,
>> fixup_hide_host_resource_fsl);
>> DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_FREESCALE, PCI_ANY_ID,
>> fixup_hide_host_resource_fsl);
>>
>> This function is now (the #if 0 case is in 2.6.28) tossing out
>> the memory resources used by the PCI bridge itself. This makes
>> everything fall over, at least on my 834x platform.
>>
>> This change was applied 2008-10-08, but it seems incorrect on the 834x.
>
> Its not. The PCI subsystem shouldn't be allocating or seeing the PHBs
> resources.
>
>>> Are you using u-boot to boot? If so is the board port public?
>>
>> My systems use RedBoot (I'm the original author of RedBoot, so one would
>> expect that). At this moment, the code isn't public, sorry.
>
> Ok. Not sure if RedBoot has a simple memory dump command, but if you
> can dump the IMMR registers for PCI (0x8400 - IOS and 0x8500 - PCI1).
> (I'm assuming PCI1 is the one you are using). From IOS I wanted the
I don't think any of this matters. It turns out that even
the 2.6.26 kernel fails on an identical board with a newer
revision of the 8347 chip. I'm sure that the problem is
that the Coral-P fails when mapped to 0 (PCI relative).
I couldn't find another reliable way to get the Coral-P assigned
an address other than 0, so I'm happy accepting the work around
of allowing the kernel to map those windows, even if it's not
necessary.
For completeness, here are the values you asked for:
pcilawbar0 : 0xc0000000 -1073741824
pcilawar : 0x8000001b -2147483621
pcilawbar1 : 0xb8000000 -1207959552
pcilawar1 : 0x80000013 -2147483629
8347>md 0xff008400
ff008400 : 00000000 00000000 000c0000 00000000 ................
ff008410 : 800f0000 00000000 00000000 00000000 ................
ff008420 : 000b8000 00000000 c00fff00 00000000 ................
ff008430 : 00000000 00000000 00000000 00000000 ................
ff008440 : 00000000 00000000 00000000 00000000 ................
ff008450 : 00000000 00000000 00000000 00000000 ................
ff008460 : 00000000 00000000 00000000 00000000 ................
ff008470 : 00000000 00000000 00000000 00000000 ................
ff008480 : 00000000 00000000 00000000 00000000 ................
ff008490 : 00000000 00000000 00000000 00000000 ................
ff0084a0 : 00000000 00000000 00000000 00000000 ................
ff0084b0 : 00000000 00000000 00000000 00000000 ................
ff0084c0 : 00000000 00000000 00000000 00000000 ................
ff0084d0 : 00000000 00000000 00000000 00000000 ................
ff0084e0 : 00000000 00000000 00000000 00000000 ................
ff0084f0 : 00000001 00010006 00000000 00000000 ................
8347>md 0xff008500
ff008500 : 00000000 00000000 00000000 00000000 ................
ff008510 : 00000000 00000000 00000000 00000000 ................
ff008520 : 00000001 00000000 00000001 00000000 ................
ff008530 : 00000000 00000000 00000000 00000000 ................
ff008540 : 00000000 00000000 00000000 00000000 ................
ff008550 : 00000000 00000000 00000000 00000000 ................
ff008560 : a005501a 00000000 00000000 00000000 ..P.............
ff008570 : 00000000 00000000 00000000 00000000 ................
ff008580 : 00000000 00000000 00000000 00000000 ................
ff008590 : 00000000 00000000 00000000 00000000 ................
ff0085a0 : 00000000 00000000 00000000 00000000 ................
ff0085b0 : 00000000 00000000 00000000 00000000 ................
ff0085c0 : 00000000 00000000 00000000 00000000 ................
ff0085d0 : 00000000 00000000 00000000 00000000 ................
ff0085e0 : 00000000 00000000 00000000 00000000 ................
ff0085f0 : 00000000 00000000 00000000 00000000 ................
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
More information about the Linuxppc-dev
mailing list