public inbox for linux-arch@vger.kernel.org
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: linux-pci <linux-pci@vger.kernel.org>
Cc: Jesse Barnes <jesse.barnes@intel.com>,
	Linux Arch list <linux-arch@vger.kernel.org>
Subject: PCIBIOS_MIN_IO/MEM problem
Date: Tue, 11 Nov 2008 15:56:55 +1100	[thread overview]
Message-ID: <1226379415.7530.94.camel@pasglop> (raw)

Hi !

I have a problem on platforms with multiple PCI domains and allocating
resources.

The mechanism of having the arch set PCIBIOS_MIN_IO and PCIBIOS_MIN_MEM
to avoid allocating things over the legacy areas among other things
doesn't work well for us.

The reason is that on platforms where resource addresses are remapped
because the PCI bus isn't mapped 1:1, the values of the ranges we try
to avoid (typically 0...4K for IO space and legacy VGA memory) is
different from one domain to the next.

Right now, I'm doing a workaround for .28 that will reserve those
regions on some platforms before the allocation occurs, but it's a bit
fishy, especially it gives strange results when using things like legacy
IDE PCI cards that really want to allocate in those areas.

Ideally, we would need to pass the pci_bus pointer to those macros.

Thus, is there any objection to me replacing those accross the board
with something like that ?

	resource_size_t pcibios_min_assign_io(struct pci_bus *bus)
	resource_size_t pcibios_min_assign_mem(struct pci_bus *bus)

Please holler if you have objections before I start fixing everybody :-)

Cheers,
Ben.

             reply	other threads:[~2008-11-11  5:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-11  4:56 Benjamin Herrenschmidt [this message]
2008-11-13 19:33 ` PCIBIOS_MIN_IO/MEM problem Jesse Barnes
2008-11-13 19:33   ` Jesse Barnes

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=1226379415.7530.94.camel@pasglop \
    --to=benh@kernel.crashing.org \
    --cc=jesse.barnes@intel.com \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    /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