syzbot


memory leak in __team_options_register

Status: fixed on 2020/11/16 12:12
Subsystems: net
[Documentation on labels]
Reported-by: syzbot+69b804437cfec30deac3@syzkaller.appspotmail.com
Fix commit: 9a9e77495958 net: team: fix memory leak in __team_options_register
First crash: 1554d, last: 1554d
Discussions (8)
Title Replies (including bot) Last reply
[PATCH 5.8 000/124] 5.8.15-rc1 review 136 (136) 2020/10/14 18:31
[PATCH 4.4 00/39] 4.4.239-rc1 review 46 (46) 2020/10/14 10:18
[PATCH 4.19 00/49] 4.19.151-rc1 review 56 (56) 2020/10/14 08:34
[PATCH 4.9 00/54] 4.9.239-rc1 review 58 (58) 2020/10/14 01:39
[PATCH 4.14 00/70] 4.14.201-rc1 review 74 (74) 2020/10/14 01:28
[PATCH 5.4 00/85] 5.4.71-rc1 review 89 (89) 2020/10/14 01:24
[PATCH] net: team: fix memory leak in __team_options_register 2 (2) 2020/10/04 21:48
memory leak in __team_options_register 0 (1) 2020/09/07 21:19
Last patch testing requests (2)
Created Duration User Patch Repo Result
2020/10/04 11:05 15m anant.thazhemadam@gmail.com patch upstream OK
2020/10/04 09:25 7m anant.thazhemadam@gmail.com upstream report log

Sample crash report:
BUG: memory leak
unreferenced object 0xffff8881197f4cc0 (size 64):
  comm "syz-executor772", pid 6506, jiffies 4294951766 (age 20.400s)
  hex dump (first 32 bytes):
    00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
    41 aa 0c 84 ff ff ff ff 01 00 00 00 00 00 00 00  A...............
  backtrace:
    [<000000000c781965>] kmemdup+0x23/0x50 mm/util.c:127
    [<00000000bdcac628>] kmemdup include/linux/string.h:479 [inline]
    [<00000000bdcac628>] __team_options_register+0xf7/0x2c0 drivers/net/team/team.c:269
    [<00000000d0decc27>] team_options_register drivers/net/team/team.c:340 [inline]
    [<00000000d0decc27>] team_init+0x1b2/0x2f0 drivers/net/team/team.c:1643
    [<00000000b2b1c890>] register_netdevice+0x143/0x760 net/core/dev.c:9760
    [<000000001344192b>] __rtnl_newlink+0x8f0/0xbc0 net/core/rtnetlink.c:3441
    [<00000000254132c3>] rtnl_newlink+0x49/0x70 net/core/rtnetlink.c:3500
    [<000000001566c9e7>] rtnetlink_rcv_msg+0x17e/0x460 net/core/rtnetlink.c:5563
    [<0000000017d9fa2a>] netlink_rcv_skb+0x5b/0x180 net/netlink/af_netlink.c:2470
    [<00000000c4f11d5e>] netlink_unicast_kernel net/netlink/af_netlink.c:1304 [inline]
    [<00000000c4f11d5e>] netlink_unicast+0x2b6/0x3c0 net/netlink/af_netlink.c:1330
    [<0000000066743465>] netlink_sendmsg+0x2ba/0x570 net/netlink/af_netlink.c:1919
    [<000000005d0b195e>] sock_sendmsg_nosec net/socket.c:651 [inline]
    [<000000005d0b195e>] sock_sendmsg+0x4c/0x60 net/socket.c:671
    [<0000000008f94e79>] ____sys_sendmsg+0x118/0x2f0 net/socket.c:2353
    [<00000000e00d63ed>] ___sys_sendmsg+0x81/0xc0 net/socket.c:2407
    [<000000005e9d5313>] __sys_sendmmsg+0xda/0x230 net/socket.c:2497
    [<000000002479ea72>] __do_sys_sendmmsg net/socket.c:2526 [inline]
    [<000000002479ea72>] __se_sys_sendmmsg net/socket.c:2523 [inline]
    [<000000002479ea72>] __x64_sys_sendmmsg+0x24/0x30 net/socket.c:2523
    [<0000000032159aee>] do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46

