syzbot


WARNING in snd_usbmidi_submit_urb/usb_submit_urb
Status: fixed on 2020/09/16 22:51
Reported-by: syzbot+5f1d24c49c1d2c427497@syzkaller.appspotmail.com
Fix commit: 9b7e5208a941 ALSA: usb-audio: Fix race against the error recovery URB submission
First crash: 731d, last: 701d

Cause bisection: introduced by (bisect log) :
commit f2c2e717642c66f7fe7e5dd69b2e8ff5849f4d10
Author: Andrey Konovalov <andreyknvl@google.com>
Date: Mon Feb 24 16:13:03 2020 +0000

  usb: gadget: add raw-gadget interface

Crash: WARNING in snd_usbmidi_submit_urb/usb_submit_urb (log)
Repro: syz .config

Sample crash report:
------------[ cut here ]------------
URB 00000000543c4bbd submitted while active
WARNING: CPU: 0 PID: 7185 at drivers/usb/core/urb.c:363 usb_submit_urb+0x10c1/0x13b0 drivers/usb/core/urb.c:363
Kernel panic - not syncing: panic_on_warn set ...
CPU: 0 PID: 7185 Comm: syz-executor719 Not tainted 5.7.0-syzkaller #0
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+0x188/0x20d lib/dump_stack.c:118
 panic+0x2e3/0x75c kernel/panic.c:221
 __warn.cold+0x2f/0x35 kernel/panic.c:582
 report_bug+0x27b/0x2f0 lib/bug.c:195
 fixup_bug arch/x86/kernel/traps.c:105 [inline]
 fixup_bug arch/x86/kernel/traps.c:100 [inline]
 do_error_trap+0x12b/0x220 arch/x86/kernel/traps.c:197
 do_invalid_op+0x32/0x40 arch/x86/kernel/traps.c:216
 invalid_op+0x23/0x30 arch/x86/entry/entry_64.S:1027
RIP: 0010:usb_submit_urb+0x10c1/0x13b0 drivers/usb/core/urb.c:363
Code: 89 de e8 82 aa 63 fc 84 db 0f 85 42 f6 ff ff e8 15 a9 63 fc 4c 89 fe 48 c7 c7 c0 22 ac 88 c6 05 5d 63 76 05 01 e8 a7 ad 34 fc <0f> 0b e9 20 f6 ff ff c7 44 24 14 01 00 00 00 e9 d7 f6 ff ff 41 bd
RSP: 0018:ffffc900022172c0 EFLAGS: 00010286
RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff815d88a7 RDI: fffff52000442e4a
RBP: dffffc0000000000 R08: ffff8880a6938100 R09: ffffed1015cc6715
R10: ffff8880ae6338a7 R11: ffffed1015cc6714 R12: 0000000000000cc0
R13: 00000000fffffff0 R14: ffff888090ccc000 R15: ffff88809df99700
 snd_usbmidi_submit_urb+0x19/0x60 sound/usb/midi.c:194
 snd_usbmidi_input_start_ep sound/usb/midi.c:2313 [inline]
 snd_usbmidi_input_start.part.0+0xbe/0x1c0 sound/usb/midi.c:2329
 snd_usbmidi_input_start sound/usb/midi.c:1119 [inline]
 substream_open.isra.0+0x505/0x830 sound/usb/midi.c:1119
 open_substream+0x42e/0x880 sound/core/rawmidi.c:299
 rawmidi_open_priv+0x2e8/0x6e0 sound/core/rawmidi.c:342
 snd_rawmidi_kernel_open+0x1b5/0x270 sound/core/rawmidi.c:382
 midisynth_subscribe+0xf2/0x350 sound/core/seq/seq_midi.c:170
 subscribe_port sound/core/seq/seq_ports.c:412 [inline]
 check_and_subscribe_port+0x5b5/0x800 sound/core/seq/seq_ports.c:495
 snd_seq_port_connect+0x2e4/0x510 sound/core/seq/seq_ports.c:564
 snd_seq_ioctl_subscribe_port+0x1df/0x310 sound/core/seq/seq_clientmgr.c:1484
 snd_seq_kernel_client_ctl+0xeb/0x130 sound/core/seq/seq_clientmgr.c:2353
 snd_seq_oss_midi_open+0x3ee/0x670 sound/core/seq/oss/seq_oss_midi.c:364
 snd_seq_oss_synth_setup_midi+0x123/0x520 sound/core/seq/oss/seq_oss_synth.c:269
 snd_seq_oss_open+0x7fa/0x980 sound/core/seq/oss/seq_oss_init.c:261
 odev_open+0x6c/0x90 sound/core/seq/oss/seq_oss.c:125
 soundcore_open+0x446/0x600 sound/sound_core.c:593
 chrdev_open+0x219/0x5c0 fs/char_dev.c:414
 do_dentry_open+0x546/0x1340 fs/open.c:828
 do_open fs/namei.c:3229 [inline]
 path_openat+0x1e59/0x27d0 fs/namei.c:3346
 do_filp_open+0x192/0x260 fs/namei.c:3373
 do_sys_openat2+0x585/0x7d0 fs/open.c:1179
 do_sys_open+0xc3/0x140 fs/open.c:1195
 do_syscall_64+0xf6/0x7d0 arch/x86/entry/common.c:295
 entry_SYSCALL_64_after_hwframe+0x49/0xb3
