[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <f05baa70-5a6f-c53f-89a6-a3279df6eb83@oracle.com>
Date: Tue, 27 Sep 2016 13:22:30 +0200
From: Vegard Nossum <vegard.nossum@...cle.com>
To: Dmitry Vyukov <dvyukov@...gle.com>,
Peter Zijlstra <peterz@...radead.org>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Andrey Konovalov <andreyknvl@...gle.com>,
Nicolai Stange <nicstange@...il.com>,
Andrey Ryabinin <aryabinin@...tuozzo.com>,
Kees Cook <keescook@...omium.org>,
James Morse <james.morse@....com>,
LKML <linux-kernel@...r.kernel.org>,
Quentin Casasnovas <quentin.casasnovas@...cle.com>,
Andrey Ryabinin <ryabinin.a.a@...il.com>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...e.hu>
Subject: Re: [PATCH] kcov: properly check if we are in an interrupt
On 09/27/2016 01:20 PM, Vegard Nossum wrote:
> Your patch was:
>
> - if (!t || in_interrupt())
> + if (!t || (preempt_count() & (HARDIRQ_MASK | SOFTIRQ_OFFSET
> + | NMI_MASK)))
>
> But look at the definitions:
>
> #define irq_count() (preempt_count() & (HARDIRQ_MASK | SOFTIRQ_MASK \
> | NMI_MASK))
> #define in_interrupt() (irq_count())
>
> So isn't the patch a no-op to start with?
Eh, SOFTIRQ_OFFSET vs SOFTIRQ_MASK.
I'll just go stand in the corner.
Vegard
Powered by blists - more mailing lists