mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Martin Hicks <mort@sgi.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: "H. Peter Anvin" <hpa@zytor.com>,
	tglx@linutronix.de, mingo@redhat.com, heukelum@mailshack.com,
	linux-kernel <linux-kernel@vger.kernel.org>,
	kdb@sgi.com
Subject: Re: [PATCH] x86: push old stack address on irqstack for unwinder
Date: Sat, 31 Jan 2009 11:45:59 -0600	[thread overview]
Message-ID: <20090131174559.GI7872@alcatraz.americas.sgi.com> (raw)
In-Reply-To: <20090131003921.GA13709@elte.hu>


On Sat, Jan 31, 2009 at 01:39:21AM +0100, Ingo Molnar wrote:
> 
> * H. Peter Anvin <hpa@zytor.com> wrote:
> 
> > H. Peter Anvin wrote:
> >> Martin Hicks wrote:
> >>> Hi,
> >>>
> >>> KDB was using this information.  Could this be pushed towards 2.6.29  
> >>> please?
> >>>
> >>> This re-adds the old stack pointer to the top of the irqstack to help
> >>> with unwinding.  It was removed in commit  
> >>> d99015b1abbad743aa049b439c1e1dede6d0fa49
> >>> as part of the save_args out-of-line work.
> >>>
> >>
> >> This bothers me... why should we add even a single instruction to what  
> >> is arguably the single hottest path in the kernel to support an  
> >> out-of-tree debugger, especially if kgdb (which is in-tree) doesn't 
> >> need it?
> >>
> >> What does kgdb do differently (or is kgdb broken too)?
> >>

I was searching around, trying to find out if there was another way for
kdb to do this, and I think removing the backlink is breaking other
stuff also.  dump_trace() in dumpstack_64.S is using the same trick as
KDB to trace out of the interrupt stack:

            /*
             * We link to the next stack (which would be
             * the process stack normally) the last
             * pointer (index -1 to end) in the IRQ stack:
             */
            stack = (unsigned long *) (irqstack_end[-1]);
            irqstack_end = NULL;
            ops->stack(data, "EOI");
            continue;


mh


  parent reply	other threads:[~2009-01-31 17:46 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-30 16:50 Martin Hicks
2009-01-30 23:37 ` H. Peter Anvin
2009-01-31  0:35   ` H. Peter Anvin
2009-01-31  0:39     ` Ingo Molnar
2009-01-31  0:47       ` H. Peter Anvin
2009-01-31  0:50         ` Ingo Molnar
2009-01-31 17:45       ` Martin Hicks [this message]
2009-02-03  5:18         ` H. Peter Anvin

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=20090131174559.GI7872@alcatraz.americas.sgi.com \
    --to=mort@sgi.com \
    --cc=heukelum@mailshack.com \
    --cc=hpa@zytor.com \
    --cc=kdb@sgi.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=mingo@redhat.com \
    --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

all inboxes | Powered by JetHome®