[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5244A02C.4050700@linaro.org>
Date: Thu, 26 Sep 2013 13:59:24 -0700
From: John Stultz <john.stultz@...aro.org>
To: Steven Rostedt <rostedt@...dmis.org>
CC: LKML <linux-kernel@...r.kernel.org>,
Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
Li Zefan <lizefan@...wei.com>,
Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...nel.org>,
Thomas Gleixner <tglx@...utronix.de>
Subject: Re: [PATCH 2/4] [RFC] seqcount: Add lockdep functionality to seqcount/seqlock
structures
On 09/26/2013 01:46 PM, Steven Rostedt wrote:
> On Thu, 26 Sep 2013 11:34:22 -0700
> John Stultz <john.stultz@...aro.org> wrote:
>
>> @@ -156,10 +214,19 @@ static inline void write_seqcount_begin(seqcount_t *s)
>> {
>> s->sequence++;
>> smp_wmb();
>> + seqcount_acquire(&s->dep_map, 0, 0, _RET_IP_);
>> +}
>> +
>> +static inline void write_seqcount_begin_nested(seqcount_t *s, int subclass)
>> +{
>> + s->sequence++;
>> + smp_wmb();
>> + seqcount_acquire(&s->dep_map, subclass, 0, _RET_IP_);
>> }
> For more code reuse, I wonder if we should have:
>
> static inline void write_seqcount_begin(seqcount_t *s)
> {
> write_seqcount_begine_nested(s, 0);
> }
>
> -- Steve
Good idea! Done.
Thanks for the review!
-john
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists