All of lore.kernel.org
 help / color / mirror / Atom feed
From: Robert Richter <robert.richter@caviumnetworks.com>
To: Hanjun Guo <guohanjun@huawei.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
	Will Deacon <will.deacon@arm.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	linux-acpi@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org,
	Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com>,
	Lorenzo Pieralisi <Lorenzo.Pieralisi@arm.com>,
	Shannon Zhao <shannon.zhao@linaro.org>,
	Steve Capper <steve.capper@linaro.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Hanjun Guo <hanjun.guo@linaro.org>
Subject: Re: [PATCH v3 12/12] acpi, numa: reuse acpi_numa_memory_affinity_init()
Date: Wed, 27 Jan 2016 15:18:47 +0100	[thread overview]
Message-ID: <20160127141847.GR24726@rric.localdomain> (raw)
In-Reply-To: <56A8606A.8080407@huawei.com>

On 27.01.16 14:15:06, Hanjun Guo wrote:
> Hi Robert,
> 
> On 2016/1/25 18:26, Robert Richter wrote:
> > On 23.01.16 17:39:27, Hanjun Guo wrote:
> >> From: Hanjun Guo <hanjun.guo@linaro.org>
> >>
> >> After the cleanup for acpi_numa_memory_affinity_init(),
> >> it can be used for architetures both x86 and arm64, since
> >> CONFIG_MEMORY_HOTPLUG is not enabled for arm64, so no
> >> worry about that.
> >>
> >> Signed-off-by: Hanjun Guo <hanjun.guo@linaro.org>
> >> ---
> >>  arch/arm64/kernel/acpi_numa.c | 42 -------------------------------
> >>  arch/x86/mm/srat.c            | 54 ----------------------------------------
> >>  drivers/acpi/numa.c           | 57 +++++++++++++++++++++++++++++++++++++++++++
> >>  3 files changed, 57 insertions(+), 96 deletions(-)
> > This one reverts acpi_numa_memory_affinity_init() to the x86 version.
> > I rather would prefer the arm64 version for the generic code. We could
> > keep the x86 implementation until x86 maintainers agree to remove them
> > and use the generic one (implemented in a separate patch).
> >
> > Doing so we can move acpi_numa_memory_affinity_init() from the
> > beginning to generic code (used for arm64) and have this last patch to
> > remove the x86 version.
> 
> I think the x86 version is the generic one, all the flags (ACPI_SRAT_MEM_HOT_PLUGGABLE and
> etc) are defined in the ACPI spec, x86 just use all the flags because it support such features.
> For ARM64, firmware should be careful and represent the true platform configuration to
> OS, such as on ARM64, we can't set hotpluggable flag as the ARM64 arch don't support
> memory hot-plug yet (also the firmware don't support it too), if firmware do things right,
> it will be not worries for the kernel.

But you are removing all arm64 from your first patches. Why do you
introduce acpi_numa_memory_affinity_init() in the beginning to remove
it in the end again? I esp. like the arm64 version because of its
direct returns. So I still would like to see generic code for arm64
from the beginning. Maybe have a copy of x86 initially and make
modifications for arm64 to it, or move missing code (hotplug, etc.)
from x86 to generic and remove x86 arch code with the last patch.

-Robert

WARNING: multiple messages have this Message-ID (diff)
From: Robert Richter <robert.richter@caviumnetworks.com>
To: Hanjun Guo <guohanjun@huawei.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
	Will Deacon <will.deacon@arm.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	<linux-acpi@vger.kernel.org>,
	<linux-arm-kernel@lists.infradead.org>,
	<linux-kernel@vger.kernel.org>,
	Ganapatrao Kulkarni <gkulkarni@caviumnetworks.com>,
	Lorenzo Pieralisi <Lorenzo.Pieralisi@arm.com>,
	Shannon Zhao <shannon.zhao@linaro.org>,
	Steve Capper <steve.capper@linaro.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Hanjun Guo <hanjun.guo@linaro.org>
Subject: Re: [PATCH v3 12/12] acpi, numa: reuse acpi_numa_memory_affinity_init()
Date: Wed, 27 Jan 2016 15:18:47 +0100	[thread overview]
Message-ID: <20160127141847.GR24726@rric.localdomain> (raw)
In-Reply-To: <56A8606A.8080407@huawei.com>

On 27.01.16 14:15:06, Hanjun Guo wrote:
> Hi Robert,
> 
> On 2016/1/25 18:26, Robert Richter wrote:
> > On 23.01.16 17:39:27, Hanjun Guo wrote:
> >> From: Hanjun Guo <hanjun.guo@linaro.org>
> >>
> >> After the cleanup for acpi_numa_memory_affinity_init(),
> >> it can be used for architetures both x86 and arm64, since
> >> CONFIG_MEMORY_HOTPLUG is not enabled for arm64, so no
> >> worry about that.
> >>
> >> Signed-off-by: Hanjun Guo <hanjun.guo@linaro.org>
> >> ---
> >>  arch/arm64/kernel/acpi_numa.c | 42 -------------------------------
> >>  arch/x86/mm/srat.c            | 54 ----------------------------------------
> >>  drivers/acpi/numa.c           | 57 +++++++++++++++++++++++++++++++++++++++++++
> >>  3 files changed, 57 insertions(+), 96 deletions(-)
> > This one reverts acpi_numa_memory_affinity_init() to the x86 version.
> > I rather would prefer the arm64 version for the generic code. We could
> > keep the x86 implementation until x86 maintainers agree to remove them
> > and use the generic one (implemented in a separate patch).
> >
> > Doing so we can move acpi_numa_memory_affinity_init() from the
> > beginning to generic code (used for arm64) and have this last patch to
> > remove the x86 version.
> 
> I think the x86 version is the generic one, all the flags (ACPI_SRAT_MEM_HOT_PLUGGABLE and
> etc) are defined in the ACPI spec, x86 just use all the flags because it support such features.
> For ARM64, firmware should be careful and represent the true platform configuration to
> OS, such as on ARM64, we can't set hotpluggable flag as the ARM64 arch don't support
> memory hot-plug yet (also the firmware don't support it too), if firmware do things right,
> it will be not worries for the kernel.

But you are removing all arm64 from your first patches. Why do you
introduce acpi_numa_memory_affinity_init() in the beginning to remove
it in the end again? I esp. like the arm64 version because of its
direct returns. So I still would like to see generic code for arm64
from the beginning. Maybe have a copy of x86 initially and make
modifications for arm64 to it, or move missing code (hotplug, etc.)
from x86 to generic and remove x86 arch code with the last patch.

-Robert

WARNING: multiple messages have this Message-ID (diff)
From: robert.richter@caviumnetworks.com (Robert Richter)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v3 12/12] acpi, numa: reuse acpi_numa_memory_affinity_init()
Date: Wed, 27 Jan 2016 15:18:47 +0100	[thread overview]
Message-ID: <20160127141847.GR24726@rric.localdomain> (raw)
In-Reply-To: <56A8606A.8080407@huawei.com>

On 27.01.16 14:15:06, Hanjun Guo wrote:
> Hi Robert,
> 
> On 2016/1/25 18:26, Robert Richter wrote:
> > On 23.01.16 17:39:27, Hanjun Guo wrote:
> >> From: Hanjun Guo <hanjun.guo@linaro.org>
> >>
> >> After the cleanup for acpi_numa_memory_affinity_init(),
> >> it can be used for architetures both x86 and arm64, since
> >> CONFIG_MEMORY_HOTPLUG is not enabled for arm64, so no
> >> worry about that.
> >>
> >> Signed-off-by: Hanjun Guo <hanjun.guo@linaro.org>
> >> ---
> >>  arch/arm64/kernel/acpi_numa.c | 42 -------------------------------
> >>  arch/x86/mm/srat.c            | 54 ----------------------------------------
> >>  drivers/acpi/numa.c           | 57 +++++++++++++++++++++++++++++++++++++++++++
> >>  3 files changed, 57 insertions(+), 96 deletions(-)
> > This one reverts acpi_numa_memory_affinity_init() to the x86 version.
> > I rather would prefer the arm64 version for the generic code. We could
> > keep the x86 implementation until x86 maintainers agree to remove them
> > and use the generic one (implemented in a separate patch).
> >
> > Doing so we can move acpi_numa_memory_affinity_init() from the
> > beginning to generic code (used for arm64) and have this last patch to
> > remove the x86 version.
> 
> I think the x86 version is the generic one, all the flags (ACPI_SRAT_MEM_HOT_PLUGGABLE and
> etc) are defined in the ACPI spec, x86 just use all the flags because it support such features.
> For ARM64, firmware should be careful and represent the true platform configuration to
> OS, such as on ARM64, we can't set hotpluggable flag as the ARM64 arch don't support
> memory hot-plug yet (also the firmware don't support it too), if firmware do things right,
> it will be not worries for the kernel.

But you are removing all arm64 from your first patches. Why do you
introduce acpi_numa_memory_affinity_init() in the beginning to remove
it in the end again? I esp. like the arm64 version because of its
direct returns. So I still would like to see generic code for arm64
from the beginning. Maybe have a copy of x86 initially and make
modifications for arm64 to it, or move missing code (hotplug, etc.)
from x86 to generic and remove x86 arch code with the last patch.

-Robert

  reply	other threads:[~2016-01-27 14:18 UTC|newest]

Thread overview: 100+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-23  9:39 [PATCH v3 00/12] ACPI NUMA support for ARM64 Hanjun Guo
2016-01-23  9:39 ` Hanjun Guo
2016-01-23  9:39 ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 01/12] acpi, numa: Use pr_fmt() instead of printk Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 02/12] acpi, numa: Replace ACPI_DEBUG_PRINT() with pr_debug() Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 03/12] acpi, numa: remove duplicate NULL check Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 04/12] acpi, numa: introduce ACPI_HAS_NUMA_ARCH_FIXUP Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23 10:25   ` Robert Richter
2016-01-23 10:25     ` Robert Richter
2016-01-23 10:25     ` Robert Richter
2016-01-24  4:56     ` Hanjun Guo
2016-01-24  4:56       ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 05/12] arm64, acpi, numa: NUMA support based on SRAT and SLIT Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-25 10:21   ` Robert Richter
2016-01-25 10:21     ` Robert Richter
2016-01-25 10:21     ` Robert Richter
2016-01-27  7:12     ` Hanjun Guo
2016-01-27  7:12       ` Hanjun Guo
2016-01-27  7:12       ` Hanjun Guo
2016-01-27 14:01       ` Robert Richter
2016-01-27 14:01         ` Robert Richter
2016-01-27 14:01         ` Robert Richter
2016-01-28  3:16         ` Hanjun Guo
2016-01-28  3:16           ` Hanjun Guo
2016-01-28  3:16           ` Hanjun Guo
2016-02-01 18:09   ` Robert Richter
2016-02-01 18:09     ` Robert Richter
2016-02-01 18:09     ` Robert Richter
2016-02-02 11:30     ` Hanjun Guo
2016-02-02 11:30       ` Hanjun Guo
2016-02-02 17:00       ` Lorenzo Pieralisi
2016-02-02 17:00         ` Lorenzo Pieralisi
2016-03-02 14:10     ` Matthias Brugger
2016-03-02 14:10       ` Matthias Brugger
2016-03-02 14:10     ` Matthias Brugger
2016-03-02 14:10       ` Matthias Brugger
2016-03-02 14:08   ` Matthias Brugger
2016-03-02 14:08     ` Matthias Brugger
2016-03-10  9:50     ` Hanjun Guo
2016-03-10  9:50       ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 06/12] acpi, numa: Enable ACPI based NUMA on ARM64 Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-29 16:37   ` Robert Richter
2016-01-29 16:37     ` Robert Richter
2016-01-29 16:37     ` Robert Richter
2016-01-23  9:39 ` [PATCH v3 07/12] acpi, numa: move acpi_numa_slit_init() to common place Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 08/12] arm64, numa: rework numa_add_memblk() Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-25  9:34   ` Robert Richter
2016-01-25  9:34     ` Robert Richter
2016-01-25  9:34     ` Robert Richter
2016-01-27  6:20     ` Hanjun Guo
2016-01-27  6:20       ` Hanjun Guo
2016-01-27  6:20       ` Hanjun Guo
2016-03-09 12:27   ` Robert Richter
2016-03-09 12:27     ` Robert Richter
2016-03-09 12:27     ` Robert Richter
2016-03-10 10:10     ` Hanjun Guo
2016-03-10 10:10       ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 09/12] x86, acpi, numa: cleanup acpi_numa_processor_affinity_init() Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 10/12] acpi, numa: move bad_srat() and srat_disabled() to common place Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 11/12] acpi, numa: remove unneeded acpi_numa=1 Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39 ` [PATCH v3 12/12] acpi, numa: reuse acpi_numa_memory_affinity_init() Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-23  9:39   ` Hanjun Guo
2016-01-25 10:26   ` Robert Richter
2016-01-25 10:26     ` Robert Richter
2016-01-25 10:26     ` Robert Richter
2016-01-27  6:15     ` Hanjun Guo
2016-01-27  6:15       ` Hanjun Guo
2016-01-27  6:15       ` Hanjun Guo
2016-01-27 14:18       ` Robert Richter [this message]
2016-01-27 14:18         ` Robert Richter
2016-01-27 14:18         ` Robert Richter
2016-01-28  2:48         ` Hanjun Guo
2016-01-28  2:48           ` Hanjun Guo
2016-01-28  2:48           ` Hanjun Guo
2016-01-28 13:31           ` Robert Richter
2016-01-28 13:31             ` Robert Richter
2016-01-28 13:31             ` Robert Richter

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=20160127141847.GR24726@rric.localdomain \
    --to=robert.richter@caviumnetworks.com \
    --cc=Lorenzo.Pieralisi@arm.com \
    --cc=catalin.marinas@arm.com \
    --cc=gkulkarni@caviumnetworks.com \
    --cc=guohanjun@huawei.com \
    --cc=hanjun.guo@linaro.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=rjw@rjwysocki.net \
    --cc=shannon.zhao@linaro.org \
    --cc=steve.capper@linaro.org \
    --cc=will.deacon@arm.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.