mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Muli Ben-Yehuda <muli@il.ibm.com>
To: Yinghai Lu <Yinghai.Lu@Sun.COM>
Cc: akpm@linux-foundation.org, ak@suse.de, apw@shadowen.org,
	clameter@sgi.com, greg@kroah.com,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/5] x86_64: get mp_bus_to_node as early v3
Date: Wed, 8 Aug 2007 10:23:51 +0300	[thread overview]
Message-ID: <20070808072351.GK3383@rhun.haifa.ibm.com> (raw)
In-Reply-To: <200708071820.33720.yinghai.lu@sun.com>

On Tue, Aug 07, 2007 at 06:20:33PM -0700, Yinghai Lu wrote:

> please check this one against pci_scan_bus_with_sysdata
> 
> [PATCH 1/5] x86_64: get mp_bus_to_node as early v3
> 
> current on amd k8 system with multi ht chain, the numa_node of pci
> devices under r/sys/devices/pci0000:80/* always 0, even that chain is
> on node 1 or 2 or 3.
> 
> workaround: pcibus_to_node(bus) is used when we want to get node
> that pci_device is on.
> 
> In struct device, we already have numa_node member. and we could use
> dev_to_node() /set_dev_node() to get and set numa_node in the
> device.  set_dev_node is called in pci_device_add() with
> pcibus_to_node(bus). and pcibus_to_node use bus->sysdata for nodeid.
> 
> the problem is when pci_add_device is called, bus->sysdata is not
> assigned correct nodeid yet. the result will be numa_node always is
> 0.
> 
> pcibios_scan_root and pci_scan_root could take sysdata. So we need
> to get mp_bus_to_node mapping before these two are called. and
> get_mp_bus_to_node could get correct node for sysdata in root bus.
> 
> in scanning of root bus, all child bus will take parent bus sysdata. So all
> pci_device->dev.numa_node will be assigned correctly automatically.
> 
> later we could use dev_to_node(&pci_dev->dev) to get numa_node, and
> we could also could make other bus specific device get the correct
> numa_node too.
> 
> this is one update version to pci_sysdata ...  also reverse
> pci_acpi_scan_root to use pcibios_scan_root again.

Can you explain why this patch (and your other patches in this area)
are needed? is this a performance issue? the patches seem complex, is
there a good argument for that complexity?

Cheers,
Muli



  reply	other threads:[~2007-08-08  7:24 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <200708072245.l77MjVxU008742@imap1.linux-foundation.org>
2007-08-08  1:20 ` Yinghai Lu
2007-08-08  7:23   ` Muli Ben-Yehuda [this message]
2007-08-08  8:05     ` Yinghai Lu

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=20070808072351.GK3383@rhun.haifa.ibm.com \
    --to=muli@il.ibm.com \
    --cc=Yinghai.Lu@Sun.COM \
    --cc=ak@suse.de \
    --cc=akpm@linux-foundation.org \
    --cc=apw@shadowen.org \
    --cc=clameter@sgi.com \
    --cc=greg@kroah.com \
    --cc=linux-kernel@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

all inboxes | Powered by JetHome®