Re: [PATCH v4 01/27] lockdep: Teach lockdep about "USED" <- "IN-NMI" inversions

From: Steven Rostedt
Date: Fri Feb 21 2020 - 15:28:32 EST


On Fri, 21 Feb 2020 21:25:11 +0100
Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:

> > Nitpick, but the association with bit 16 and this mask really should be
> > defined as a macro somewhere and not have hard coded numbers.
>
> Right, I suppose I can do something like:
>
> #define LOCKDEP_RECURSION_BITS 16
> #define LOCKDEP_OFF (1U << LOCKDEP_RECURSION_BITS)
> #define LOCKDEP_RECURSION_MASK (LOCKDEP_OFF - 1)

LGTM

-- Steve