diff options
Diffstat (limited to 'arch/x86_64/mm/srat.c')
-rw-r--r-- | arch/x86_64/mm/srat.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/x86_64/mm/srat.c b/arch/x86_64/mm/srat.c index 92f6ec79b232..db6b073a149f 100644 --- a/arch/x86_64/mm/srat.c +++ b/arch/x86_64/mm/srat.c | |||
@@ -25,6 +25,13 @@ static nodemask_t nodes_found __initdata; | |||
25 | static struct node nodes[MAX_NUMNODES] __initdata; | 25 | static struct node nodes[MAX_NUMNODES] __initdata; |
26 | static __u8 pxm2node[256] = { [0 ... 255] = 0xff }; | 26 | static __u8 pxm2node[256] = { [0 ... 255] = 0xff }; |
27 | 27 | ||
28 | int pxm_to_node(int pxm) | ||
29 | { | ||
30 | if ((unsigned)pxm >= 256) | ||
31 | return 0; | ||
32 | return pxm2node[pxm]; | ||
33 | } | ||
34 | |||
28 | static __init int setup_node(int pxm) | 35 | static __init int setup_node(int pxm) |
29 | { | 36 | { |
30 | unsigned node = pxm2node[pxm]; | 37 | unsigned node = pxm2node[pxm]; |