From: Greg KH <greg@kroah.com>
To: linux-hotplug@vger.kernel.org
Subject: Re: About PCI hot-plugging & resource management
Date: Mon, 01 Feb 2010 20:38:56 +0000 [thread overview]
Message-ID: <20100201203856.GA21456@kroah.com> (raw)
In-Reply-To: <8506939B503B404A84BBB12293FC45F60681AA4E@emailbng3.jnpr.net>
On Mon, Feb 01, 2010 at 12:24:41PM +0530, Rajat Jain wrote:
> Hello,
>
> Pardon me for asking few basic questions, but I'm trying to understand
> the basics of the PCI hot-plugging:
>
> 1) From what I understand, Linux kernel does not use the PCI resource
> allocation done by the BIOS or the boot loader. Rather it enumerates the
> PCI buses and devices again and thus the PCI bus numbers and the
> resources that are allocated may differ from what was done by the BIOS,
> right?
No, not always. It depends on the platform involved as to what it does.
> 2) Now as per my understanding when a new device is added later on [and
> that device may a whole new PCI tree including PCI bridges and other
> devices on it], there will be a need to allocate PCI bus numbers, and
> PCI resources to the new devices.
>
> As far as I understand, the PCI bus numbers needs to be within the range
> of subordinate bus numbers of the parent PCI bridges, the same is also
> true for PCI memory resources I think. Hence in a nutshell, there will
> be a need for having reserved "holes" in the PCI resource space. Is my
> understanding correct?
>
> 3) What approach does Linux take towards dealing with the above
> situation? I'd appreciate if you could please point me to appropriate
> links or code references...
The PCI Hotplug controller is responsible for ensuring that there is a
range of resources and bus numbers for any PCI devices that are added
after the machine is up and running. Or the BIOS/firmware if that is
what the platform is using. Either way, it's not the kernel's job to
reserve space for new PCI devices.
See the PCI hotplug spec from the PCI sig if you have questions about
the details.
hope this helps,
greg k-h
prev parent reply other threads:[~2010-02-01 20:38 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-01 7:06 About PCI hot-plugging & resource management Rajat Jain
2010-02-01 20:38 ` Greg KH [this message]
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=20100201203856.GA21456@kroah.com \
--to=greg@kroah.com \
--cc=linux-hotplug@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;
as well as URLs for NNTP newsgroup(s).