[PATCH v2 0/1] ARM64/ftrace: ftrace support on ARM64.

Ganapatrao Kulkarni ganapatrao.kulkarni at caviumnetworks.com
Thu Oct 17 04:00:29 EDT 2013


From: Ganapatrao Kulkarni <ganapatrao.kulkarni at cavium.com>

This patch adds the support for ftrace on ARM64.

This code is compiled with the toolchain patched with profiling(-pg)
support patch from
http://gcc.gnu.org/viewcvs/gcc?view=revision&revision=203028.

Tested for function trace, dynamic function trace,
function graph trace and function graph with
dynamic trace on simulator.

Note:
Make sure your host machine has below macros(atleast)
defined in file /usr/include/elf.h

#define EM_AARCH64      183             /* ARM64 */
#define R_AARCH64_ABS64                 257

V2:
  - Added and tested ftrace on Big-endian Kernel.
  - Fixed Simulator Hang/Kernel Panic (more prominent with pre-emptive)
    with Graph function tracer.
  - Removed unnecessary Macros, variables and functions.

V1:
  - Initial patch-set

Ganapatrao Kulkarni (1):
  ARM64/ftrace: ftrace support on ARM64.

 arch/arm64/Kconfig                  |   5 +
 arch/arm64/include/asm/ftrace.h     |  78 +++++++++++++++
 arch/arm64/include/asm/stacktrace.h |   1 +
 arch/arm64/kernel/Makefile          |  10 +-
 arch/arm64/kernel/arm64ksyms.c      |   5 +
 arch/arm64/kernel/entry.S           | 187 +++++++++++++++++++++++++++++++++++
 arch/arm64/kernel/ftrace.c          | 191 ++++++++++++++++++++++++++++++++++++
 arch/arm64/kernel/insn.c            |  48 +++++++++
 arch/arm64/kernel/insn.h            |  38 +++++++
 arch/arm64/kernel/return_address.c  |  67 +++++++++++++
 scripts/recordmcount.c              |   4 +
 scripts/recordmcount.h              |   3 +-
 scripts/recordmcount.pl             |   5 +
 13 files changed, 640 insertions(+), 2 deletions(-)
 create mode 100644 arch/arm64/include/asm/ftrace.h
 create mode 100644 arch/arm64/kernel/ftrace.c
 create mode 100644 arch/arm64/kernel/insn.c
 create mode 100644 arch/arm64/kernel/insn.h
 create mode 100644 arch/arm64/kernel/return_address.c

-- 
1.8.1.4




More information about the linux-arm-kernel mailing list