The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Masami Hiramatsu (Google) <mhiramat@kernel.org>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: linux-kernel@vger.kernel.org,
	Masami Hiramatsu <mhiramat@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	<linux-arch@vger.kernel.org>, "x86@kernel.org" <x86@kernel.org>,
	Will Deacon <will@kernel.org>,
	Huacai Chen <chenhuacai@kernel.org>,
	WANG Xuerui <kernel@xen0n.name>,
	Michael Ellerman <mpe@ellerman.id.au>,
	Nicholas Piggin <npiggin@gmail.com>,
	Christophe Leroy <christophe.leroy@csgroup.eu>,
	Naveen N Rao <naveen@kernel.org>,
	Madhavan Srinivasan <maddy@linux.ibm.com>,
	Paul Walmsley <paul.walmsley@sifive.com>,
	Palmer Dabbelt <palmer@dabbelt.com>,
	Albert Ou <aou@eecs.berkeley.edu>,
	Heiko Carstens <hca@linux.ibm.com>,
	Vasily Gorbik <gor@linux.ibm.com>,
	Alexander Gordeev <agordeev@linux.ibm.com>,
	Christian Borntraeger <borntraeger@linux.ibm.com>,
	Sven Schnelle <svens@linux.ibm.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@kernel.org>, Borislav Petkov <bp@alien8.de>,
	Dave Hansen <dave.hansen@linux.intel.com>,
	Catalin Marinas <catalin.marinas@arm.com>
Subject: Re: [for-next][PATCH 4/4] ftrace: Consolidate ftrace_regs accessor functions for archs using pt_regs
Date: Tue, 15 Oct 2024 08:54:34 +0900	[thread overview]
Message-ID: <20241015085434.afeaac72d7cae61bf00af3b5@kernel.org> (raw)
In-Reply-To: <20241011132956.899228335@goodmis.org>

Hi Steve,

I found one problem on this patch while debugging my series;

On Fri, 11 Oct 2024 09:29:45 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> -#define ftrace_regs_get_argument(fregs, n) \
> -	regs_get_kernel_argument(&arch_ftrace_regs(fregs)->regs, n)

As you can seem most arch uses "arch_ftrace_regs()" macro
for ftrace_regs_*() macros. This is because we are sure
this ftrace_regs is not fully compatible with pt_regs.


> +#define ftrace_regs_get_instruction_pointer(fregs) \
> +	instruction_pointer(arch_ftrace_get_regs(fregs))

However, these consolidated macros in ftrace_regs.h are
using "arch_ftrace_get_regs()" macro, which can return NULL
if FL_SAVE_REGS is not set.

So, those should use arch_ftrace_regs() as original code
does.

Thank you,

-- 
Masami Hiramatsu (Google) <mhiramat@kernel.org>

      parent reply	other threads:[~2024-10-14 23:54 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-11 13:29 [for-next][PATCH 0/4] ftrace: Updates for 6.13 Steven Rostedt
2024-10-11 13:29 ` [for-next][PATCH 1/4] fgraph: Simplify return address printing in function graph tracer Steven Rostedt
2024-10-11 13:29 ` [for-next][PATCH 2/4] fgragh: No need to invoke the function call_filter_check_discard() Steven Rostedt
2024-10-11 13:29 ` [for-next][PATCH 3/4] ftrace: Make ftrace_regs abstract from direct use Steven Rostedt
2024-10-14  6:42   ` Madhavan Srinivasan
2024-10-11 13:29 ` [for-next][PATCH 4/4] ftrace: Consolidate ftrace_regs accessor functions for archs using pt_regs Steven Rostedt
2024-10-14  9:34   ` Michael Ellerman
2024-10-14 23:54   ` Masami Hiramatsu [this message]

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=20241015085434.afeaac72d7cae61bf00af3b5@kernel.org \
    --to=mhiramat@kernel.org \
    --cc=agordeev@linux.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=aou@eecs.berkeley.edu \
    --cc=borntraeger@linux.ibm.com \
    --cc=bp@alien8.de \
    --cc=catalin.marinas@arm.com \
    --cc=chenhuacai@kernel.org \
    --cc=christophe.leroy@csgroup.eu \
    --cc=dave.hansen@linux.intel.com \
    --cc=gor@linux.ibm.com \
    --cc=hca@linux.ibm.com \
    --cc=kernel@xen0n.name \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maddy@linux.ibm.com \
    --cc=mark.rutland@arm.com \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=mingo@kernel.org \
    --cc=mpe@ellerman.id.au \
    --cc=naveen@kernel.org \
    --cc=npiggin@gmail.com \
    --cc=palmer@dabbelt.com \
    --cc=paul.walmsley@sifive.com \
    --cc=rostedt@goodmis.org \
    --cc=svens@linux.ibm.com \
    --cc=tglx@linutronix.de \
    --cc=will@kernel.org \
    --cc=x86@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