linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: Sergei Shtylyov <sshtylyov@mvista.com>
Cc: kgdb-bugreport@lists.sourceforge.net,
	Jason Wessel <jason.wessel@windriver.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-next@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [Kgdb-bugreport] [PATCH] kgdbts: only use new asm-generic/ptrace.h api when needed
Date: Mon, 30 May 2011 12:28:17 -0400	[thread overview]
Message-ID: <BANLkTind_F4-5sLUO1GVxK_yY_eXz_J0Vg@mail.gmail.com> (raw)
In-Reply-To: <4DE3688A.4040600@mvista.com>

On Mon, May 30, 2011 at 05:51, Sergei Shtylyov wrote:
> On 28-05-2011 18:04, Mike Frysinger wrote:
>> The new instruction_pointer_set helper is defined for people who have
>> converted to asm-generic/ptrace.h, so don't use it generally unless
>> the arch needs it (in which case it has been converted).  This should
>> fix building of kgdb tests for arches not yet converted.
>
>> --- a/drivers/misc/kgdbts.c
>> +++ b/drivers/misc/kgdbts.c
>> @@ -304,7 +304,10 @@ static int check_and_rewind_pc(char *put_str, char
>> *arg)
>>                return 1;
>>        }
>>        /* Readjust the instruction pointer if needed */
>> -       instruction_pointer_set(&kgdbts_regs, ip + offset);
>> +       ip += offset;
>
>   Since 'íp' is local, incrementing it is pointless here unless you have
> GDB_ADJUSTS_BREAK_OFFSET defined. Why not keep instruction_pointer_set()
> call as is?

i prefer to have as much outside of ifdefs as possible.  gcc optimizes
the result away, so it isnt a code size problem.
-mike

  reply	other threads:[~2011-05-30 16:28 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-27  5:11 linux-next: build failure after merge of the final tree Stephen Rothwell
2011-05-27 14:47 ` Mike Frysinger
2011-05-28 14:04 ` [PATCH] kgdbts: only use new asm-generic/ptrace.h api when needed Mike Frysinger
2011-05-30  9:51   ` [Kgdb-bugreport] " Sergei Shtylyov
2011-05-30 16:28     ` Mike Frysinger [this message]
2011-06-01  0:11       ` Stephen Rothwell
2011-06-01  2:19         ` Mike Frysinger

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=BANLkTind_F4-5sLUO1GVxK_yY_eXz_J0Vg@mail.gmail.com \
    --to=vapier@gentoo.org \
    --cc=akpm@linux-foundation.org \
    --cc=jason.wessel@windriver.com \
    --cc=kgdb-bugreport@lists.sourceforge.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=sshtylyov@mvista.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 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).