linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v4 0/6] arm64: ftrace: fix incorrect output from stack tracer
@ 2015-10-30  5:25 AKASHI Takahiro
  2015-10-30  5:25 ` [PATCH v4 1/6] arm64: ftrace: adjust callsite addresses examined by " AKASHI Takahiro
                   ` (5 more replies)
  0 siblings, 6 replies; 17+ messages in thread
From: AKASHI Takahiro @ 2015-10-30  5:25 UTC (permalink / raw)
  To: linux-arm-kernel

This is the fourth patch series for fixing stack tracer on arm64.
The original issue was reported by Jungseok[1], and then I found more
issues[2].
(Steven, Jungseok, sorry for not replying to your comments directly.)

I address here all the issues and implement fixes described in [2] except
for interrupt-triggered problems(II-3) and leaf function(II-5).  Recent
discussions[3] about introducing a dedicated interrupt stack suggests that
we may avoid walking through from an interrupt stack to a process stack.
(So interrupt-stack patch is a prerequisite.)

Basically,
patch1 corresponds to the original issue.
patch2 is a proactive improvement of function_graph tracer. 
patch3 corresponds to II-4(functions under function_graph tracer).
patch4, 5 and 6 correspond to II-1(slurping stack) and II-2(differences
between x86 and arm64).

Each fix can be applied independently, but if patch4, 5 and 6 are
acceptable, patch1 is not necessary because patch7 replaces a default
stack tracer.

I tested the code with v4.3-rc7 + Jungseok's patch v5[4].

Changes from v3:
- fixed build errors/warnings reported by kbuild test robot
- addressed Steven's comments around check_stack()
- removed a patch ("arm64: ftrace: allow for tracing leaf functions")
  I don't remember why I thought this was necessary, but anyhow "-pg" seems
  to disable omit-leaf-stack-frame.

[1] http://lists.infradead.org/pipermail/linux-arm-kernel/2015-July/354126.html
[2] http://lists.infradead.org/pipermail/linux-arm-kernel/2015-July/355920.html 
[3] http://lists.infradead.org/pipermail/linux-arm-kernel/2015-September/368003.html
[4] http://lists.infradead.org/pipermail/linux-arm-kernel/2015-October/378699.html

AKASHI Takahiro (6):
  arm64: ftrace: adjust callsite addresses examined by stack tracer
  arm64: ftrace: modify a stack frame in a safe way
  arm64: ftrace: fix a stack tracer's output under function graph
    tracer
  ftrace: allow arch-specific stack tracer
  arm64: insn: add instruction decoders for ldp/stp and add/sub
  arm64: ftrace: add arch-specific stack tracer

 arch/arm64/include/asm/ftrace.h     |    7 +-
 arch/arm64/include/asm/insn.h       |   18 +++
 arch/arm64/include/asm/stacktrace.h |    4 +
 arch/arm64/kernel/ftrace.c          |   79 +++++++++++--
 arch/arm64/kernel/insn.c            |  102 +++++++++++++++++
 arch/arm64/kernel/stacktrace.c      |  213 ++++++++++++++++++++++++++++++++++-
 include/linux/ftrace.h              |   17 +++
 kernel/trace/trace_stack.c          |   88 ++++++++-------
 8 files changed, 473 insertions(+), 55 deletions(-)

-- 
1.7.9.5

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2015-11-04  8:42 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-30  5:25 [PATCH v4 0/6] arm64: ftrace: fix incorrect output from stack tracer AKASHI Takahiro
2015-10-30  5:25 ` [PATCH v4 1/6] arm64: ftrace: adjust callsite addresses examined by " AKASHI Takahiro
2015-10-30 11:16   ` Will Deacon
2015-11-02 18:20     ` Steven Rostedt
2015-11-02 18:29       ` Mark Rutland
2015-11-02 18:41         ` Will Deacon
2015-11-02 18:43           ` Mark Rutland
2015-10-30  5:25 ` [PATCH v4 2/6] arm64: ftrace: modify a stack frame in a safe way AKASHI Takahiro
2015-10-30  5:25 ` [PATCH v4 3/6] arm64: ftrace: fix a stack tracer's output under function graph tracer AKASHI Takahiro
2015-11-01  8:00   ` Jungseok Lee
2015-11-04  7:49     ` AKASHI Takahiro
2015-10-30  5:25 ` [PATCH v4 4/6] ftrace: allow arch-specific stack tracer AKASHI Takahiro
2015-10-30  5:25 ` [PATCH v4 5/6] arm64: insn: add instruction decoders for ldp/stp and add/sub AKASHI Takahiro
2015-10-30  5:25 ` [PATCH v4 6/6] arm64: ftrace: add arch-specific stack tracer AKASHI Takahiro
2015-11-01  8:30   ` Jungseok Lee
2015-11-04  8:01     ` AKASHI Takahiro
2015-11-04  8:42   ` yalin wang

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).