[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <9b12762abf045a08c930f71537edf1affcca0c5c.1434598237.git.panand@redhat.com>
Date: Thu, 18 Jun 2015 09:28:51 +0530
From: Pratyush Anand <panand@...hat.com>
To: linux-arm-kernel@...ts.infradead.org, linux@....linux.org.uk,
catalin.marinas@....com, will.deacon@....com
Cc: linux-kernel@...r.kernel.org, wcohen@...hat.com, oleg@...hat.com,
dave.long@...aro.org, steve.capper@...aro.org,
srikar@...ux.vnet.ibm.com, vijaya.kumar@...iumnetworks.com,
Pratyush Anand <panand@...hat.com>
Subject: [RFC PATCH V2 04/10] arm64: Add helper for link pointer
At many a place we program procedure link pointer ie regs[30]. So adding
helper to do that.
Signed-off-by: Pratyush Anand <panand@...hat.com>
---
arch/arm64/include/asm/ptrace.h | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/arch/arm64/include/asm/ptrace.h b/arch/arm64/include/asm/ptrace.h
index 3ea7f5a04bfc..fa2c122e5bd6 100644
--- a/arch/arm64/include/asm/ptrace.h
+++ b/arch/arm64/include/asm/ptrace.h
@@ -227,6 +227,13 @@ static inline int valid_user_regs(struct user_pt_regs *regs)
#include <asm-generic/ptrace.h>
#define stack_pointer(regs) ((regs)->sp)
+#define procedure_link_pointer(regs) ((regs)->regs[30])
+
+static inline void procedure_link_pointer_set(struct pt_regs *regs,
+ unsigned long val)
+{
+ procedure_link_pointer(regs) = val;
+}
#ifdef CONFIG_SMP
#undef profile_pc
--
2.1.0
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists