syzbot


memory leak in __proc_create

Status: fixed on 2023/06/08 14:41
Subsystems: scsi usb
[Documentation on labels]
Reported-by: syzbot+645a4616b87a2f10e398@syzkaller.appspotmail.com
Fix commit: be03df3d4bfe scsi: core: Fix a procfs host directory removal regression
First crash: 585d, last: 585d
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [scsi?] memory leak in __proc_create 0 (1) 2023/03/07 18:05

Sample crash report:
BUG: memory leak
unreferenced object 0xffff88810af45b40 (size 192):
  comm "kworker/1:5", pid 5185, jiffies 4294972950 (age 13.730s)
  hex dump (first 32 bytes):
    00 00 00 00 01 00 00 00 48 5b f4 0a 81 88 ff ff  ........H[......
    48 5b f4 0a 81 88 ff ff 00 00 00 00 00 00 00 00  H[..............
  backtrace:
    [<ffffffff81749860>] kmem_cache_zalloc include/linux/slab.h:710 [inline]
    [<ffffffff81749860>] __proc_create+0x1a0/0x3b0 fs/proc/generic.c:426
    [<ffffffff8174a42e>] proc_create_reg+0xae/0x120 fs/proc/generic.c:553
    [<ffffffff8174a4d5>] proc_create_data+0x35/0x90 fs/proc/generic.c:573
    [<ffffffff82c2559c>] scsi_proc_host_add+0xdc/0x160 drivers/scsi/scsi_proc.c:233
    [<ffffffff82c0c26b>] scsi_add_host_with_dma+0x48b/0x500 drivers/scsi/hosts.c:311
    [<ffffffff832b7f52>] scsi_add_host include/scsi/scsi_host.h:774 [inline]
    [<ffffffff832b7f52>] usb_stor_probe2+0x2f2/0x410 drivers/usb/storage/usb.c:1056
    [<ffffffff832c5ff7>] sddr09_probe+0xb7/0x110 drivers/usb/storage/sddr09.c:1772
    [<ffffffff831c2549>] usb_probe_interface+0x179/0x3c0 drivers/usb/core/driver.c:396
    [<ffffffff82b40b0d>] call_driver_probe drivers/base/dd.c:552 [inline]
    [<ffffffff82b40b0d>] really_probe+0x12d/0x430 drivers/base/dd.c:631
    [<ffffffff82b40ecf>] __driver_probe_device+0xbf/0x140 drivers/base/dd.c:768
    [<ffffffff82b40f7a>] driver_probe_device+0x2a/0x120 drivers/base/dd.c:798
    [<ffffffff82b4116b>] __device_attach_driver+0xfb/0x150 drivers/base/dd.c:926
    [<ffffffff82b3e0f1>] bus_for_each_drv+0xc1/0x110 drivers/base/bus.c:457
    [<ffffffff82b41692>] __device_attach+0x102/0x2a0 drivers/base/dd.c:998
    [<ffffffff82b3f79a>] bus_probe_device+0xca/0xd0 drivers/base/bus.c:532
    [<ffffffff82b3bdf1>] device_add+0x991/0xc80 drivers/base/core.c:3589


Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/03/07 16:57 upstream 8ca09d5fa354 ffaa5c55 .config console log report syz ci-upstream-gce-leak memory leak in __proc_create
* Struck through repros no longer work on HEAD.