[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200820095456.6550b78a@oasis.local.home>
Date: Thu, 20 Aug 2020 09:54:56 -0400
From: Steven Rostedt <rostedt@...dmis.org>
To: Peter Zijlstra <peterz@...radead.org>
Cc: linux-kernel@...r.kernel.org, mingo@...nel.org, will@...nel.org,
npiggin@...il.com, elver@...gle.com, jgross@...e.com,
paulmck@...nel.org, rjw@...ysocki.net, joel@...lfernandes.org,
svens@...ux.ibm.com, tglx@...utronix.de
Subject: Re: [PATCH 1/9] lockdep: Use raw_cpu_*() for per-cpu variables
On Thu, 20 Aug 2020 09:30:32 +0200
Peter Zijlstra <peterz@...radead.org> wrote:
> +++ b/include/linux/lockdep.h
> @@ -535,19 +535,27 @@ do { \
> DECLARE_PER_CPU(int, hardirqs_enabled);
> DECLARE_PER_CPU(int, hardirq_context);
>
> +/*
> + * The below lockdep_assert_*() macros se raw_cpu_read() to access the above
s/se/use/ ?
-- Steve
> + * per-cpu variables. This is required because this_cpu_read() will potentially
> + * call into preempt/irq-disable and that obviously isn't right. This is also
> + * correct because when IRQs are enabled, it doesn't matter if we accidentally
> + * read the value from our previous CPU.
> + */
Powered by blists - more mailing lists