lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210305104409.72e90865@gandalf.local.home>
Date:   Fri, 5 Mar 2021 10:44:09 -0500
From:   Steven Rostedt <rostedt@...dmis.org>
To:     Masami Hiramatsu <mhiramat@...nel.org>
Cc:     Ingo Molnar <mingo@...nel.org>, X86 ML <x86@...nel.org>,
        Daniel Xu <dxu@...uu.xyz>, linux-kernel@...r.kernel.org,
        bpf@...r.kernel.org, kuba@...nel.org, mingo@...hat.com,
        ast@...nel.org, tglx@...utronix.de, kernel-team@...com, yhs@...com
Subject: Re: [PATCH -tip 5/5] tracing: Remove kretprobe unknown indicator
 from stacktrace

On Sat,  6 Mar 2021 00:39:50 +0900
Masami Hiramatsu <mhiramat@...nel.org> wrote:

> Since the stacktrace API fixup the kretprobed address correctly,
> there is no need to convert the "kretprobe_trampoline" to
>  "[unknown/kretprobe'd]" anymore. Remove it.
> 
> Signed-off-by: Masami Hiramatsu <mhiramat@...nel.org>
> ---
>  kernel/trace/trace_output.c |   27 ++++-----------------------
>  1 file changed, 4 insertions(+), 23 deletions(-)
> 

Acked-by: Steven Rostedt (VMware) <rostedt@...dmis.org>

-- Steve

> diff --git a/kernel/trace/trace_output.c b/kernel/trace/trace_output.c
> index 61255bad7e01..f5f8b081b668 100644
> --- a/kernel/trace/trace_output.c
> +++ b/kernel/trace/trace_output.c
> @@ -346,37 +346,18 @@ int trace_output_call(struct trace_iterator *iter, char *name, char *fmt, ...)
>  }
>  EXPORT_SYMBOL_GPL(trace_output_call);
>  
> -#ifdef CONFIG_KRETPROBES
> -static inline const char *kretprobed(const char *name)
> -{
> -	static const char tramp_name[] = "kretprobe_trampoline";
> -	int size = sizeof(tramp_name);
> -
> -	if (strncmp(tramp_name, name, size) == 0)
> -		return "[unknown/kretprobe'd]";
> -	return name;
> -}
> -#else
> -static inline const char *kretprobed(const char *name)
> -{
> -	return name;
> -}
> -#endif /* CONFIG_KRETPROBES */
> -
>  void
>  trace_seq_print_sym(struct trace_seq *s, unsigned long address, bool offset)
>  {
>  #ifdef CONFIG_KALLSYMS
> -	char str[KSYM_SYMBOL_LEN];
> -	const char *name;
> +	char name[KSYM_SYMBOL_LEN];
>  
>  	if (offset)
> -		sprint_symbol(str, address);
> +		sprint_symbol(name, address);
>  	else
> -		kallsyms_lookup(address, NULL, NULL, NULL, str);
> -	name = kretprobed(str);
> +		kallsyms_lookup(address, NULL, NULL, NULL, name);
>  
> -	if (name && strlen(name)) {
> +	if (strlen(name)) {
>  		trace_seq_puts(s, name);
>  		return;
>  	}

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