mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Matthew Wilcox <matthew@wil.cx>
To: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Justin Mattock <justinmattock@gmail.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linux PCI <linux-pci@vger.kernel.org>,
	Jesse Barnes <jbarnes@virtuousgeek.org>
Subject: Re: pci 0000:01:00.0: BAR 6: no parent found for of device [0xfffe0000-0xffffffff]
Date: Wed, 24 Jun 2009 13:50:30 -0600	[thread overview]
Message-ID: <20090624195030.GS19977@parisc-linux.org> (raw)
In-Reply-To: <200906242130.07583.rjw@sisk.pl>

On Wed, Jun 24, 2009 at 09:30:07PM +0200, Rafael J. Wysocki wrote:
> (Adding CC to linux-pci)

Thanks Rafael.

> On Wednesday 24 June 2009, Justin Mattock wrote:
> > (just pulled the latest git)
> > And am seeing this:
> 
> Where pci 0000:01:00.0 and 0000:02:00.0 are what?
> 
> > [    0.696001] pci 0000:01:00.0: BAR 6: no parent found for of device
> > [0xfffe0000-0xffffffff]

So the message is coming from pci_claim_resource, and
if you bother to bisect, you'll track it back to my commit
a76117dfd687ec4be0a9a05214f3009cc5f73a42 .  What's going on here, since
this is BAR 6, is we have a ROM which has been mapped high, and then
not unmapped.  The BAR doesn't fit in the parent's window, so the code
is rightly declining to allocate the BAR.

Before my patch, we silently didn't allocate the BARs.  Now we print
a message.  I wonder what to do ... we could silence this warning in
pci_claim_resource (patch below).  Or we could declare this to be a bug,
and fix it by disabling the ROM BAR (by clearing bit 0).

I'm agnostic ... anyone have any preferences?

----

Silence spurious warning about ROM BARs

We shouldn't warn about not being able to allocate ROM BARs.  They are
often deliberately mapped outside the range of parent windows in order
to disable them.

Also fix the message to delete the spurious 'of'.

Signed-off-by: Matthew Wilcox <willy@linux.intel.com>

diff --git a/drivers/pci/setup-res.c b/drivers/pci/setup-res.c
index 1240351..d1b980c 100644
--- a/drivers/pci/setup-res.c
+++ b/drivers/pci/setup-res.c
@@ -109,8 +109,8 @@ int pci_claim_resource(struct pci_dev *dev, int resource)
 	if (root != NULL)
 		err = insert_resource(root, res);
 
-	if (err) {
-		dev_err(&dev->dev, "BAR %d: %s of %s %pR\n",
+	if (err && (resource != 6)) {
+		dev_err(&dev->dev, "BAR %d: %s %s %pR\n",
 			resource,
 			root ? "address space collision on" :
 				"no parent found for",

-- 
Matthew Wilcox				Intel Open Source Technology Centre
"Bill, look, we understand that you're interested in selling us this
operating system, but compare it to ours.  We can't possibly take such
a retrograde step."

  reply	other threads:[~2009-06-24 19:50 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-24 17:27 Justin Mattock
2009-06-24 19:30 ` Rafael J. Wysocki
2009-06-24 19:50   ` Matthew Wilcox [this message]
2009-06-24 20:04     ` Jesse Barnes
2009-06-24 20:41       ` Justin Mattock
2009-06-24 19:32 ` Jesse Barnes
2009-06-24 19:42   ` Justin Mattock

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090624195030.GS19977@parisc-linux.org \
    --to=matthew@wil.cx \
    --cc=jbarnes@virtuousgeek.org \
    --cc=justinmattock@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=rjw@sisk.pl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®