mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: li guang <lig.fnst@cn.fujitsu.com>
To: David Rientjes <rientjes@google.com>
Cc: linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org, x86@kernel.org
Subject: Re: [PATCH 2/5] acpi/numa: check if parsing acpi numa info disabled earlier
Date: Tue, 05 Feb 2013 09:12:18 +0800	[thread overview]
Message-ID: <1360026738.4449.8.camel@liguang.fnst.cn.fujitsu.com> (raw)
In-Reply-To: <alpine.DEB.2.02.1302041133520.10378@chino.kir.corp.google.com>

在 2013-02-04一的 11:41 -0800,David Rientjes写道:
> On Mon, 4 Feb 2013, liguang wrote:
> 
> > Signed-off-by: liguang <lig.fnst@cn.fujitsu.com>
> 
> Because there's no changelog, I have to read the patch to figure out what 
> it's doing since the title isn't that helpful either.  Please provide a 
> description of what problem you're trying to fix or what improvement 
> you're trying to make so it's clear.
> 
> > ---
> >  arch/x86/mm/srat.c  |    6 ------
> >  drivers/acpi/numa.c |    2 ++
> >  2 files changed, 2 insertions(+), 6 deletions(-)
> > 
> > diff --git a/arch/x86/mm/srat.c b/arch/x86/mm/srat.c
> > index a837c95..78c67bd 100644
> > --- a/arch/x86/mm/srat.c
> > +++ b/arch/x86/mm/srat.c
> > @@ -60,8 +60,6 @@ acpi_numa_x2apic_affinity_init(struct acpi_srat_x2apic_cpu_affinity *pa)
> >  	int pxm, node;
> >  	int apic_id;
> >  
> > -	if (srat_disabled())
> > -		return;
> >  	if (pa->header.length < sizeof(struct acpi_srat_x2apic_cpu_affinity)) {
> >  		bad_srat();
> >  		return;
> > @@ -100,8 +98,6 @@ acpi_numa_processor_affinity_init(struct acpi_srat_cpu_affinity *pa)
> >  	int pxm, node;
> >  	int apic_id;
> >  
> > -	if (srat_disabled())
> > -		return;
> >  	if (pa->header.length != sizeof(struct acpi_srat_cpu_affinity)) {
> >  		bad_srat();
> >  		return;
> > @@ -148,8 +144,6 @@ acpi_numa_memory_affinity_init(struct acpi_srat_mem_affinity *ma)
> >  	u64 start, end;
> >  	int node, pxm;
> >  
> > -	if (srat_disabled())
> > -		return -1;
> >  	if (ma->header.length != sizeof(struct acpi_srat_mem_affinity)) {
> >  		bad_srat();
> >  		return -1;
> > diff --git a/drivers/acpi/numa.c b/drivers/acpi/numa.c
> > index cb31298..1f51222 100644
> > --- a/drivers/acpi/numa.c
> > +++ b/drivers/acpi/numa.c
> > @@ -262,6 +262,8 @@ static int __init acpi_parse_srat(struct acpi_table_header *table)
> >  	struct acpi_table_srat *srat;
> >  	if (!table)
> >  		return -EINVAL;
> > +	if (srat_disabled())
> > +		return -EACCES;
> >  
> >  	srat = (struct acpi_table_srat *)table;
> >  	acpi_srat_revision = srat->header.revision;
> 
> Nack, this isn't helpful since SRAT is only for x86 and other 
> architectures use this code.  It would break the build on ia64 since it's 
> obviously not going to have a function called srat_disabled().
> 
> And -EACCES would not be the appropriate return value, this has nothing to 
> do with permissions.

Yes, you're right, will drop this change.




  reply	other threads:[~2013-02-05  1:12 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-04  8:43 [PATCH 0/5] acpi: do some changes for numa info liguang
2013-02-04  8:43 ` [PATCH 1/5] numa: avoid export acpi_numa variable liguang
2013-02-04 19:31   ` David Rientjes
2013-02-05  0:56     ` li guang
2013-02-04  8:43 ` [PATCH 2/5] acpi/numa: check if parsing acpi numa info disabled earlier liguang
2013-02-04 19:41   ` David Rientjes
2013-02-05  1:12     ` li guang [this message]
2013-02-04  8:43 ` [PATCH 3/5] acpi: move x86/mm/srat.c to x86/kernel/acpi/srat.c liguang
2013-02-04 19:44   ` David Rientjes
2013-02-05  1:16     ` li guang
2013-02-04  8:43 ` [PATCH 4/5] acpi: add clock_domain field to acpi_srat_cpu_affinity liguang
2013-02-04  8:43 ` [PATCH 5/5] remove include asm/acpi.h in process_driver.c liguang

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=1360026738.4449.8.camel@liguang.fnst.cn.fujitsu.com \
    --to=lig.fnst@cn.fujitsu.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rientjes@google.com \
    --cc=x86@kernel.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

all inboxes | Powered by JetHome®