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]
Date: Mon, 1 Apr 2024 07:57:56 +0530
From: Joel Fernandes <joel@...lfernandes.org>
To: Lai Jiangshan <jiangshanlai@...il.com>
Cc: linux-kernel@...r.kernel.org, rcu@...r.kernel.org, x86@...nel.org,
 Lai Jiangshan <jiangshan.ljs@...group.com>,
 "Paul E. McKenney" <paulmck@...nel.org>,
 Peter Zijlstra <peterz@...radead.org>,
 Frederic Weisbecker <frederic@...nel.org>,
 Neeraj Upadhyay <quic_neeraju@...cinc.com>,
 Josh Triplett <josh@...htriplett.org>, Boqun Feng <boqun.feng@...il.com>,
 Steven Rostedt <rostedt@...dmis.org>,
 Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
 Zqiang <qiang.zhang1211@...il.com>
Subject: Re: [PATCH 02/10] rcu: Move rcu_preempt_depth_set() to rcupdate.h



> On Mar 31, 2024, at 9:46 PM, Lai Jiangshan <jiangshanlai@...il.com> wrote:
> 
> On Sun, Mar 31, 2024 at 7:10 PM Joel Fernandes <joel@...lfernandes.org> wrote:
>> 
>> 
>> 
>>>> On Mar 28, 2024, at 1:20 PM, Lai Jiangshan <jiangshanlai@...il.com> wrote:
>>> 
>>> From: Lai Jiangshan <jiangshan.ljs@...group.com>
>>> 
>>> Prepare for arch-specific-defined rcu_preempt_depth_set().
>>> 
>>> No functionality change intended, but it has to be defined as a macro
>>> as rcupdate.h is a very low level header included from areas that don't
>>> even know about the task struct "current".
>> 
>> Sorry I did not follow changelog. If some rcupdate.h includers do not know
>> about task_struct, how does adding a macro that uses current help?
>> 
> 
> Hello
> 
> This is how macro works and it expands blindly based on tokens on the
> usage-sites.
> 
> And rcu_preempt_depth() & rcu_preempt_depth_set() are not universally
> used wrappers, the user can simply also include linux/sched.h to make
> they work.

Oh I see, so by hiding it in a macro, the code remains unexpanded. That makes sense..

Thanks.





> 
> Thanks
> Lai

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