Messages in this thread | | | From | Jesse Barnes <> | Subject | Re: [Lse-tech] [RFC][PATCH] Change pcibus_to_cpumask() to pcibus_to_node() | Date | Tue, 27 Jul 2004 08:22:43 -0700 |
| |
On Tuesday, July 27, 2004 2:51 am, Christoph Hellwig wrote: > On Mon, Jul 26, 2004 at 05:10:08PM -0700, Matthew Dobson wrote: > > So in discussions with Jesse at OLS, we decided that pcibus_to_node() is > > Please do pcibus_to_nodemask() instead - there could be dual-ported pci > bridges.
Do you know of any? On sn2 there are dual ported xio->pci bridges, but in that case, half the busses are associated with one node and the other half with another node, so pcibus_to_node would work in that case. And for numalink->pci bridges, we'll return the node id of the bridge in that case (which may not have any memory, but in that case alloc_pages_node will fall back to the next node).
I wonder though if we shouldn't add
... #ifdef CONFIG_NUMA int node; /* or nodemask_t if necessary */ #endif ...
to struct pci_bus instead? That would make the existing code paths a little faster and avoid the need for a global array, which tends to lead to TLB misses.
Anyway, my needs are very simple. I'd like to do alloc_pages_node(pci_to_node(pci_dev)); in the sn2 version of pci_alloc_consistent and use the new routine to simplify the initial irq setup code, making it look more like build_zonelists and the sched domains patch I posted yesterday. So as long as those needs are provided for, I'm ok with the interface.
Thanks, Jesse - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |