From: Julien Grall <julien.grall@arm.com>
To: Vijay Kilari <vijay.kilari@gmail.com>
Cc: Tim Deegan <tim@xen.org>,
Stefano Stabellini <sstabellini@kernel.org>,
Wei Liu <wei.liu2@citrix.com>,
George Dunlap <George.Dunlap@eu.citrix.com>,
Andrew Cooper <andrew.cooper3@citrix.com>,
Ian Jackson <ian.jackson@eu.citrix.com>,
"xen-devel@lists.xen.org" <xen-devel@lists.xen.org>,
Jan Beulich <jbeulich@suse.com>,
Vijaya Kumar K <Vijaya.Kumar@cavium.com>
Subject: Re: [RFC PATCH v2 10/25] x86: NUMA: Move numa code and make it generic
Date: Tue, 9 May 2017 09:23:43 +0100 [thread overview]
Message-ID: <890d30ce-545b-c5c8-8bd0-c63a7cc7bf9a@arm.com> (raw)
In-Reply-To: <CALicx6uGkNxL3aK1Qh2GwygCKvKSBbjYi5S7QzccKNrasgdoHw@mail.gmail.com>
On 05/09/2017 08:36 AM, Vijay Kilari wrote:
> On Mon, May 8, 2017 at 10:11 PM, Julien Grall <julien.grall@arm.com> wrote:
>> Hi Vijay,
>>
>>
>> On 28/03/17 16:53, vijay.kilari@gmail.com wrote:
>>>
>>> diff --git a/xen/arch/x86/numa.c b/xen/arch/x86/numa.c
>>> index 3bdab9a..33c6806 100644
>>> --- a/xen/arch/x86/numa.c
>>> +++ b/xen/arch/x86/numa.c
>>> @@ -10,286 +10,13 @@
>>> #include <xen/ctype.h>
>>> #include <xen/nodemask.h>
>>> #include <xen/numa.h>
>>> -#include <xen/keyhandler.h>
>>> #include <xen/time.h>
>>> #include <xen/smp.h>
>>> #include <xen/pfn.h>
>>> #include <asm/acpi.h>
>>> -#include <xen/sched.h>
>>> -#include <xen/softirq.h>
>>> -
>>> -static int numa_setup(char *s);
>>> -custom_param("numa", numa_setup);
>>> -
>>> -struct node_data node_data[MAX_NUMNODES];
>>> -
>>> -/* Mapping from pdx to node id */
>>> -unsigned int memnode_shift;
>>> -static typeof(*memnodemap) _memnodemap[64];
>>> -unsigned long memnodemapsize;
>>> -uint8_t *memnodemap;
>>> -
>>> -nodeid_t __read_mostly cpu_to_node[NR_CPUS] = {
>>> - [0 ... NR_CPUS-1] = NUMA_NO_NODE
>>> -};
>>> -/*
>>> - * Keep BIOS's CPU2node information, should not be used for memory
>>> allocaion
>>> - */
>>> -nodeid_t apicid_to_node[MAX_LOCAL_APIC] = {
>>> - [0 ... MAX_LOCAL_APIC-1] = NUMA_NO_NODE
>>> -};
>>
>>
>> Why this is moved in this patch from here to x86/srat.c?
>
> This is x86 specific. I will make a separate patch for this
> move.
But x86/numa.c is specific specific.... So why do you move it????
>
>>
>> [...]
>>
>>> diff --git a/xen/arch/x86/srat.c b/xen/arch/x86/srat.c
>>> index 7cf4771..2cc87a3 100644
>>> --- a/xen/arch/x86/srat.c
>>> +++ b/xen/arch/x86/srat.c
>>> @@ -27,6 +27,13 @@ static nodemask_t __initdata memory_nodes_parsed;
>>> static nodemask_t __initdata processor_nodes_parsed;
>>> static struct node __initdata nodes[MAX_NUMNODES];
>>>
>>> +/*
>>> + * Keep BIOS's CPU2node information, should not be used for memory
>>> allocaion
>>> + */
>>> +nodeid_t apicid_to_node[MAX_LOCAL_APIC] = {
>>> + [0 ... MAX_LOCAL_APIC-1] = NUMA_NO_NODE
>>> +};
>>> +
>>
>>
>> This does not belong to this patch...
> Ok
>>
>>> struct pxm2node {
>>> unsigned int pxm;
>>> nodeid_t node;
>>
>>
>> [...]
>>
>>
>>> diff --git a/xen/common/numa.c b/xen/common/numa.c
>>> new file mode 100644
>>> index 0000000..207ebd8
>>> --- /dev/null
>>> +++ b/xen/common/numa.c
>>> @@ -0,0 +1,488 @@
>>> +/*
>>> + * Common NUMA handling functions for x86 and arm.
>>> + * Original code extracted from arch/x86/numa.c
>>> + *
>>> + * This program is free software; you can redistribute it and/or
>>> + * modify it under the terms and conditions of the GNU General Public
>>> + * License, version 2, as published by the Free Software Foundation.
>>> + *
>>> + * This program is distributed in the hope that it will be useful,
>>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
>>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
>>> + * GNU General Public License for more details.
>>> + *
>>> + * You should have received a copy of the GNU General Public License
>>> + * along with this program; If not, see <http://www.gnu.org/licenses/>.
>>> + */
>>> +
>>> +#include <xen/mm.h>
>>> +#include <xen/string.h>
>>> +#include <xen/init.h>
>>> +#include <xen/ctype.h>
>>> +#include <xen/nodemask.h>
>>> +#include <xen/numa.h>
>>> +#include <xen/keyhandler.h>
>>> +#include <xen/time.h>
>>> +#include <xen/smp.h>
>>> +#include <xen/pfn.h>
>>> +#include <asm/acpi.h>
>>> +#include <xen/sched.h>
>>> +#include <xen/softirq.h>
>>
>>
>> Whilst you are moving this in a newfile, please order the includes.
>
> I understand that you don't like any code changes in code movement
> patch.
Are you saying you blindly copied the headers without even checking they
are necessary?
Surely, you only added the one necessary which means it would be ok to
sort them as if one is missing this would be catch by compilation.
Cheers,
--
Julien Grall
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
next prev parent reply other threads:[~2017-05-09 8:23 UTC|newest]
Thread overview: 71+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-28 15:53 [RFC PATCH v2 00/25] ARM: Add Xen NUMA support vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 01/25] x86: NUMA: Clean up: Drop trailing spaces vijay.kilari
2017-03-28 16:44 ` Wei Liu
2017-05-31 10:20 ` Jan Beulich
2017-05-31 10:21 ` Jan Beulich
2017-03-28 15:53 ` [RFC PATCH v2 02/25] x86: NUMA: Fix datatypes and attributes vijay.kilari
2017-03-28 16:44 ` Wei Liu
2017-05-31 10:35 ` Jan Beulich
2017-03-28 15:53 ` [RFC PATCH v2 03/25] x86: NUMA: Rename and sanitize some common functions vijay.kilari
2017-06-30 14:05 ` Jan Beulich
2017-07-11 10:16 ` Vijay Kilari
2017-03-28 15:53 ` [RFC PATCH v2 04/25] x86: NUMA: Add accessors for acpi_numa, numa_off and numa_fake variables vijay.kilari
2017-04-20 15:59 ` Julien Grall
2017-04-25 6:54 ` Vijay Kilari
2017-04-25 12:04 ` Julien Grall
2017-04-25 12:20 ` Vijay Kilari
2017-04-25 12:28 ` Julien Grall
2017-04-25 14:54 ` Vijay Kilari
2017-04-25 15:14 ` Julien Grall
2017-04-25 15:43 ` Jan Beulich
2017-05-02 9:47 ` Vijay Kilari
2017-05-02 9:54 ` Jan Beulich
2017-05-08 17:38 ` Julien Grall
2017-06-30 14:07 ` Jan Beulich
2017-03-28 15:53 ` [RFC PATCH v2 05/25] x86: NUMA: Move generic dummy_numa_init to separate function vijay.kilari
2017-04-20 16:12 ` Julien Grall
2017-04-25 6:59 ` Vijay Kilari
2017-06-30 14:08 ` Jan Beulich
2017-03-28 15:53 ` [RFC PATCH v2 06/25] x86: NUMA: Add accessors for nodes[] and node_memblk_range[] structs vijay.kilari
2017-05-08 14:39 ` Julien Grall
2017-05-09 7:02 ` Vijay Kilari
2017-05-09 8:13 ` Julien Grall
2017-03-28 15:53 ` [RFC PATCH v2 07/25] x86: NUMA: Rename some generic functions vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 08/25] x86: NUMA: Sanitize node distance vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 09/25] ARM: NUMA: Add existing ARM numa code under CONFIG_NUMA vijay.kilari
2017-05-08 15:58 ` Julien Grall
2017-05-09 7:14 ` Vijay Kilari
2017-05-09 8:21 ` Julien Grall
2017-03-28 15:53 ` [RFC PATCH v2 10/25] x86: NUMA: Move numa code and make it generic vijay.kilari
2017-05-08 16:41 ` Julien Grall
2017-05-09 7:36 ` Vijay Kilari
2017-05-09 8:23 ` Julien Grall [this message]
2017-05-08 16:51 ` Julien Grall
2017-05-09 7:39 ` Vijay Kilari
2017-05-09 8:26 ` Julien Grall
2017-03-28 15:53 ` [RFC PATCH v2 11/25] x86: NUMA: Move common code from srat.c vijay.kilari
2017-05-08 17:06 ` Julien Grall
2017-05-10 9:00 ` Vijay Kilari
2017-03-28 15:53 ` [RFC PATCH v2 12/25] ARM: NUMA: Parse CPU NUMA information vijay.kilari
2017-05-08 17:31 ` Julien Grall
2017-05-10 5:24 ` Vijay Kilari
2017-05-10 8:52 ` Julien Grall
2017-03-28 15:53 ` [RFC PATCH v2 13/25] ARM: NUMA: Parse memory " vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 14/25] ARM: NUMA: Parse NUMA distance information vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 15/25] ARM: NUMA: Add CPU NUMA support vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 16/25] ARM: NUMA: Add memory " vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 17/25] ARM: NUMA: Add fallback on NUMA failure vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 18/25] ARM: NUMA: Do not expose numa info to DOM0 vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 19/25] ACPI: Refactor acpi SRAT and SLIT table handling code vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 20/25] ARM: NUMA: Extract MPIDR from MADT table vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 21/25] ACPI: Move arch specific SRAT parsing vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 22/25] ARM: NUMA: Extract proximity from SRAT table vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 23/25] ARM: NUMA: Initialize ACPI NUMA vijay.kilari
2017-03-28 15:53 ` [RFC PATCH v2 24/25] NUMA: Move CONFIG_NUMA to common Kconfig vijay.kilari
2017-05-31 10:04 ` Jan Beulich
2017-05-31 10:18 ` Julien Grall
2017-05-31 10:37 ` Jan Beulich
2017-06-15 7:52 ` Vijay Kilari
2017-06-15 9:00 ` Julien Grall
2017-03-28 15:53 ` [RFC PATCH v2 25/25] NUMA: Enable ACPI_NUMA config vijay.kilari
2017-05-31 10:05 ` Jan Beulich
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=890d30ce-545b-c5c8-8bd0-c63a7cc7bf9a@arm.com \
--to=julien.grall@arm.com \
--cc=George.Dunlap@eu.citrix.com \
--cc=Vijaya.Kumar@cavium.com \
--cc=andrew.cooper3@citrix.com \
--cc=ian.jackson@eu.citrix.com \
--cc=jbeulich@suse.com \
--cc=sstabellini@kernel.org \
--cc=tim@xen.org \
--cc=vijay.kilari@gmail.com \
--cc=wei.liu2@citrix.com \
--cc=xen-devel@lists.xen.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).