* net/dst_cache.c: preemption bug in net/dst_cache.c
@ 2019-08-22 19:51 Bharath Vedartham
2019-09-09 9:48 ` Xin Long
0 siblings, 1 reply; 3+ messages in thread
From: Bharath Vedartham @ 2019-08-22 19:51 UTC (permalink / raw)
To: davem, gregkh, allison; +Cc: tglx, netdev, linux-kernel
Hi all,
I just want to bring attention to the syzbot bug [1]
Even though syzbot claims the bug to be in net/tipc, I feel it is in
net/dst_cache.c. Please correct me if I am wrong.
This bug is being triggered a lot of times by syzbot since the day it
was reported. Also given that this is core networking code, I felt it
was important to bring this to attention.
It looks like preemption needs to be disabled before using this_cpu_ptr
or maybe we would be better of using a get_cpu_var and put_cpu_var combo
here.
[1] https://syzkaller.appspot.com/bug?id=dc6352b92862eb79373fe03fdf9af5928753e057
Thank you
Bharath
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: net/dst_cache.c: preemption bug in net/dst_cache.c
2019-08-22 19:51 net/dst_cache.c: preemption bug in net/dst_cache.c Bharath Vedartham
@ 2019-09-09 9:48 ` Xin Long
2019-09-18 10:19 ` Bharath Vedartham
0 siblings, 1 reply; 3+ messages in thread
From: Xin Long @ 2019-09-09 9:48 UTC (permalink / raw)
To: Bharath Vedartham
Cc: davem, Greg Kroah-Hartman, allison, tglx, network dev, LKML, Jon Maloy
On Fri, Aug 23, 2019 at 3:58 PM Bharath Vedartham <linux.bhar@gmail.com> wrote:
>
> Hi all,
>
> I just want to bring attention to the syzbot bug [1]
>
> Even though syzbot claims the bug to be in net/tipc, I feel it is in
> net/dst_cache.c. Please correct me if I am wrong.
>
> This bug is being triggered a lot of times by syzbot since the day it
> was reported. Also given that this is core networking code, I felt it
> was important to bring this to attention.
>
> It looks like preemption needs to be disabled before using this_cpu_ptr
> or maybe we would be better of using a get_cpu_var and put_cpu_var combo
> here.
b->media->send_msg (tipc_udp_send_msg)
-> tipc_udp_xmit() -> dst_cache_get()
send_msg() is always called under the protection of rcu_read_lock(), which
already disabled preemption. If not, there must be some unbalanced calls of
disable/enable preemption elsewhere.
Agree that this could be a serious issue, do you have any reproducer for this?
Thanks.
>
> [1] https://syzkaller.appspot.com/bug?id=dc6352b92862eb79373fe03fdf9af5928753e057
>
> Thank you
> Bharath
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: net/dst_cache.c: preemption bug in net/dst_cache.c
2019-09-09 9:48 ` Xin Long
@ 2019-09-18 10:19 ` Bharath Vedartham
0 siblings, 0 replies; 3+ messages in thread
From: Bharath Vedartham @ 2019-09-18 10:19 UTC (permalink / raw)
To: Xin Long
Cc: davem, Greg Kroah-Hartman, allison, tglx, network dev, LKML, Jon Maloy
On Mon, Sep 09, 2019 at 05:48:25PM +0800, Xin Long wrote:
> On Fri, Aug 23, 2019 at 3:58 PM Bharath Vedartham <linux.bhar@gmail.com> wrote:
> >
> > Hi all,
> >
> > I just want to bring attention to the syzbot bug [1]
> >
> > Even though syzbot claims the bug to be in net/tipc, I feel it is in
> > net/dst_cache.c. Please correct me if I am wrong.
> >
> > This bug is being triggered a lot of times by syzbot since the day it
> > was reported. Also given that this is core networking code, I felt it
> > was important to bring this to attention.
> >
> > It looks like preemption needs to be disabled before using this_cpu_ptr
> > or maybe we would be better of using a get_cpu_var and put_cpu_var combo
> > here.
> b->media->send_msg (tipc_udp_send_msg)
> -> tipc_udp_xmit() -> dst_cache_get()
>
> send_msg() is always called under the protection of rcu_read_lock(), which
> already disabled preemption. If not, there must be some unbalanced calls of
> disable/enable preemption elsewhere.
>
> Agree that this could be a serious issue, do you have any reproducer for this?
>
> Thanks.
Hi Xin,
Sorry for the delayed response. I do not have a reproducer for this. You
can submit a patch to syzbot which can run the patch on the same system
on which it found the bug.
Thank you
Bharath
> >
> > [1] https://syzkaller.appspot.com/bug?id=dc6352b92862eb79373fe03fdf9af5928753e057
> >
> > Thank you
> > Bharath
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-09-18 10:19 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-22 19:51 net/dst_cache.c: preemption bug in net/dst_cache.c Bharath Vedartham
2019-09-09 9:48 ` Xin Long
2019-09-18 10:19 ` Bharath Vedartham
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).