[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190213040539.GA8524@lenoir>
Date: Wed, 13 Feb 2019 05:05:40 +0100
From: Frederic Weisbecker <frederic@...nel.org>
To: Denys Vlasenko <vda.linux@...glemail.com>
Cc: Frederic Weisbecker <fweisbec@...il.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: preempt.h: some SOFTIRQ_OFFSET should be SOFTIRQ_MASK?
On Tue, Feb 05, 2019 at 07:34:31PM +0100, Denys Vlasenko wrote:
> SOFTIRQ is a counter.
> Why here:
>
> #define in_serving_softirq() (softirq_count() & SOFTIRQ_OFFSET)
> #define in_task() (!(preempt_count() & \
> (NMI_MASK | HARDIRQ_MASK | SOFTIRQ_OFFSET)))
>
> we check only lowest bit?
So we have SOFTIRQ_OFFSET that is used when serving softirqs.
And we have SOFTIRQ_DISABLE_OFFSET that is used when we disable
softirqs.
I think the choice is right on both tests above, or am I missing something?
Powered by blists - more mailing lists