syzbot


memory leak in kobject_set_name_vargs (5)

Status: upstream: reported syz repro on 2022/06/22 23:13
Reported-by: syzbot+7381dc4ad60658ca4c05@syzkaller.appspotmail.com
First crash: 6d11h, last: 6d11h
similar bugs (4):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream memory leak in kobject_set_name_vargs C 12 1089d 1122d 13/22 fixed on 2019/07/10 21:40
upstream memory leak in kobject_set_name_vargs (3) C 19 586d 642d 17/22 fixed on 2020/11/16 12:12
upstream memory leak in kobject_set_name_vargs (2) C done 47 883d 1067d 16/22 fixed on 2020/02/18 14:31
upstream memory leak in kobject_set_name_vargs (4) C 171 294d 581d 22/22 fixed on 2021/11/10 00:51

Sample crash report:
BUG: memory leak
unreferenced object 0xffff88811943b700 (size 32):
  comm "syz-executor.7", pid 3953, jiffies 4294958653 (age 15.830s)
  hex dump (first 32 bytes):
    6c 6f 6f 70 37 00 00 00 00 00 00 00 00 00 00 00  loop7...........
    00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
  backtrace:
    [<ffffffff814b7106>] kstrdup+0x36/0x70 mm/util.c:61
    [<ffffffff814b7193>] kstrdup_const+0x53/0x80 mm/util.c:84
    [<ffffffff8239acd2>] kvasprintf_const+0xc2/0x110 lib/kasprintf.c:48
    [<ffffffff8249179b>] kobject_set_name_vargs+0x3b/0xe0 lib/kobject.c:257
    [<ffffffff82491c1d>] kobject_add_varg lib/kobject.c:352 [inline]
    [<ffffffff82491c1d>] kobject_init_and_add+0x6d/0xc0 lib/kobject.c:441
    [<ffffffff81e2c07a>] nilfs_sysfs_create_device_group+0x9a/0x3d0 fs/nilfs2/sysfs.c:991
    [<ffffffff81e1482c>] init_nilfs+0x51c/0x680 fs/nilfs2/the_nilfs.c:637
    [<ffffffff81e004db>] nilfs_fill_super fs/nilfs2/super.c:1047 [inline]
    [<ffffffff81e004db>] nilfs_mount+0x51b/0x890 fs/nilfs2/super.c:1317
    [<ffffffff8163fb5b>] legacy_get_tree+0x2b/0x90 fs/fs_context.c:610
    [<ffffffff815d95c8>] vfs_get_tree+0x28/0x100 fs/super.c:1497
    [<ffffffff8161d097>] do_new_mount fs/namespace.c:3040 [inline]
    [<ffffffff8161d097>] path_mount+0xc37/0x1120 fs/namespace.c:3370
    [<ffffffff8161dcce>] do_mount fs/namespace.c:3383 [inline]
    [<ffffffff8161dcce>] __do_sys_mount fs/namespace.c:3591 [inline]
    [<ffffffff8161dcce>] __se_sys_mount fs/namespace.c:3568 [inline]
    [<ffffffff8161dcce>] __x64_sys_mount+0x18e/0x1d0 fs/namespace.c:3568
    [<ffffffff845a9cb5>] do_syscall_x64 arch/x86/entry/common.c:50 [inline]
    [<ffffffff845a9cb5>] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
    [<ffffffff8460006a>] entry_SYSCALL_64_after_hwframe+0x46/0xb0


Crashes (1):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci-upstream-gce-leak 2022/06/18 23:11 upstream 4b35035bcf80 8f633d84 .config log report syz memory leak in kobject_set_name_vargs