Commit 7715a1e8 authored by David Rientjes's avatar David Rientjes Committed by Jesse Barnes

x86/PCI: default pcibus cpumask to all cpus if it lacks affinity

The early initialization of the pci bus to node mapping leaves all busses
with a node id of -1 if it lacks memory affinity.  Thus, cpumask_of_pcibus
must return all online cpus for such busses.
Signed-off-by: default avatarDavid Rientjes <rientjes@google.com>
Signed-off-by: default avatarJesse Barnes <jbarnes@virtuousgeek.org>
parent be3652b8
...@@ -143,7 +143,11 @@ static inline int __pcibus_to_node(const struct pci_bus *bus) ...@@ -143,7 +143,11 @@ static inline int __pcibus_to_node(const struct pci_bus *bus)
static inline const struct cpumask * static inline const struct cpumask *
cpumask_of_pcibus(const struct pci_bus *bus) cpumask_of_pcibus(const struct pci_bus *bus)
{ {
return cpumask_of_node(__pcibus_to_node(bus)); int node;
node = __pcibus_to_node(bus);
return (node == -1) ? cpu_online_mask :
cpumask_of_node(node);
} }
#endif #endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment