linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* WARNING: suspicious RCU usage in xfrm_alloc_userspi
@ 2019-03-19 16:02 syzbot
  2019-03-19 16:23 ` Eric Dumazet
  2019-03-19 20:59 ` syzbot
  0 siblings, 2 replies; 4+ messages in thread
From: syzbot @ 2019-03-19 16:02 UTC (permalink / raw)
  To: davem, herbert, linux-kernel, netdev, steffen.klassert, syzkaller-bugs

Hello,

syzbot found the following crash on:

HEAD commit:    b9998194 Add linux-next specific files for 20190318
git tree:       linux-next
console output: https://syzkaller.appspot.com/x/log.txt?x=17a2e24d200000
kernel config:  https://syzkaller.appspot.com/x/.config?x=59cd5d43b5df6955
dashboard link: https://syzkaller.appspot.com/bug?extid=59752237f7ab21c3f3c3
compiler:       gcc (GCC) 9.0.0 20181231 (experimental)
syz repro:      https://syzkaller.appspot.com/x/repro.syz?x=14e70cb3200000
C reproducer:   https://syzkaller.appspot.com/x/repro.c?x=17292127200000

IMPORTANT: if you fix the bug, please add the following tag to the commit:
Reported-by: syzbot+59752237f7ab21c3f3c3@syzkaller.appspotmail.com

=============================
WARNING: suspicious RCU usage
5.1.0-rc1-next-20190318 #5 Not tainted
-----------------------------
net/xfrm/xfrm_user.c:1080 suspicious rcu_dereference_check() usage!

other info that might help us debug this:


rcu_scheduler_active = 2, debug_locks = 1
1 lock held by syz-executor085/7946:
  #0: 00000000a55031b5 (&net->xfrm.xfrm_cfg_mutex){+.+.}, at:  
xfrm_netlink_rcv+0x61/0x90 net/xfrm/xfrm_user.c:2691

stack backtrace:
CPU: 0 PID: 7946 Comm: syz-executor085 Not tainted 5.1.0-rc1-next-20190318  
#5
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS  
Google 01/01/2011
Call Trace:
  __dump_stack lib/dump_stack.c:77 [inline]
  dump_stack+0x172/0x1f0 lib/dump_stack.c:113
  lockdep_rcu_suspicious+0x153/0x15d kernel/locking/lockdep.c:5162
  xfrm_nlmsg_unicast net/xfrm/xfrm_user.c:1080 [inline]
  xfrm_alloc_userspi+0x7d5/0xa80 net/xfrm/xfrm_user.c:1356
  xfrm_user_rcv_msg+0x458/0x770 net/xfrm/xfrm_user.c:2684
  netlink_rcv_skb+0x17a/0x460 net/netlink/af_netlink.c:2485
  xfrm_netlink_rcv+0x70/0x90 net/xfrm/xfrm_user.c:2692
  netlink_unicast_kernel net/netlink/af_netlink.c:1310 [inline]
  netlink_unicast+0x536/0x720 net/netlink/af_netlink.c:1336
  netlink_sendmsg+0x8ae/0xd70 net/netlink/af_netlink.c:1925
  sock_sendmsg_nosec net/socket.c:651 [inline]
  sock_sendmsg+0xdd/0x130 net/socket.c:661
  ___sys_sendmsg+0x806/0x930 net/socket.c:2260
  __sys_sendmsg+0x105/0x1d0 net/socket.c:2298
  __do_sys_sendmsg net/socket.c:2307 [inline]
  __se_sys_sendmsg net/socket.c:2305 [inline]
  __x64_sys_sendmsg+0x78/0xb0 net/socket.c:2305
  do_syscall_64+0x103/0x610 arch/x86/entry/common.c:290
  entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x440499
Code: 18 89 d0 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 00 48 89 f8 48 89 f7  
48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff  
ff 0f 83 fb 13 fc ff c3 66 2e 0f 1f 84 00 00 00 00
RSP: 002b:00007ffcf12caf08 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
RAX: ffffffffffffffda RBX: 00000000004002c8 RCX: 0000000000440499
RDX: 0000000000000000 RSI: 00000000200006c0 RDI: 0000000000000003
RBP: 00000000006ca018 R08: 0000000000000000 R09: 00000000004002c8
R10: 0000000000000000 R11: 0000000000000246 R12: 000000000040


---
This bug is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzkaller@googlegroups.com.

