From: Pratyush Anand <panand@redhat.com>
To: linux-arm-kernel@lists.infradead.org, linux@arm.linux.org.uk
Cc: tixy@linaro.org, ananth@in.ibm.com, sandeepa.prabhu@linaro.org,
catalin.marinas@arm.com, will.deacon@arm.com,
linux-kernel@vger.kernel.org, anil.s.keshavamurthy@intel.com,
masami.hiramatsu.pt@hitachi.com, wcohen@redhat.com,
oleg@redhat.com, Pratyush Anand <panand@redhat.com>
Subject: [RFC 1/8] ARM64: Move BRK opcodes defines from kprobes.h to insn.h
Date: Wed, 31 Dec 2014 20:51:17 +0530 [thread overview]
Message-ID: <5beb1ff58d4928a873be5e898b62d8cc2003ec7c.1420038188.git.panand@redhat.com> (raw)
In-Reply-To: <cover.1420038188.git.panand@redhat.com>
In-Reply-To: <cover.1420038188.git.panand@redhat.com>
Its better to keep all BRK opcodes used by kprobes and uprobes at one
place. Therefore move these defines to asm/insn.h.
Signed-off-by: Pratyush Anand <panand@redhat.com>
---
arch/arm64/include/asm/insn.h | 6 ++++++
arch/arm64/kernel/kprobes.h | 7 +------
2 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/arch/arm64/include/asm/insn.h b/arch/arm64/include/asm/insn.h
index e2ff32a93b5c..87fa48746806 100644
--- a/arch/arm64/include/asm/insn.h
+++ b/arch/arm64/include/asm/insn.h
@@ -23,6 +23,12 @@
/* A64 instructions are always 32 bits. */
#define AARCH64_INSN_SIZE 4
+/* BRK opcodes with ESR encoding */
+#define BRK64_ESR_MASK 0xFFFF
+#define BRK64_ESR_KPROBES 0x0004
+#define BRK64_OPCODE_KPROBES 0xD4200080 /* "brk 0x4" */
+#define ARCH64_NOP_OPCODE 0xD503201F
+
#ifndef __ASSEMBLY__
/*
* ARM Architecture Reference Manual for ARMv8 Profile-A, Issue A.a
diff --git a/arch/arm64/kernel/kprobes.h b/arch/arm64/kernel/kprobes.h
index 93c54b4972f9..a1140971b045 100644
--- a/arch/arm64/kernel/kprobes.h
+++ b/arch/arm64/kernel/kprobes.h
@@ -15,12 +15,7 @@
#ifndef _ARM_KERNEL_KPROBES_H
#define _ARM_KERNEL_KPROBES_H
-
-/* BRK opcodes with ESR encoding */
-#define BRK64_ESR_MASK 0xFFFF
-#define BRK64_ESR_KPROBES 0x0004
-#define BRK64_OPCODE_KPROBES 0xD4200080 /* "brk 0x4" */
-#define ARCH64_NOP_OPCODE 0xD503201F
+#include <asm/insn.h>
#define JPROBES_MAGIC_NUM 0xa5a5a5a5a5a5a5a5
--
2.1.0
next prev parent reply other threads:[~2014-12-31 15:22 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-31 15:21 [RFC 0/8] ARM64: Uprobe support added Pratyush Anand
2014-12-31 15:21 ` Pratyush Anand [this message]
2015-01-08 16:55 ` [RFC 1/8] ARM64: Move BRK opcodes defines from kprobes.h to insn.h Will Deacon
2015-01-08 17:31 ` Pratyush Anand
2014-12-31 15:21 ` [RFC 2/8] ARM64: Refactor kprobes-arm64 Pratyush Anand
2015-01-08 16:55 ` Will Deacon
2015-01-08 17:33 ` Pratyush Anand
2015-01-08 17:36 ` Will Deacon
2015-01-08 17:39 ` Pratyush Anand
2014-12-31 15:21 ` [RFC 3/8] Kernel/uprobe: Define arch_uprobe_exception_notify as __weak Pratyush Anand
2015-01-02 17:43 ` Oleg Nesterov
2015-01-04 13:50 ` Pratyush Anand
2014-12-31 15:21 ` [RFC 4/8] ARM64: Add instruction_pointer_set function Pratyush Anand
2015-01-08 16:59 ` Will Deacon
2015-01-09 5:18 ` Pratyush Anand
2014-12-31 15:21 ` [RFC 5/8] ARM64: Re-factor flush_ptrace_access Pratyush Anand
2015-01-02 17:51 ` Oleg Nesterov
2015-01-02 18:19 ` Oleg Nesterov
2015-01-04 13:50 ` Pratyush Anand
2014-12-31 15:21 ` [RFC 6/8] ARM64: Handle TRAP_HWBRKPT for user mode as well Pratyush Anand
2015-01-02 18:05 ` Oleg Nesterov
2015-01-08 17:01 ` Will Deacon
2015-01-08 17:51 ` Pratyush Anand
2014-12-31 15:21 ` [RFC 7/8] ARM64: Handle TRAP_BRKPT " Pratyush Anand
2014-12-31 15:21 ` [RFC 8/8] ARM64: Add uprobe support Pratyush Anand
2015-01-02 17:23 ` Oleg Nesterov
2015-01-04 13:49 ` Pratyush Anand
2015-01-04 18:40 ` Oleg Nesterov
2015-01-05 4:17 ` Pratyush Anand
2015-01-08 17:03 ` Will Deacon
2015-01-08 17:54 ` Pratyush Anand
2015-01-09 17:45 ` Oleg Nesterov
2015-01-12 4:50 ` Pratyush Anand
2015-01-09 17:59 ` Oleg Nesterov
2015-01-12 5:04 ` Pratyush Anand
2015-01-12 6:45 ` Pratyush Anand
2015-01-12 14:38 ` Oleg Nesterov
2015-01-12 14:28 ` Oleg Nesterov
2015-01-01 1:59 ` [RFC 0/8] ARM64: Uprobe support added Pratyush Anand
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=5beb1ff58d4928a873be5e898b62d8cc2003ec7c.1420038188.git.panand@redhat.com \
--to=panand@redhat.com \
--cc=ananth@in.ibm.com \
--cc=anil.s.keshavamurthy@intel.com \
--cc=catalin.marinas@arm.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=masami.hiramatsu.pt@hitachi.com \
--cc=oleg@redhat.com \
--cc=sandeepa.prabhu@linaro.org \
--cc=tixy@linaro.org \
--cc=wcohen@redhat.com \
--cc=will.deacon@arm.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
all inboxes | Powered by JetHome®