Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1227352
| From | Eric Dumazet <eric.dumazet@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [RFC] net: fix data race on sk_buff after re-cloning |
| Date | 2015-09-17 21:10 +0200 |
| Message-ID | <q9MJc-4n2-23@gated-at.bofh.it> (permalink) |
| References | <q9MpP-3IX-15@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Thu, 2015-09-17 at 20:44 +0200, Dmitry Vyukov wrote: > KernelThreadSanitizer (KTSAN) reported the following race (on 4.2 rc2): > > ThreadSanitizer: data-race in __copy_skb_header ... > if (likely(atomic_read(&skb->users) == 1)) > smp_rmb(); > > The patch contains a proposed fix. > If it looks good to you and the scenario looks sane, > then I will update the description and resend it. > --- > net/core/skbuff.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) I have to double check this patch, but in the case it is needed, it would be better to not use fancy new atomic_read_acquire(), as backporting the fix up to 3.19 (where the bug was probably added) will require extra hassle. atomic_read_acquire() would be fine for cleanups and new code, in next branch. Thanks ! -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[RFC] net: fix data race on sk_buff after re-cloning Dmitry Vyukov <dvyukov@google.com> - 2015-09-17 20:50 +0200 Re: [RFC] net: fix data race on sk_buff after re-cloning Eric Dumazet <eric.dumazet@gmail.com> - 2015-09-17 21:10 +0200
csiph-web