From: Jiang Liu <liuj97@gmail.com>
To: Taku Izumi <izumi.taku@jp.fujitsu.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>,
Yinghai Lu <yinghai@kernel.org>,
Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>,
Don Dutile <ddutile@redhat.com>,
Keping Chen <chenkeping@huawei.com>,
linux-pci@vger.kernel.org
Subject: Re: [PATCH v5 0/6] PCI, x86: update MMCFG information when hot-plugging PCI host bridges
Date: Wed, 09 May 2012 00:58:13 +0800 [thread overview]
Message-ID: <4FA950A5.6040106@gmail.com> (raw)
In-Reply-To: <20120508172153.b67a8cc6.izumi.taku@jp.fujitsu.com>
Hi Taku,
Thanks for testing. Could you please help to try the patch below?
diff --git a/arch/x86/pci/mmconfig-shared.c b/arch/x86/pci/mmconfig-shared.c
index a8da5d4..2551586 100644
--- a/arch/x86/pci/mmconfig-shared.c
+++ b/arch/x86/pci/mmconfig-shared.c
@@ -708,6 +708,13 @@ int __devinit pci_mmconfig_insert(int segment, int start, int end
if (cfg) {
if (cfg->start_bus <= start && cfg->end_bus >= end) {
rc = -EEXIST;
+ } else if (!addr) {
+ /*
+ * With some legacy BIOSes, the MCFG table only
+ * partially covers bus ranges returned by
+ * root bridges' _CRS method.
+ */
+ rc = -EEXIST;
} else {
printk(KERN_WARNING PREFIX
"MMCONFIG for domain %04x [bus %02x-%02x] "
On 05/08/2012 04:21 PM, Taku Izumi wrote:
>
> Hi Jiang,
>
> I tested this pachset.
> (to be honest, as I used Bjorn tree, I changed a little of Patch6/6
> to apply to his tree.)
>
> My machine failed to boot after applied your patchset.
> The reason is:
> My machine's MCFG table shows that End bus number is 0x13.
>
> [000h 0000 4] Signature : "MCFG" /* Memory Mapped Configuration table */
> [004h 0004 4] Table Length : 00000040
> [008h 0008 1] Revision : 01
> [009h 0009 1] Checksum : 3E
> [00Ah 0010 6] Oem ID : "PTLTD "
> [010h 0016 8] Oem Table ID : " MCFG "
> [018h 0024 4] Oem Revision : 06040001
> [01Ch 0028 4] Asl Compiler ID : " LTP"
> [020h 0032 4] Asl Compiler Revision : 00000000
>
> [024h 0036 8] Reserved : 0000000000000000
>
> [02Ch 0044 8] Base Address : 00000000F0000000
> [034h 0052 2] Segment Group Number : 0000
> [036h 0054 1] Start Bus Number : 00
> [037h 0055 1] End Bus Number : 13
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> [038h 0056 4] Reserved : 00000000
>
> But CRS shows bus range is 0x00 - 0xff. So arch_acpi_pci_root_add() failed
> because pci_mmconfig_insert() returns not -EEXIST but -EINVAL.
>
> [ 0.094236] PCI: MMCONFIG for domain 0000 [bus 00-ff] conflicts with domain 0000 [bus 00-13]
>
> int __devinit pci_mmconfig_insert(int segment, int start, int end, u64 addr)
> {
> ..
> (snip)
> ...
> mutex_lock(&pci_mmcfg_lock);
> cfg = pci_mmconfig_lookup(segment, start);
> if (cfg) {
> if (cfg->start_bus <= start && cfg->end_bus >= end) {
> rc = -EEXIST;
> } else {
> printk(KERN_WARNING PREFIX
> "MMCONFIG for domain %04x [bus %02x-%02x] "
> "conflicts with domain %04x [bus %02x-%02x]\n",
> segment, start, end,
> cfg->segment, cfg->start_bus, cfg->end_bus);
> }
> goto out;
>
>
> My impression is my machine's firmware is broken.
> Howerver my machine boots well without your patchset. So I report as a problem.
>
>
> Best regards,
> Taku Izumi <izumi.taku@jp.fujitsu.com>
>
next prev parent reply other threads:[~2012-05-08 16:58 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-05 3:00 [PATCH v5 0/6] PCI, x86: update MMCFG information when hot-plugging PCI host bridges Jiang Liu
2012-05-05 3:00 ` [PATCH v5 1/6] PCI, x86: split out pci_mmcfg_check_reserved() for code reuse Jiang Liu
2012-05-05 3:00 ` [PATCH v5 2/6] PCI, x86: split out pci_mmconfig_alloc() " Jiang Liu
2012-05-05 3:00 ` [PATCH v5 3/6] PCI, x86: use RCU list to protect mmconfig list Jiang Liu
2012-05-05 3:00 ` [PATCH v5 4/6] PCI, x86: introduce pci_mmcfg_arch_map()/pci_mmcfg_arch_unmap() Jiang Liu
2012-05-05 3:00 ` [PATCH v5 5/6] PCI, x86: introduce pci_mmconfig_insert()/delete() for PCI root bridge hotplug Jiang Liu
2012-05-18 16:30 ` Bjorn Helgaas
2012-05-05 3:00 ` [PATCH v5 6/6] PCI, ACPI, x86: update MMCFG information when hot-plugging PCI host bridges Jiang Liu
2012-05-18 16:03 ` Bjorn Helgaas
2012-05-18 16:56 ` Jiang Liu
2012-05-08 8:21 ` [PATCH v5 0/6] PCI, " Taku Izumi
2012-05-08 16:28 ` Bjorn Helgaas
2012-05-08 16:58 ` Jiang Liu [this message]
2012-05-09 7:21 ` Taku Izumi
2012-05-09 10:30 ` Jiang Liu
2012-05-18 16:36 ` Bjorn Helgaas
2012-05-18 16:59 ` Jiang Liu
2012-05-21 1:45 ` Taku Izumi
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=4FA950A5.6040106@gmail.com \
--to=liuj97@gmail.com \
--cc=bhelgaas@google.com \
--cc=chenkeping@huawei.com \
--cc=ddutile@redhat.com \
--cc=izumi.taku@jp.fujitsu.com \
--cc=kaneshige.kenji@jp.fujitsu.com \
--cc=linux-pci@vger.kernel.org \
--cc=yinghai@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).