From: Yinghai Lu <yinghai@kernel.org>
To: Ulrich Drepper <drepper@gmail.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>,
jbarnes@virtuousgeek.org,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
lenb@kernel.org, x86@kernel.org, linux-pci@vger.kernel.org
Subject: Re: SNB PCI root information
Date: Mon, 18 Jun 2012 16:40:42 -0700 [thread overview]
Message-ID: <CAE9FiQVzKr+nyBh=8-v+HEDF=7JqN2CqdTNx1=LHTq=c_OyZvg@mail.gmail.com> (raw)
In-Reply-To: <CAOPLpQeJTfB2UNy3O9FgRCyZb=LyMqd0SOsz7qDM0Ur_sfeNhg@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 914 bytes --]
On Mon, Jun 18, 2012 at 3:30 PM, Ulrich Drepper <drepper@gmail.com> wrote:
> On Sat, Jun 16, 2012 at 5:56 PM, Bjorn Helgaas <bhelgaas@google.com> wrote:
>> If ACPI provides a perfectly usable generic way to describe this
>> topology and the vendor BIOS doesn't bother to use it, I'm not very
>> interested in trying to compensate for that BIOS deficiency by adding
>> a bunch of non-portable CPU-specific gunk to Linux.
>
> The problem is that all machines get this wrong. I've tested varies
> models from Dell and HP and none of them have the _PXM entry and the
> local_cpus fields are wrong. If there is a reasonably sane way to
> compensate for broken BIOSes it should be considered. We all know how
> good BIOS authors are...
please check attached one. and you may append "pci=busnum_node=00:00,80:01"
to change node for root bus.
assume you have two root bus: 00, 80
Thanks
Yinghai
[-- Attachment #2: busnum_node.patch --]
[-- Type: application/octet-stream, Size: 1604 bytes --]
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
index a92c5eb..a66485f 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -2190,6 +2190,10 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
off: Turn realloc off
on: Turn realloc on
realloc same as realloc=on
+ busnum_node=
+ Format:
+ <bus>:<node>[, ...]
+ Specifies node for bus
noari do not use PCIe ARI.
pcie_scan_all Scan all possible PCIe devices. Otherwise we
only look for one device below a PCIe downstream
diff --git a/arch/x86/pci/common.c b/arch/x86/pci/common.c
index 0ad990a..a6527fe 100644
--- a/arch/x86/pci/common.c
+++ b/arch/x86/pci/common.c
@@ -494,6 +494,28 @@ int __init pcibios_init(void)
return 0;
}
+static void __init parse_busnum_node(char *str)
+{
+ int bus, node, count;
+ char *p;
+
+ p = str;
+ while (*p) {
+ count = 0;
+ if (sscanf(p, "%x:%x%n", &bus, &node, &count) != 2) {
+ printk(KERN_ERR "PCI: Can't parse busnum_node input: %s\n",
+ p);
+ break;
+ }
+ set_mp_bus_to_node(bus, node);
+ p += count;
+ if (*p != ',')
+ break;
+ p++;
+ }
+}
+
+
char * __devinit pcibios_setup(char *str)
{
if (!strcmp(str, "off")) {
@@ -579,6 +601,9 @@ char * __devinit pcibios_setup(char *str)
} else if (!strcmp(str, "nocrs")) {
pci_probe |= PCI_ROOT_NO_CRS;
return NULL;
+ } else if (!strncmp(str, "busnum_node=", 12)) {
+ parse_busnum_node(str + 12);
+ return NULL;
} else if (!strcmp(str, "earlydump")) {
pci_early_dump_regs = 1;
return NULL;
next prev parent reply other threads:[~2012-06-18 23:40 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CAOPLpQfUm-2ENkbnYfXEn1nf9FHnaRk3aqQTSTBWb-CsfCUCFA@mail.gmail.com>
2012-06-16 3:03 ` SNB PCI root information Yinghai Lu
2012-06-16 8:52 ` Thomas Gleixner
2012-06-16 19:36 ` Yinghai Lu
2012-06-16 21:56 ` Bjorn Helgaas
2012-06-18 22:30 ` Ulrich Drepper
2012-06-18 23:40 ` Yinghai Lu [this message]
2012-06-19 12:36 ` Bjorn Helgaas
2012-06-19 18:20 ` Yinghai Lu
2012-06-20 17:11 ` Ulrich Drepper
2012-06-20 17:17 ` Bjorn Helgaas
2012-06-20 17:59 ` Ulrich Drepper
2012-06-20 18:37 ` Yinghai Lu
2012-06-20 18:46 ` Bjorn Helgaas
2012-06-20 19:28 ` Yinghai Lu
2012-06-20 19:34 ` Ingo Molnar
2012-06-20 20:04 ` Ulrich Drepper
2012-06-20 20:16 ` Bjorn Helgaas
2012-06-20 21:21 ` Ulrich Drepper
2012-06-20 23:58 ` Yinghai Lu
2012-06-21 2:37 ` Yinghai Lu
2012-06-21 3:50 ` Yinghai Lu
2012-06-21 12:17 ` Ulrich Drepper
2012-06-21 16:22 ` Ulrich Drepper
2012-06-21 18:11 ` Yinghai Lu
2012-06-25 17:54 ` Ulrich Drepper
2012-06-20 19:57 ` Brice Goglin
2012-06-21 2:43 ` Yinghai Lu
2012-06-21 5:56 ` Brice Goglin
2012-06-21 19:24 ` Yinghai Lu
2012-06-22 7:14 ` Brice Goglin
2012-06-22 17:28 ` Yinghai Lu
2012-06-22 20:38 ` Brice Goglin
2012-06-22 20:41 ` Yinghai Lu
2012-06-25 9:07 ` Brice Goglin
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='CAE9FiQVzKr+nyBh=8-v+HEDF=7JqN2CqdTNx1=LHTq=c_OyZvg@mail.gmail.com' \
--to=yinghai@kernel.org \
--cc=bhelgaas@google.com \
--cc=drepper@gmail.com \
--cc=jbarnes@virtuousgeek.org \
--cc=lenb@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--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;
as well as URLs for NNTP newsgroup(s).