public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Vivek Goyal <vgoyal@in.ibm.com>
To: h-shimamoto@ct.jp.nec.com
Cc: hbabu@us.ibm.com, tglx@linutronix.de,
	linux-kernel@vger.kernel.org, kexec@lists.infradead.org,
	Fernando Luis Vazquez Cao <fernando@intellilink.co.jp>
Subject: Re: [PATCH 2/3] x86: add safe_smp_processor_id for x86_64
Date: Wed, 24 Oct 2007 14:31:28 +0530	[thread overview]
Message-ID: <20071024090128.GA4809@in.ibm.com> (raw)
In-Reply-To: <20071024063141.GB4622@in.ibm.com>

On Wed, Oct 24, 2007 at 12:01:41PM +0530, Vivek Goyal wrote:
> On Fri, Oct 19, 2007 at 06:23:02PM -0700, Hiroshi Shimamoto wrote:
> > From: Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
> > 
> > Signed-off-by: Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
> > ---
> >  include/asm-x86/smp_64.h |    2 ++
> >  1 files changed, 2 insertions(+), 0 deletions(-)
> > 
> > diff --git a/include/asm-x86/smp_64.h b/include/asm-x86/smp_64.h
> > index 6f0e027..ab612b0 100644
> > --- a/include/asm-x86/smp_64.h
> > +++ b/include/asm-x86/smp_64.h
> > @@ -76,6 +76,8 @@ extern unsigned __cpuinitdata disabled_cpus;
> > 
> >  #endif /* CONFIG_SMP */
> > 
> > +#define safe_smp_processor_id()		smp_processor_id()
> > +
> 
> Can you please implement a patch for safe_smp_processor_id() instead of
> using smp_processor_id(). safe_smp_processor_id() was introduced to make
> sure that we are not dependent on the stack of threads after kernel has
> crashed instead read the apic id and convert it to cpu id with other
> data structures. This helped in stack overflow case.
> 
> Hardcoding it to smp_processor_id() will give the false impression.
> 

Just now Aneesh pointed that x86_64 using pda for retrieving processor id
and not kernel stack.

I think it is fine then.

Thanks
Vivek

  reply	other threads:[~2007-10-24  9:01 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-20  1:18 [PATCH 0/3] x86: unify crash_32/64.c Hiroshi Shimamoto
2007-10-20  1:21 ` [PATCH 1/3] x86: add lapic_shutdown for x86_64 Hiroshi Shimamoto
2007-10-24  6:29   ` Vivek Goyal
2007-10-24 21:27     ` Hiroshi Shimamoto
2007-10-25  0:28       ` Eric W. Biederman
2007-10-29 22:45         ` Hiroshi Shimamoto
2007-10-29 22:39     ` [PATCH] Revert " Hiroshi Shimamoto
2007-10-29 23:15       ` Arjan van de Ven
2007-10-30  0:05         ` Hiroshi Shimamoto
2007-10-30  1:06           ` Thomas Gleixner
2007-10-20  1:23 ` [PATCH 2/3] x86: add safe_smp_processor_id " Hiroshi Shimamoto
2007-10-24  6:31   ` Vivek Goyal
2007-10-24  9:01     ` Vivek Goyal [this message]
2007-10-20  1:24 ` [PATCH 3/3] x86: unify crash_32/64.c Hiroshi Shimamoto
2007-10-20 10:50 ` [PATCH 0/3] " Thomas Gleixner
2007-10-24  6:34 ` Vivek Goyal
2007-10-24 16:28   ` Hiroshi Shimamoto
2007-10-25 17:58     ` Hiroshi Shimamoto
2007-10-26 21:43       ` Hiroshi Shimamoto
2007-10-26 22:37         ` Thomas Gleixner
2007-10-27  0:13           ` Hiroshi Shimamoto
2007-10-27  1:15             ` Hiroshi Shimamoto

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=20071024090128.GA4809@in.ibm.com \
    --to=vgoyal@in.ibm.com \
    --cc=fernando@intellilink.co.jp \
    --cc=h-shimamoto@ct.jp.nec.com \
    --cc=hbabu@us.ibm.com \
    --cc=kexec@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tglx@linutronix.de \
    /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