Re: [Xen-devel] [RFC PATCH v1 19/21] ARM: NUMA: Initialize ACPI NUMA
On Thu, Mar 2, 2017 at 10:55 PM, Julien Grallwrote: > Hello Vijay, > > > On 09/02/17 15:57, vijay.kil...@gmail.com wrote: >> >> From: Vijaya Kumar K >> >> Call ACPI NUMA initialization under CONFIG_ACPI_NUMA. >> >> Signed-off-by: Vijaya Kumar >> --- >> xen/arch/arm/numa.c | 12 +++- >> xen/common/numa.c | 6 ++ >> 2 files changed, 17 insertions(+), 1 deletion(-) >> >> diff --git a/xen/arch/arm/numa.c b/xen/arch/arm/numa.c >> index 50c3dea..1d6e16c 100644 >> --- a/xen/arch/arm/numa.c >> +++ b/xen/arch/arm/numa.c >> @@ -204,7 +204,17 @@ int __init numa_init(void) >> for ( i = 0; i < MAX_NUMNODES * 2; i++ ) >> _node_distance[i] = 0; >> >> -ret = dt_numa_init(); >> +#ifdef CONFIG_ACPI_NUMA >> +if ( !acpi_disabled ) >> +{ >> +acpi_map_uid_to_mpidr(); >> +ret = acpi_numa_init(); >> +if ( ret || srat_disabled() ) >> +goto no_numa; >> +} >> +else >> +#endif > > > We should really have only on call to ACPI in the generic code. Please move > all of this in a function. OK > > >> +ret = dt_numa_init(); >> >> if ( !ret ) >> ret = numa_initmem_init(); >> diff --git a/xen/common/numa.c b/xen/common/numa.c >> index 2f5266a..4c67d38 100644 >> --- a/xen/common/numa.c >> +++ b/xen/common/numa.c >> @@ -30,6 +30,7 @@ >> #include >> #include >> #include >> +#include >> #include >> >> static int numa_setup(char *s); >> @@ -282,6 +283,11 @@ static __init int numa_setup(char *opt) >> numa_off = 1; >> if ( !strncmp(opt,"on",2) ) >> numa_off = 0; >> +if ( !strncmp(opt,"noacpi",6) ) >> +{ >> +numa_off = 0; >> +acpi_numa = -1; >> +} >> >> return arch_numa_setup(opt); >> } >> > > -- > Julien Grall ___ Xen-devel mailing list Xen-devel@lists.xen.org https://lists.xen.org/xen-devel
Re: [Xen-devel] [RFC PATCH v1 19/21] ARM: NUMA: Initialize ACPI NUMA
Hello Vijay, On 09/02/17 15:57, vijay.kil...@gmail.com wrote: From: Vijaya Kumar KCall ACPI NUMA initialization under CONFIG_ACPI_NUMA. Signed-off-by: Vijaya Kumar --- xen/arch/arm/numa.c | 12 +++- xen/common/numa.c | 6 ++ 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/xen/arch/arm/numa.c b/xen/arch/arm/numa.c index 50c3dea..1d6e16c 100644 --- a/xen/arch/arm/numa.c +++ b/xen/arch/arm/numa.c @@ -204,7 +204,17 @@ int __init numa_init(void) for ( i = 0; i < MAX_NUMNODES * 2; i++ ) _node_distance[i] = 0; -ret = dt_numa_init(); +#ifdef CONFIG_ACPI_NUMA +if ( !acpi_disabled ) +{ +acpi_map_uid_to_mpidr(); +ret = acpi_numa_init(); +if ( ret || srat_disabled() ) +goto no_numa; +} +else +#endif We should really have only on call to ACPI in the generic code. Please move all of this in a function. +ret = dt_numa_init(); if ( !ret ) ret = numa_initmem_init(); diff --git a/xen/common/numa.c b/xen/common/numa.c index 2f5266a..4c67d38 100644 --- a/xen/common/numa.c +++ b/xen/common/numa.c @@ -30,6 +30,7 @@ #include #include #include +#include #include static int numa_setup(char *s); @@ -282,6 +283,11 @@ static __init int numa_setup(char *opt) numa_off = 1; if ( !strncmp(opt,"on",2) ) numa_off = 0; +if ( !strncmp(opt,"noacpi",6) ) +{ +numa_off = 0; +acpi_numa = -1; +} return arch_numa_setup(opt); } -- Julien Grall ___ Xen-devel mailing list Xen-devel@lists.xen.org https://lists.xen.org/xen-devel
[Xen-devel] [RFC PATCH v1 19/21] ARM: NUMA: Initialize ACPI NUMA
From: Vijaya Kumar KCall ACPI NUMA initialization under CONFIG_ACPI_NUMA. Signed-off-by: Vijaya Kumar --- xen/arch/arm/numa.c | 12 +++- xen/common/numa.c | 6 ++ 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/xen/arch/arm/numa.c b/xen/arch/arm/numa.c index 50c3dea..1d6e16c 100644 --- a/xen/arch/arm/numa.c +++ b/xen/arch/arm/numa.c @@ -204,7 +204,17 @@ int __init numa_init(void) for ( i = 0; i < MAX_NUMNODES * 2; i++ ) _node_distance[i] = 0; -ret = dt_numa_init(); +#ifdef CONFIG_ACPI_NUMA +if ( !acpi_disabled ) +{ +acpi_map_uid_to_mpidr(); +ret = acpi_numa_init(); +if ( ret || srat_disabled() ) +goto no_numa; +} +else +#endif +ret = dt_numa_init(); if ( !ret ) ret = numa_initmem_init(); diff --git a/xen/common/numa.c b/xen/common/numa.c index 2f5266a..4c67d38 100644 --- a/xen/common/numa.c +++ b/xen/common/numa.c @@ -30,6 +30,7 @@ #include #include #include +#include #include static int numa_setup(char *s); @@ -282,6 +283,11 @@ static __init int numa_setup(char *opt) numa_off = 1; if ( !strncmp(opt,"on",2) ) numa_off = 0; +if ( !strncmp(opt,"noacpi",6) ) +{ +numa_off = 0; +acpi_numa = -1; +} return arch_numa_setup(opt); } -- 2.7.4 ___ Xen-devel mailing list Xen-devel@lists.xen.org https://lists.xen.org/xen-devel