From: Ingo Molnar <mingo@elte.hu>
To: Dmitry Baryshkov <dbaryshkov@gmail.com>
Cc: linux-kernel@vger.kernel.org, peterz@infradead.org,
mingo@redhat.com, Alexander Viro <viro@ftp.linux.org.uk>
Subject: Re: [PATCH] lockdep: fix spurious 'inconsistent lock state' warning
Date: Mon, 18 Aug 2008 09:42:21 +0200 [thread overview]
Message-ID: <20080818074221.GD30694@elte.hu> (raw)
In-Reply-To: <1219019197-17744-1-git-send-email-dbaryshkov@gmail.com>
* Dmitry Baryshkov <dbaryshkov@gmail.com> wrote:
> Since f82b217e3513fe3af342c0f3ee1494e86250c21c lockdep can output
> spurious warnings related to hwirqs due to hardirq_off shrinkage from
> int to bit-sized flag. Guard it with double negation to fix the
> warning.
>
> Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
good spotting! Applied to tip/core/urgent, thanks Dmitry.
I'm wondering, is there any way to teach gcc some sanity here - a safer
variant of bitfields, that is just not allowed to overflow into or
corrupt nearby fields? The fact that a benign looking hlock->state = 15
can corrupt other fields worries me quite a bit. Valid C semantics or
not, this is a totally dangerous construct. The space savings are very
real though, so it would be nice to get 'safer bitfields', somehow.
Ingo
prev parent reply other threads:[~2008-08-18 7:42 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-18 0:26 [PATCH] lockdep: fix spurious 'inconsistent lock state' warning Dmitry Baryshkov
2008-08-18 7:42 ` Ingo Molnar [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080818074221.GD30694@elte.hu \
--to=mingo@elte.hu \
--cc=dbaryshkov@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=viro@ftp.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox