syzbot


WARNING: locking bug in nfs_get_client

Status: fixed on 2019/06/14 18:22
Subsystems: nfs
[Documentation on labels]
Reported-by: syzbot+228a82b263b5da91883d@syzkaller.appspotmail.com
Fix commit: c260121a97a3 NFS: Fix a double unlock from nfs_match,get_client
First crash: 1807d, last: 1806d
Cause bisection: introduced by (bisect log) :
commit 950a578c6128c2886e295b9c7ecb0b6b22fcc92b
Author: Roberto Bergantinos Corpas <rbergant@redhat.com>
Date: Thu Apr 25 13:36:51 2019 +0000

  NFS: make nfs_match_client killable

Crash: WARNING: locking bug in nfs_get_client (log)
Repro: C syz .config
  
Discussions (5)
Title Replies (including bot) Last reply
[PATCH 4.19 000/276] 4.19.47-stable review 304 (304) 2019/06/06 19:22
[PATCH 5.0 000/346] 5.0.20-stable review 355 (355) 2019/05/31 14:18
[PATCH 5.1 000/405] 5.1.6-stable review 414 (414) 2019/05/31 14:16
[PATCH 4.14 000/193] 4.14.123-stable review 199 (199) 2019/05/31 05:16
WARNING: locking bug in nfs_get_client 3 (5) 2019/05/09 12:06

Sample crash report:
------------[ cut here ]------------
DEBUG_LOCKS_WARN_ON(depth <= 0)
WARNING: CPU: 1 PID: 7948 at kernel/locking/lockdep.c:4052 __lock_release kernel/locking/lockdep.c:4052 [inline]
WARNING: CPU: 1 PID: 7948 at kernel/locking/lockdep.c:4052 lock_release+0x667/0xa00 kernel/locking/lockdep.c:4321
Kernel panic - not syncing: panic_on_warn set ...
CPU: 1 PID: 7948 Comm: syz-executor561 Not tainted 5.1.0-next-20190508 #3
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
 panic+0x2cb/0x75a kernel/panic.c:218
 __warn.cold+0x20/0x47 kernel/panic.c:575
 report_bug+0x263/0x2b0 lib/bug.c:186
 fixup_bug arch/x86/kernel/traps.c:179 [inline]
 fixup_bug arch/x86/kernel/traps.c:174 [inline]
 do_error_trap+0x11b/0x200 arch/x86/kernel/traps.c:272
 do_invalid_op+0x37/0x50 arch/x86/kernel/traps.c:291
 invalid_op+0x14/0x20 arch/x86/entry/entry_64.S:972
RIP: 0010:__lock_release kernel/locking/lockdep.c:4052 [inline]
RIP: 0010:lock_release+0x667/0xa00 kernel/locking/lockdep.c:4321
Code: 0f 85 a0 03 00 00 8b 35 a7 02 09 08 85 f6 75 23 48 c7 c6 e0 57 6b 87 48 c7 c7 80 27 6b 87 4c 89 85 70 ff ff ff e8 37 7c eb ff <0f> 0b 4c 8b 85 70 ff ff ff 4c 89 ea 4c 89 e6 4c 89 c7 e8 52 63 ff
RSP: 0018:ffff888095867730 EFLAGS: 00010082
RAX: 0000000000000000 RBX: 1ffff11012b0ceec RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff815b20c6 RDI: ffffed1012b0ced8
RBP: ffff8880958677e8 R08: ffff88809a5b83c0 R09: fffffbfff1133071
R10: fffffbfff1133070 R11: ffffffff88998383 R12: ffff888219eeb700
R13: ffffffff821668ab R14: ffffffff8a45bd40 R15: ffff8880958677c0
 __raw_spin_unlock include/linux/spinlock_api_smp.h:150 [inline]
 _raw_spin_unlock+0x1b/0x50 kernel/locking/spinlock.c:183
 spin_unlock include/linux/spinlock.h:378 [inline]
 nfs_get_client+0xc1b/0x1300 fs/nfs/client.c:412
 nfs_init_server+0x26f/0xea0 fs/nfs/client.c:675
 nfs_create_server+0x12b/0x6d0 fs/nfs/client.c:962
 nfs_try_mount+0x15a/0x910 fs/nfs/super.c:1882
 nfs_fs_mount+0x184a/0x2690 fs/nfs/super.c:2718
 legacy_get_tree+0x10a/0x220 fs/fs_context.c:665
 vfs_get_tree+0x93/0x3a0 fs/super.c:1476
 do_new_mount fs/namespace.c:2790 [inline]
 do_mount+0x138c/0x1c00 fs/namespace.c:3110
 ksys_mount+0xdb/0x150 fs/namespace.c:3319
 __do_sys_mount fs/namespace.c:3333 [inline]
 __se_sys_mount fs/namespace.c:3330 [inline]
 __x64_sys_mount+0xbe/0x150 fs/namespace.c:3330
 do_syscall_64+0x103/0x670 arch/x86/entry/common.c:298
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x4467d9
Code: e8 5c b3 02 00 48 83 c4 18 c3 0f 1f 80 00 00 00 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 0b 08 fc ff c3 66 2e 0f 1f 84 00 00 00 00
RSP: 002b:00007f54c53e0db8 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00000000006dbc38 RCX: 00000000004467d9
RDX: 0000000020fb5ffc RSI: 0000000020343ff8 RDI: 0000000000000000
RBP: 00000000006dbc30 R08: 000000002000a000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00000000006dbc3c
R13: 00007ffe22037e2f R14: 00007f54c53e19c0 R15: 20c49ba5e353f7cf
Kernel Offset: disabled
Rebooting in 86400 seconds..

Crashes (13):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2019/05/08 22:41 linux-next 31ccad9ba503 1ab4c999 .config console log report syz C ci-upstream-linux-next-kasan-gce-root
2019/05/10 02:25 linux-next 13b704419877 018207ef .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/10 01:14 linux-next 13b704419877 018207ef .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/09 14:07 linux-next 13b704419877 6fc130d3 .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/09 07:53 linux-next 31ccad9ba503 1ab4c999 .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/09 04:31 linux-next 31ccad9ba503 1ab4c999 .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/08 21:44 linux-next 31ccad9ba503 1ab4c999 .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/08 21:43 linux-next 31ccad9ba503 1ab4c999 .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/08 21:07 linux-next 31ccad9ba503 1ab4c999 .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/08 21:04 linux-next 31ccad9ba503 1ab4c999 .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/08 20:50 linux-next 31ccad9ba503 1ab4c999 .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/08 20:30 linux-next 31ccad9ba503 1ab4c999 .config console log report ci-upstream-linux-next-kasan-gce-root
2019/05/08 20:16 linux-next 31ccad9ba503 1ab4c999 .config console log report ci-upstream-linux-next-kasan-gce-root
* Struck through repros no longer work on HEAD.