From ca4e0d4efa9845bfff3338e3269ff112be186a2e Mon Sep 17 00:00:00 2001 From: Allen Pais Date: Wed, 11 Jan 2017 14:41:16 +0530 Subject: [PATCH] sparc64:This fixes the numa_node attributes displayed in sysfs. Orabug: 22748961 Signed-off-by: Chris Hyser Signed-off-by: Allen Pais --- arch/sparc/kernel/pci.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c index 553ea40b2913..d21f046fa23b 100644 --- a/arch/sparc/kernel/pci.c +++ b/arch/sparc/kernel/pci.c @@ -685,6 +685,13 @@ struct pci_bus *pci_scan_one_pbm(struct pci_pbm_info *pbm, return NULL; } + /* adding the device later will overwrite this value with the parent and + * then trash the entire subtree. + */ + set_dev_node(&bus->dev, pbm->numa_node); + if (bus->dev.parent) + set_dev_node(bus->dev.parent, pbm->numa_node); + pci_of_scan_bus(pbm, node, bus); pci_bus_register_of_sysfs(bus); -- 2.50.1