Re: [tip:locking/urgent] compiler, atomics: Provide READ_ONCE_NOCHECK ()
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- Subject: Re: [tip:locking/urgent] compiler, atomics: Provide READ_ONCE_NOCHECK ()
- From: Peter Zijlstra <peterz@xxxxxxxxxxxxx>
- Date: Wed, 14 Oct 2015 18:34:23 +0200
- Cc: Dmitry Vyukov <dvyukov@xxxxxxxxxx>, Paul McKenney <paulmck@xxxxxxxxxxxxxxxxxx>, tip-bot for Andrey Ryabinin <tipbot@xxxxxxxxx>, "linux-tip-commits@xxxxxxxxxxxxxxx" <linux-tip-commits@xxxxxxxxxxxxxxx>, kasan-dev <kasan-dev@xxxxxxxxxxxxxxxx>, Ingo Molnar <mingo@xxxxxxxxxx>, Kostya Serebryany <kcc@xxxxxxxxxx>, Borislav Petkov <bp@xxxxxxxxx>, Andrey Ryabinin <aryabinin@xxxxxxxxxxxxx>, Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>, LKML <linux-kernel@xxxxxxxxxxxxxxx>, Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>, Thomas Gleixner <tglx@xxxxxxxxxxxxx>, Sasha Levin <sasha.levin@xxxxxxxxxx>, Denys Vlasenko <dvlasenk@xxxxxxxxxx>, Wolfram Gloger <wmglo@xxxxxxxxxxxxxxxxxxxxxxxx>, Andrey Konovalov <andreyknvl@xxxxxxxxxx>, "H. Peter Anvin" <hpa@xxxxxxxxx>, Alexander Potapenko <glider@xxxxxxxxxx>
- In-reply-to: <CALCETrVZP4myE3hvFmgvVcQhKMNvtOUzghC7bjDDMnjbr2Kdhg@mail.gmail.com>
- User-agent: Mutt/1.5.21 (2012-12-30)
On Wed, Oct 14, 2015 at 09:23:33AM -0700, Andy Lutomirski wrote:
> On Wed, Oct 14, 2015 at 9:20 AM, Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:
> > On Wed, Oct 14, 2015 at 06:18:58PM +0200, Dmitry Vyukov wrote:
> >>
> >> Well, if another thread writes it byte-by-byte, it pretty much does
> >> not matter how you read it.
> >> Note that I said "at least one access is not atomic". If both are
> >> atomic, then this is, of course, legal. And KTSAN considers
> >> READ/WRITE_ONCE as atomic operations.
> >
> > OK, then I'm confused on what exactly the annotation does, but less
> > worried.
>
> The annotation says "hey, KASAN (etc), don't worry if you think that
> the memory being accessed is out of bounds". Presumably KTSAN is okay
> with the operation because it's atomic, but KASAN dislikes it because
> it's accessing memory that is out of bounds from the perspective of a
> C program.
There's going to be more of that..
> I'd still rather find a way to just delete get_wchan, but whatever.
:-)
--
To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
[Index of Archives]
[Linux Stable Commits]
[Linux Stable Kernel]
[Linux Kernel]
[Linux USB Devel]
[Linux Video &Media]
[Linux Audio Users]
[Yosemite News]
[Linux SCSI]