syzbot will keep track of this bug report. See:
https://goo.gl/tpsmEJ#bug-status-tracking for how to communicate with  
syzbot.
syzbot can test patches for this bug, for details see:
https://goo.gl/tpsmEJ#testing-patches

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: WARNING: suspicious RCU usage in xfrm_alloc_userspi
  2019-03-19 16:02 WARNING: suspicious RCU usage in xfrm_alloc_userspi syzbot
@ 2019-03-19 16:23 ` Eric Dumazet
  2019-03-20  0:55   ` Su Yanjun <suyj.fnst@cn.fujitsu.com>
  2019-03-19 20:59 ` syzbot
  1 sibling, 1 reply; 4+ messages in thread
From: Eric Dumazet @ 2019-03-19 16:23 UTC (permalink / raw)
  To: syzbot, davem, herbert, linux-kernel, netdev, steffen.klassert,
	syzkaller-bugs, Su Yanjun

CC Su Yanjun 

On 03/19/2019 09:02 AM, syzbot wrote:
> Hello,
> 
> syzbot found the following crash on:
> 
> HEAD commit:    b9998194 Add linux-next specific files for 20190318
> git tree:       linux-next
> console output: https://syzkaller.appspot.com/x/log.txt?x=17a2e24d200000
> kernel config:  https://syzkaller.appspot.com/x/.config?x=59cd5d43b5df6955
> dashboard link: https://syzkaller.appspot.com/bug?extid=59752237f7ab21c3f3c3
> compiler:       gcc (GCC) 9.0.0 20181231 (experimental)
> syz repro:      https://syzkaller.appspot.com/x/repro.syz?x=14e70cb3200000
> C reproducer:   https://syzkaller.appspot.com/x/repro.c?x=17292127200000
> 
> IMPORTANT: if you fix the bug, please add the following tag to the commit:
> Reported-by: syzbot+59752237f7ab21c3f3c3@syzkaller.appspotmail.com
> 
> =============================
> WARNING: suspicious RCU usage
> 5.1.0-rc1-next-20190318 #5 Not tainted
> -----------------------------
> net/xfrm/xfrm_user.c:1080 suspicious rcu_dereference_check() usage!
> 
> other info that might help us debug this:
> 
> 
> rcu_scheduler_active = 2, debug_locks = 1
> 1 lock held by syz-executor085/7946:
>  #0: 00000000a55031b5 (&net->xfrm.xfrm_cfg_mutex){+.+.}, at: xfrm_netlink_rcv+0x61/0x90 net/xfrm/xfrm_user.c:2691
> 
> stack backtrace:
> CPU: 0 PID: 7946 Comm: syz-executor085 Not tainted 5.1.0-rc1-next-20190318 #5
> Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
> Call Trace:
>  __dump_stack lib/dump_stack.c:77 [inline]
>  dump_stack+0x172/0x1f0 lib/dump_stack.c:113
>  lockdep_rcu_suspicious+0x153/0x15d kernel/locking/lockdep.c:5162
>  xfrm_nlmsg_unicast net/xfrm/xfrm_user.c:1080 [inline]
>  xfrm_alloc_userspi+0x7d5/0xa80 net/xfrm/xfrm_user.c:1356
>  xfrm_user_rcv_msg+0x458/0x770 net/xfrm/xfrm_user.c:2684
>  netlink_rcv_skb+0x17a/0x460 net/netlink/af_netlink.c:2485
>  xfrm_netlink_rcv+0x70/0x90 net/xfrm/xfrm_user.c:2692
>  netlink_unicast_kernel net/netlink/af_netlink.c:1310 [inline]
>  netlink_unicast+0x536/0x720 net/netlink/af_netlink.c:1336
>  netlink_sendmsg+0x8ae/0xd70 net/netlink/af_netlink.c:1925
>  sock_sendmsg_nosec net/socket.c:651 [inline]
>  sock_sendmsg+0xdd/0x130 net/socket.c:661
>  ___sys_sendmsg+0x806/0x930 net/socket.c:2260
>  __sys_sendmsg+0x105/0x1d0 net/socket.c:2298
>  __do_sys_sendmsg net/socket.c:2307 [inline]
>  __se_sys_sendmsg net/socket.c:2305 [inline]
>  __x64_sys_sendmsg+0x78/0xb0 net/socket.c:2305
>  do_syscall_64+0x103/0x610 arch/x86/entry/common.c:290
>  entry_SYSCALL_64_after_hwframe+0x49/0xbe
> RIP: 0033:0x440499
> Code: 18 89 d0 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 fb 13 fc ff c3 66 2e 0f 1f 84 00 00 00 00
> RSP: 002b:00007ffcf12caf08 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
> RAX: ffffffffffffffda RBX: 00000000004002c8 RCX: 0000000000440499
> RDX: 0000000000000000 RSI: 00000000200006c0 RDI: 0000000000000003
> RBP: 00000000006ca018 R08: 0000000000000000 R09: 00000000004002c8
> R10: 0000000000000000 R11: 0000000000000246 R12: 000000000040
> 
> 
> ---
> This bug is generated by a bot. It may contain errors.
> See https://goo.gl/tpsmEJ for more information about syzbot.
> syzbot engineers can be reached at syzkaller@googlegroups.com.
> 
> syzbot will keep track of this bug report. See:
> https://goo.gl/tpsmEJ#bug-status-tracking for how to communicate with syzbot.
> syzbot can test patches for this bug, for details see:
> https://goo.gl/tpsmEJ#testing-patches

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: WARNING: suspicious RCU usage in xfrm_alloc_userspi
  2019-03-19 16:02 WARNING: suspicious RCU usage in xfrm_alloc_userspi syzbot
  2019-03-19 16:23 ` Eric Dumazet
