lkml.org 
[lkml]   [2020]   [Nov]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH net-next] net: add in_softirq() debug checking in napi_consume_skb()
On Wed, Nov 18, 2020 at 07:43:48AM -0800, Jakub Kicinski wrote:

> TBH the last sentence I wrote isn't clear even to me at this point ;D
>
> Maybe using just the macros from preempt.h - like this?
>
> #define lockdep_assert_in_softirq() \
> do { \
> WARN_ON_ONCE(__lockdep_enabled && \
> (!in_softirq() || in_irq() || in_nmi()) \
> } while (0)
>
> We know what we're doing so in_softirq() should be fine (famous last
> words).

So that's not actually using any lockdep state. But if that's what you
need, I don't have any real complaints.

\
 
 \ /
  Last update: 2020-11-18 17:01    [W:0.129 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site