linux-mips
[Top] [All Lists]

Re: Linux MIPS PCI resource sanity check

To: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Subject: Re: Linux MIPS PCI resource sanity check
From: Michael Buesch <mb@bu3sch.de>
Date: Sat, 16 Feb 2008 11:55:38 +0100
Cc: ralf@linux-mips.org, linux-mips@linux-mips.org
In-reply-to: <47B6BFD4.5050404@ru.mvista.com>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <200802161139.10791.mb@bu3sch.de> <47B6BFD4.5050404@ru.mvista.com>
Sender: linux-mips-bounce@linux-mips.org
User-agent: KMail/1.9.6 (enterprise 0.20070907.709405)
On Saturday 16 February 2008 11:49:56 Sergei Shtylyov wrote:
> Michael Buesch wrote:
> 
> > There's a sanity check in pcibios_enable_resources() that looks like this:
> 
> >     r = &dev->resource[idx];
> >     if (!r->start && r->end) {
> >             printk(KERN_ERR "PCI: Device %s not available because of 
> > resource collisions\n", pci_name(dev));
> >             return -EINVAL;
> >     }
> > 
> > What is this check actually doing?
> 
>    It makes sure that a PCI resource is allocated (base of 0 means that it's 
> unallocated due to previously detected resource conlict (or some other 
> reason).

So well, that's what the error message already told me. ;)
But where is the actual bug? I mean, this tells me there's some collision
for this MMIO resource. Still, I can access the MMIO space just fine.

> > It triggers for me on a BCM4318 device which is behind a BCM4710 PCI bridge.
> > r->start is 0 and r->end is 0x1FFF when this triggers.
> > If I simply comment out that check the device is detected correctly
> > and seems to initialize just fine.
> 
>     No, that failnig resource should be relocated.

How?

-- 
Greetings Michael.

<Prev in Thread] Current Thread [Next in Thread>