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  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:   Wed, 8 Aug 2018 09:07:24 -0400
From:   Steven Rostedt <>
To:     "Paul E. McKenney" <>
Cc:     Joel Fernandes <>,
        Joel Fernandes <>,
        LKML <>,
        "Cc: Android Kernel" <>,
        Boqun Feng <>,
        Byungchul Park <>,
        Ingo Molnar <>,
        Masami Hiramatsu <>,
        Mathieu Desnoyers <>,
        Namhyung Kim <>,
        Peter Zijlstra <>,
        Thomas Glexiner <>,
        Tom Zanussi <>
Subject: Re: [PATCH v12 3/3] tracing: Centralize preemptirq tracepoints and
 unify their usage

On Wed, 8 Aug 2018 06:03:02 -0700
"Paul E. McKenney" <> wrote:

>  What's wrong with a this_cpu_inc()? It's atomic for the CPU. Although
> > it wont be atomic for the capture of the idx. But I also don't see
> > interrupts being disabled, thus an NMI is no different than any
> > interrupt doing the same thing, right?  
> On architectures without increment-memory instructions, if you take an NMI
> between the load from sp->sda->srcu_lock_count and the later store, you
> lose a count.  Note that both __srcu_read_lock() and __srcu_read_unlock()
> do increments of different locations, so you cannot rely on the usual
> "NMI fixes up before exit" semantics you get when incrementing and
> decrementing the same location.

And how is this handled in the interrupt case? Interrupts are not
disabled here.

I would also argue that architectures without increment-memory
instructions shouldn't have NMIs ;-)

-- Steve

Powered by blists - more mailing lists