linux-parisc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sven Schnelle <svens@stackframe.org>
To: linux-parisc@vger.kernel.org
Cc: Sven Schnelle <svens@stackframe.org>
Subject: [PATCH 1/2] parisc: regs_return_value() should return gpr28
Date: Thu,  4 Apr 2019 18:16:03 +0200	[thread overview]
Message-ID: <20190404161604.6165-2-svens@stackframe.org> (raw)
In-Reply-To: <20190404161604.6165-1-svens@stackframe.org>

While working on kretprobes for PA-RISC i was wondering while the
kprobes sanity test always fails on kretprobes. This is caused by
returning gpr20 instead of gpr28.

Signed-off-by: Sven Schnelle <svens@stackframe.org>
---
 arch/parisc/include/asm/ptrace.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/parisc/include/asm/ptrace.h b/arch/parisc/include/asm/ptrace.h
index 2a27b275ab09..4a87b3d600c6 100644
--- a/arch/parisc/include/asm/ptrace.h
+++ b/arch/parisc/include/asm/ptrace.h
@@ -22,7 +22,7 @@ unsigned long profile_pc(struct pt_regs *);
 
 static inline unsigned long regs_return_value(struct pt_regs *regs)
 {
-	return regs->gr[20];
+	return regs->gr[28];
 }
 
 static inline void instruction_pointer_set(struct pt_regs *regs,
-- 
2.20.1


  reply	other threads:[~2019-04-04 16:16 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-04 16:16 [PATCH 0/2] small ptrace fixes Sven Schnelle
2019-04-04 16:16 ` Sven Schnelle [this message]
2019-04-04 16:16 ` [PATCH 2/2] parisc: also set iaoq_b in instruction_pointer_set() Sven Schnelle
2019-04-04 17:54 ` [PATCH 0/2] small ptrace fixes Helge Deller

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=20190404161604.6165-2-svens@stackframe.org \
    --to=svens@stackframe.org \
    --cc=linux-parisc@vger.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;
as well as URLs for NNTP newsgroup(s).