Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 62389
b: refs/heads/master
c: 08705b8
h: refs/heads/master
i:
  62387: 55d5e50
v: v3
  • Loading branch information
David Rientjes authored and Linus Torvalds committed Jul 22, 2007
1 parent aebebd7 commit 37ebdb9
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3484d79813707bb6045773953a809abba443dc20
refs/heads/master: 08705b89ecb0f4b0ba5735630ef988bd9fd9dd95
13 changes: 12 additions & 1 deletion trunk/arch/x86_64/mm/srat.c
Original file line number Diff line number Diff line change
Expand Up @@ -470,10 +470,13 @@ static int __init find_node_by_addr(unsigned long addr)
*/
void __init acpi_fake_nodes(const struct bootnode *fake_nodes, int num_nodes)
{
int i;
int i, j;
int fake_node_to_pxm_map[MAX_NUMNODES] = {
[0 ... MAX_NUMNODES-1] = PXM_INVAL
};
unsigned char fake_apicid_to_node[MAX_LOCAL_APIC] = {
[0 ... MAX_LOCAL_APIC-1] = NUMA_NO_NODE
};

printk(KERN_INFO "Faking PXM affinity for fake nodes on real "
"topology.\n");
Expand All @@ -487,9 +490,17 @@ void __init acpi_fake_nodes(const struct bootnode *fake_nodes, int num_nodes)
if (pxm == PXM_INVAL)
continue;
fake_node_to_pxm_map[i] = pxm;
/*
* For each apicid_to_node mapping that exists for this real
* node, it must now point to the fake node ID.
*/
for (j = 0; j < MAX_LOCAL_APIC; j++)
if (apicid_to_node[j] == nid)
fake_apicid_to_node[j] = i;
}
for (i = 0; i < num_nodes; i++)
__acpi_map_pxm_to_node(fake_node_to_pxm_map[i], i);
memcpy(apicid_to_node, fake_apicid_to_node, sizeof(apicid_to_node));

nodes_clear(nodes_parsed);
for (i = 0; i < num_nodes; i++)
Expand Down

0 comments on commit 37ebdb9

Please sign in to comment.