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: <20230308143925.GJ2017917@hirez.programming.kicks-ass.net>
Date:   Wed, 8 Mar 2023 15:39:25 +0100
From:   Peter Zijlstra <peterz@...radead.org>
To:     Steven Rostedt <rostedt@...dmis.org>
Cc:     LKML <linux-kernel@...r.kernel.org>,
        Linux Trace Kernel <linux-trace-kernel@...r.kernel.org>,
        Masami Hiramatsu <mhiramat@...nel.org>,
        Ingo Molnar <mingo@...nel.org>,
        Joel Fernandes <joel@...lfernandes.org>,
        Ross Zwisler <zwisler@...gle.com>
Subject: Re: [PATCH] tracing, hardirq: Do not test lockdep on irq trace
 points when disabled

On Tue, Mar 07, 2023 at 06:46:45PM -0500, Steven Rostedt wrote:
> From: "Steven Rostedt (Google)" <rostedt@...dmis.org>
> 
> When CONFIG_LOCKDEP is enabled, the trace points have:
> 
> 	static inline void trace_##name(proto)				\
> 	{								\
> 		if (static_key_false(&__tracepoint_##name.key))		\
> 			__DO_TRACE(name,				\
> 				TP_ARGS(args),				\
> 				TP_CONDITION(cond), 0);			\
> 		if (IS_ENABLED(CONFIG_LOCKDEP) && (cond)) {		\
> 			rcu_read_lock_sched_notrace();			\
> 			rcu_dereference_sched(__tracepoint_##name.funcs);\
> 			rcu_read_unlock_sched_notrace();		\
> 		}							\
> 	}								\

> Where it will test lockdep for trace points even when they are not
> enabled, to make sure they do not cause RCU issues, and lockdep will
> trigger even when the trace points are not enabled.

I'm confused what that's actually trying to do..

You're not tickling the rcu_is_watching() check, because
rcu_read_lock_sched_notrace() doesn't have that. You're not tickling
RCU_LOCKDEP_WARN() because you did rcu_read_lock_sched_notrace().

So what?!?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