RIP: 0033:0x445719
Code: e8 8c e8 ff ff 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 eb cc fb ff c3 66 2e 0f 1f 84 00 00 00 00
RSP: 002b:00007fff53fd3828 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 0000000000445719
RDX: 000000000000c006 RSI: 0000000020000040 RDI: ffffffffffffff9c
RBP: 00000000000932b2 R08: 0000000000000000 R09: 00000000004002e0
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000402890
R13: 0000000000402920 R14: 0000000000000000 R15: 0000000000000000
Kernel Offset: disabled
Rebooting in 86400 seconds..

Crashes (42):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci-upstream-kasan-gce-root 2020/06/05 11:09 upstream 435faf5c218a 2420d1bc .config log report syz C
ci-upstream-kasan-gce-selinux-root 2020/06/04 14:15 upstream cb8e59cc8720 b0d1c0d5 .config log report syz C
ci-upstream-kasan-gce-root 2020/06/03 06:17 upstream 1ee08de1e234 f3ba1b5b .config log report syz C
ci-upstream-kasan-gce-386 2020/06/05 02:56 upstream acf25aa66371 6720fdef .config log report syz C
ci-upstream-kasan-gce-386 2020/06/04 10:52 upstream cb8e59cc8720 b0d1c0d5 .config log report syz C
ci-upstream-kasan-gce-386 2020/06/03 05:40 upstream 1ee08de1e234 f3ba1b5b .config log report syz C
ci-upstream-kasan-gce-root 2020/06/01 03:55 upstream bdc48fa11e46 a0331e89 .config log report syz
ci-upstream-kasan-gce 2020/06/25 11:51 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce 2020/06/25 04:23 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce 2020/06/24 23:05 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce-root 2020/06/24 22:32 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce 2020/06/24 22:15 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce 2020/06/24 22:11 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce 2020/06/24 21:57 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce-root 2020/06/24 13:00 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce-root 2020/06/24 08:55 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce-root 2020/06/10 18:23 upstream 7ae77150d94d a6f7998d .config log report
ci-upstream-kasan-gce-root 2020/06/10 16:02 upstream 7ae77150d94d a6f7998d .config log report
ci-upstream-kasan-gce 2020/06/10 10:39 upstream 7ae77150d94d 860c4de9 .config log report
ci-upstream-kasan-gce 2020/06/07 23:02 upstream 7ae77150d94d 2c2b926c .config log report
ci-upstream-kasan-gce-selinux-root 2020/06/05 06:48 upstream 435faf5c218a 2420d1bc .config log report
ci-upstream-kasan-gce 2020/06/05 06:05 upstream acf25aa66371 6720fdef .config log report
ci-upstream-kasan-gce 2020/06/04 16:37 upstream cb8e59cc8720 b0d1c0d5 .config log report
ci-upstream-kasan-gce-selinux-root 2020/06/04 10:16 upstream cb8e59cc8720 b0d1c0d5 .config log report
ci-upstream-kasan-gce-selinux-root 2020/06/03 10:53 upstream 1ee08de1e234 f3ba1b5b .config log report
ci-upstream-kasan-gce 2020/06/03 10:52 upstream 1ee08de1e234 f3ba1b5b .config log report
ci-upstream-kasan-gce-root 2020/06/03 01:41 upstream 1ee08de1e234 f3ba1b5b .config log report
ci-upstream-kasan-gce-selinux-root 2020/06/02 11:23 upstream f359287765c0 a0331e89 .config log report
ci-upstream-kasan-gce-root 2020/06/01 21:18 upstream 9bf9511e3d9f a0331e89 .config log report
ci-upstream-kasan-gce 2020/06/01 20:26 upstream 3d77e6a8804a a0331e89 .config log report
ci-upstream-kasan-gce 2020/06/01 03:44 upstream bdc48fa11e46 a0331e89 .config log report
ci-upstream-kasan-gce-root 2020/06/01 03:41 upstream bdc48fa11e46 a0331e89 .config log report
ci-upstream-kasan-gce-root 2020/05/31 22:58 upstream bdc48fa11e46 a0331e89 .config log report
ci-upstream-kasan-gce-386 2020/06/24 21:37 upstream 7ae77150d94d 54566aff .config log report
ci-upstream-kasan-gce-386 2020/06/10 18:42 upstream 7ae77150d94d a6f7998d .config log report
ci-upstream-kasan-gce-386 2020/06/07 17:04 upstream 7ae77150d94d 2c2b926c .config log report
ci-upstream-kasan-gce-386 2020/06/03 20:22 upstream d6f9469a03d8 a5ce5de0 .config log report
ci-upstream-kasan-gce-386 2020/06/03 03:18 upstream 1ee08de1e234 f3ba1b5b .config log report
ci-upstream-kasan-gce-386 2020/06/01 20:41 upstream 3d77e6a8804a a0331e89 .config log report
ci-upstream-kasan-gce-386 2020/05/31 23:27 upstream bdc48fa11e46 a0331e89 .config log report
ci-upstream-linux-next-kasan-gce-root 2020/05/26 02:00 linux-next 7b4cb0a48db0 30927cd7 .config log report