@ 2019-03-19 20:59 ` syzbot
  1 sibling, 0 replies; 4+ messages in thread
From: syzbot @ 2019-03-19 20:59 UTC (permalink / raw)
  To: davem, eric.dumazet, fw, herbert, linux-kernel, netdev,
	steffen.klassert, suyj.fnst, syzkaller-bugs

syzbot has bisected this bug to:

commit f10e0010fae8174dc20bdc872bcaa85baa925cb7
Author: Su Yanjun <suyj.fnst@cn.fujitsu.com>
Date:   Thu Mar 7 01:54:08 2019 +0000

     net: xfrm: Add '_rcu' tag for rcu protected pointer in netns_xfrm

bisection log:  https://syzkaller.appspot.com/x/bisect.txt?x=1644ec8b200000
start commit:   f10e0010 net: xfrm: Add '_rcu' tag for rcu protected point..
git tree:       linux-next
final crash:    https://syzkaller.appspot.com/x/report.txt?x=1544ec8b200000
console output: https://syzkaller.appspot.com/x/log.txt?x=1144ec8b200000
kernel config:  https://syzkaller.appspot.com/x/.config?x=59cd5d43b5df6955
dashboard link: https://syzkaller.appspot.com/bug?extid=59752237f7ab21c3f3c3
syz repro:      https://syzkaller.appspot.com/x/repro.syz?x=14e70cb3200000
C reproducer:   https://syzkaller.appspot.com/x/repro.c?x=17292127200000

Reported-by: syzbot+59752237f7ab21c3f3c3@syzkaller.appspotmail.com
Fixes: f10e0010 ("net: xfrm: Add '_rcu' tag for rcu protected pointer in  
netns_xfrm")

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: WARNING: suspicious RCU usage in xfrm_alloc_userspi
  2019-03-19 16:23 ` Eric Dumazet
