Messages in this thread | | | Date | Tue, 12 May 2020 10:49:15 +0100 | From | Will Deacon <> | Subject | Re: [PATCH v5 17/18] READ_ONCE: Use data_race() to avoid KCSAN instrumentation |
| |
On Tue, May 12, 2020 at 10:23:06AM +0200, Peter Zijlstra wrote: > On Mon, May 11, 2020 at 09:41:49PM +0100, Will Deacon wrote: > > > + data_race(({ __WRITE_ONCE(*__xp, val); 0; })); \ > > That had me blink for a little, I see how we got there, but urgh.
I tried for a while to see if data_race() could act differently if the expression was type-compatible with 'void' and, while I got something that mostly worked, it would fire unexpectedly in a few places where the expression was most definitely not void (e.g. dereferencing a vma pointer) so I gave up :(
> Anyway, it's all in *much* better shape now than it was, so no real > copmlaints.
Thanks.
Will
| |