From: "Rafael J. Wysocki" <rjw@rjwysocki.net>
To: Jiang Liu <jiang.liu@linux.intel.com>
Cc: Thomas Voegtle <tv@lio96.de>, Hudd <hedede.l@gmail.com>,
Prakash Punnoor <prakash@punnoor.de>,
Francois Romieu <romieu@fr.zoreil.com>,
Dave Airlie <airlied@gmail.com>,
Marcel Holtmann <marcel@holtmann.org>,
Bjorn Helgaas <bhelgaas@google.com>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>,
x86@kernel.org, LKML <linux-kernel@vger.kernel.org>,
linux-pci@vger.kernel.org, linux-acpi@vger.kernel.org,
Lv Zheng <lv.zheng@intel.com>
Subject: Re: [Bugfix 1/2] x86/PCI/ACPI: Ignore resources consumed by host bridge itself
Date: Wed, 04 Mar 2015 15:25:17 +0100 [thread overview]
Message-ID: <10992995.sRFs1pmEco@vostro.rjw.lan> (raw)
In-Reply-To: <1425458832-28777-1-git-send-email-jiang.liu@linux.intel.com>
On Wednesday, March 04, 2015 04:47:11 PM Jiang Liu wrote:
> When parsing resources for PCI host bridge, we should ignore resources
> consumed by host bridge itself and only report window resources available
> to child PCI busses.
>
> Signed-off-by: Jiang Liu <jiang.liu@linux.intel.com>
Queued up for 4.0-rc3, thanks!
> ---
> arch/x86/pci/acpi.c | 11 ++++++++---
> 1 file changed, 8 insertions(+), 3 deletions(-)
>
> diff --git a/arch/x86/pci/acpi.c b/arch/x86/pci/acpi.c
> index 6ac273832f28..e4695985f9de 100644
> --- a/arch/x86/pci/acpi.c
> +++ b/arch/x86/pci/acpi.c
> @@ -331,7 +331,7 @@ static void probe_pci_root_info(struct pci_root_info *info,
> struct list_head *list)
> {
> int ret;
> - struct resource_entry *entry;
> + struct resource_entry *entry, *tmp;
>
> sprintf(info->name, "PCI Bus %04x:%02x", domain, busnum);
> info->bridge = device;
> @@ -345,8 +345,13 @@ static void probe_pci_root_info(struct pci_root_info *info,
> dev_dbg(&device->dev,
> "no IO and memory resources present in _CRS\n");
> else
> - resource_list_for_each_entry(entry, list)
> - entry->res->name = info->name;
> + resource_list_for_each_entry_safe(entry, tmp, list) {
> + if ((entry->res->flags & IORESOURCE_WINDOW) == 0 ||
> + (entry->res->flags & IORESOURCE_DISABLED))
> + resource_list_destroy_entry(entry);
> + else
> + entry->res->name = info->name;
> + }
> }
>
> struct pci_bus *pci_acpi_scan_root(struct acpi_pci_root *root)
>
--
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.
prev parent reply other threads:[~2015-03-04 14:01 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-04 8:47 [Bugfix 1/2] x86/PCI/ACPI: Ignore resources consumed by host bridge itself Jiang Liu
2015-03-04 8:47 ` [Bugfix 2/2] x86/PCI/ACPI: Relax ACPI resource descriptor checks to work around BIOS bugs Jiang Liu
2015-03-04 14:26 ` Rafael J. Wysocki
2015-03-04 14:25 ` Rafael J. Wysocki [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=10992995.sRFs1pmEco@vostro.rjw.lan \
--to=rjw@rjwysocki.net \
--cc=airlied@gmail.com \
--cc=bhelgaas@google.com \
--cc=hedede.l@gmail.com \
--cc=hpa@zytor.com \
--cc=jiang.liu@linux.intel.com \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lv.zheng@intel.com \
--cc=marcel@holtmann.org \
--cc=mingo@redhat.com \
--cc=prakash@punnoor.de \
--cc=romieu@fr.zoreil.com \
--cc=tglx@linutronix.de \
--cc=tv@lio96.de \
--cc=x86@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