@ 2019-03-20  0:55   ` Su Yanjun <suyj.fnst@cn.fujitsu.com>
  0 siblings, 0 replies; 4+ messages in thread
From: Su Yanjun <suyj.fnst@cn.fujitsu.com> @ 2019-03-20  0:55 UTC (permalink / raw)
  To: Eric Dumazet, syzbot, davem, herbert, linux-kernel, netdev,
	steffen.klassert, syzkaller-bugs


On 2019/3/20 0:23, Eric Dumazet wrote:
> CC Su Yanjun
>
> On 03/19/2019 09:02 AM, syzbot wrote:
>> Hello,
>>
>> syzbot found the following crash on:
>>
>> HEAD commit:    b9998194 Add linux-next specific files for 20190318
>> git tree:       linux-next
>> console output: https://syzkaller.appspot.com/x/log.txt?x=17a2e24d200000
>> kernel config:  https://syzkaller.appspot.com/x/.config?x=59cd5d43b5df6955
>> dashboard link: https://syzkaller.appspot.com/bug?extid=59752237f7ab21c3f3c3
>> compiler:       gcc (GCC) 9.0.0 20181231 (experimental)
>> syz repro:      https://syzkaller.appspot.com/x/repro.syz?x=14e70cb3200000
>> C reproducer:   https://syzkaller.appspot.com/x/repro.c?x=17292127200000
>>
>> IMPORTANT: if you fix the bug, please add the following tag to the commit:
>> Reported-by: syzbot+59752237f7ab21c3f3c3@syzkaller.appspotmail.com
>>
>> =============================
>> WARNING: suspicious RCU usage
>> 5.1.0-rc1-next-20190318 #5 Not tainted
>> -----------------------------
>> net/xfrm/xfrm_user.c:1080 suspicious rcu_dereference_check() usage!
>>
>> other info that might help us debug this:
>>
>>
>> rcu_scheduler_active = 2, debug_locks = 1
>> 1 lock held by syz-executor085/7946:
>>   #0: 00000000a55031b5 (&net->xfrm.xfrm_cfg_mutex){+.+.}, at: xfrm_netlink_rcv+0x61/0x90 net/xfrm/xfrm_user.c:2691
>>
>> stack backtrace:
>> CPU: 0 PID: 7946 Comm: syz-executor085 Not tainted 5.1.0-rc1-next-20190318 #5
>> Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
>> Call Trace:
>>   __dump_stack lib/dump_stack.c:77 [inline]
>>   dump_stack+0x172/0x1f0 lib/dump_stack.c:113
>>   lockdep_rcu_suspicious+0x153/0x15d kernel/locking/lockdep.c:5162
>>   xfrm_nlmsg_unicast net/xfrm/xfrm_user.c:1080 [inline]
>>   xfrm_alloc_userspi+0x7d5/0xa80 net/xfrm/xfrm_user.c:1356
>>   xfrm_user_rcv_msg+0x458/0x770 net/xfrm/xfrm_user.c:2684
>>   netlink_rcv_skb+0x17a/0x460 net/netlink/af_netlink.c:2485
>>   xfrm_netlink_rcv+0x70/0x90 net/xfrm/xfrm_user.c:2692
>>   netlink_unicast_kernel net/netlink/af_netlink.c:1310 [inline]
>>   netlink_unicast+0x536/0x720 net/netlink/af_netlink.c:1336
>>   netlink_sendmsg+0x8ae/0xd70 net/netlink/af_netlink.c:1925
>>   sock_sendmsg_nosec net/socket.c:651 [inline]
>>   sock_sendmsg+0xdd/0x130 net/socket.c:661
>>   ___sys_sendmsg+0x806/0x930 net/socket.c:2260
>>   __sys_sendmsg+0x105/0x1d0 net/socket.c:2298
>>   __do_sys_sendmsg net/socket.c:2307 [inline]
>>   __se_sys_sendmsg net/socket.c:2305 [inline]
>>   __x64_sys_sendmsg+0x78/0xb0 net/socket.c:2305
>>   do_syscall_64+0x103/0x610 arch/x86/entry/common.c:290
>>   entry_SYSCALL_64_after_hwframe+0x49/0xbe
>> RIP: 0033:0x440499
>> Code: 18 89 d0 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 fb 13 fc ff c3 66 2e 0f 1f 84 00 00 00 00
>> RSP: 002b:00007ffcf12caf08 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
>> RAX: ffffffffffffffda RBX: 00000000004002c8 RCX: 0000000000440499
>> RDX: 0000000000000000 RSI: 00000000200006c0 RDI: 0000000000000003
>> RBP: 00000000006ca018 R08: 0000000000000000 R09: 00000000004002c8
>> R10: 0000000000000000 R11: 0000000000000246 R12: 000000000040
>>
>>
>> ---
>> This bug is generated by a bot. It may contain errors.
>> See https://goo.gl/tpsmEJ for more information about syzbot.
>> syzbot engineers can be reached at syzkaller@googlegroups.com.
>>
>> syzbot will keep track of this bug report. See:
>> https://goo.gl/tpsmEJ#bug-status-tracking for how to communicate with syzbot.
>> syzbot can test patches for this bug, for details see:
>> https://goo.gl/tpsmEJ#testing-patches

I  got it.

Thanks




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-03-20  0:55 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-19 16:02 WARNING: suspicious RCU usage in xfrm_alloc_userspi syzbot
2019-03-19 16:23 ` Eric Dumazet
2019-03-20  0:55   ` Su Yanjun <suyj.fnst@cn.fujitsu.com>
2019-03-19 20:59 ` syzbot

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).