BUG: memory leak
unreferenced object 0xffff88811b4e0b80 (size 64):
  comm "syz-executor772", pid 6508, jiffies 4294951886 (age 19.210s)
  hex dump (first 32 bytes):
    00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
    41 aa 0c 84 ff ff ff ff 01 00 00 00 00 00 00 00  A...............
  backtrace:
    [<000000000c781965>] kmemdup+0x23/0x50 mm/util.c:127
    [<00000000bdcac628>] kmemdup include/linux/string.h:479 [inline]
    [<00000000bdcac628>] __team_options_register+0xf7/0x2c0 drivers/net/team/team.c:269
    [<00000000d0decc27>] team_options_register drivers/net/team/team.c:340 [inline]
    [<00000000d0decc27>] team_init+0x1b2/0x2f0 drivers/net/team/team.c:1643
    [<00000000b2b1c890>] register_netdevice+0x143/0x760 net/core/dev.c:9760
    [<000000001344192b>] __rtnl_newlink+0x8f0/0xbc0 net/core/rtnetlink.c:3441
    [<00000000254132c3>] rtnl_newlink+0x49/0x70 net/core/rtnetlink.c:3500
    [<000000001566c9e7>] rtnetlink_rcv_msg+0x17e/0x460 net/core/rtnetlink.c:5563
    [<0000000017d9fa2a>] netlink_rcv_skb+0x5b/0x180 net/netlink/af_netlink.c:2470
    [<00000000c4f11d5e>] netlink_unicast_kernel net/netlink/af_netlink.c:1304 [inline]
    [<00000000c4f11d5e>] netlink_unicast+0x2b6/0x3c0 net/netlink/af_netlink.c:1330
    [<0000000066743465>] netlink_sendmsg+0x2ba/0x570 net/netlink/af_netlink.c:1919
    [<000000005d0b195e>] sock_sendmsg_nosec net/socket.c:651 [inline]
    [<000000005d0b195e>] sock_sendmsg+0x4c/0x60 net/socket.c:671
    [<0000000008f94e79>] ____sys_sendmsg+0x118/0x2f0 net/socket.c:2353
    [<00000000e00d63ed>] ___sys_sendmsg+0x81/0xc0 net/socket.c:2407
    [<000000005e9d5313>] __sys_sendmmsg+0xda/0x230 net/socket.c:2497
    [<000000002479ea72>] __do_sys_sendmmsg net/socket.c:2526 [inline]
    [<000000002479ea72>] __se_sys_sendmmsg net/socket.c:2523 [inline]
    [<000000002479ea72>] __x64_sys_sendmmsg+0x24/0x30 net/socket.c:2523
    [<0000000032159aee>] do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46

BUG: memory leak
unreferenced object 0xffff88811b4e03c0 (size 64):
  comm "syz-executor772", pid 6518, jiffies 4294951923 (age 18.840s)
  hex dump (first 32 bytes):
    00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
    41 aa 0c 84 ff ff ff ff 01 00 00 00 00 00 00 00  A...............
  backtrace:
    [<000000000c781965>] kmemdup+0x23/0x50 mm/util.c:127
    [<00000000bdcac628>] kmemdup include/linux/string.h:479 [inline]
    [<00000000bdcac628>] __team_options_register+0xf7/0x2c0 drivers/net/team/team.c:269
    [<00000000d0decc27>] team_options_register drivers/net/team/team.c:340 [inline]
    [<00000000d0decc27>] team_init+0x1b2/0x2f0 drivers/net/team/team.c:1643
    [<00000000b2b1c890>] register_netdevice+0x143/0x760 net/core/dev.c:9760
    [<000000001344192b>] __rtnl_newlink+0x8f0/0xbc0 net/core/rtnetlink.c:3441
    [<00000000254132c3>] rtnl_newlink+0x49/0x70 net/core/rtnetlink.c:3500
    [<000000001566c9e7>] rtnetlink_rcv_msg+0x17e/0x460 net/core/rtnetlink.c:5563
    [<0000000017d9fa2a>] netlink_rcv_skb+0x5b/0x180 net/netlink/af_netlink.c:2470
    [<00000000c4f11d5e>] netlink_unicast_kernel net/netlink/af_netlink.c:1304 [inline]
    [<00000000c4f11d5e>] netlink_unicast+0x2b6/0x3c0 net/netlink/af_netlink.c:1330
    [<0000000066743465>] netlink_sendmsg+0x2ba/0x570 net/netlink/af_netlink.c:1919
    [<000000005d0b195e>] sock_sendmsg_nosec net/socket.c:651 [inline]
    [<000000005d0b195e>] sock_sendmsg+0x4c/0x60 net/socket.c:671
    [<0000000008f94e79>] ____sys_sendmsg+0x118/0x2f0 net/socket.c:2353
    [<00000000e00d63ed>] ___sys_sendmsg+0x81/0xc0 net/socket.c:2407
    [<000000005e9d5313>] __sys_sendmmsg+0xda/0x230 net/socket.c:2497
    [<000000002479ea72>] __do_sys_sendmmsg net/socket.c:2526 [inline]
    [<000000002479ea72>] __se_sys_sendmmsg net/socket.c:2523 [inline]
    [<000000002479ea72>] __x64_sys_sendmmsg+0x24/0x30 net/socket.c:2523
    [<0000000032159aee>] do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46

executing program
executing program
executing program
executing program
executing program
executing program
executing program

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2020/09/07 20:03 upstream f4d51dffc6c0 abf9ba4f .config console log report syz C ci-upstream-gce-leak
* Struck through repros no longer work on HEAD.