Received: by 2002:a05:7412:5112:b0:fa:6e18:a558 with SMTP id fm18csp368462rdb; Tue, 23 Jan 2024 02:05:15 -0800 (PST) X-Google-Smtp-Source: AGHT+IHP3EoCykdGBX8xN/muKBDUf3dIMxwACFWYVyeg3ELtc/g2Hu+utXc8NJED5rBYGvvws4yb X-Received: by 2002:a05:6402:1612:b0:55c:7c67:c45f with SMTP id f18-20020a056402161200b0055c7c67c45fmr464068edv.56.1706004314870; Tue, 23 Jan 2024 02:05:14 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706004314; cv=pass; d=google.com; s=arc-20160816; b=VqVdbpEwAs0yBEAFSyes5jA+oDjQfVVPaVIzLfDIpq8vMHb2QNBHeVfxGg2+gLJJYK YidWETfn3rZ1Bjnl0GCKgRIT0JtlTyn9+3p0HUonzT/simi4rRZ17NTocoiwZkEbSded 8G/ton5ZGJRXRClRjHbJ5O5nfd4fmA9T+JlGS7VQb+vcwgGt/g3hePvSaIEcB0n747A2 mW8bFnBycIoY5YGxK1mn2xqQPptaq3dDhvwL5iiMam7ZcZifBjVRVlMZOSVjZfldT06L HO0af8dMoi4vSzfMIVKyNpQ36UUT9ll5Qrlw+bSotD50Kf1bf5/dG0qtcczRyAukIMzd y45A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=to:from:subject:message-id:in-reply-to:date:mime-version :list-unsubscribe:list-subscribe:list-id:precedence; bh=AS2P3nQdsUNC5p4LXiOIShjbvIlAWTYX3zFAQ+Hlvpc=; fh=ASkzh1hihoqljkDw3HfUYnTGfH8gTlTbXU5VCwnW0rg=; b=OY7x6HqdGXO314xKHslFmion28++o0E8JpVnLUKuVZ2rl6bYi2laNyTL/vPh8EMf9u QMDgyHVT0g1C2qzDZ2dUZMSBWUh4ZqNooNUREBg90gjEcxLoU4d1BEXOJKidxZHZ9IOF htjHtyIMFoC2sZ/67Vh9gWToTuZwR173/oq7JPDSpiCfAYX4/REPwcpVejEx1Mw3Zf5i iqWkgqVy8bE7t8hdH6n7ZL4fAHH66A0e73VKwuVUNVObouF6mzXGVmgdAzsid1o8B7bo mOm0acvjUbdxv1MgypKB7f1ujpr6RGexdW71xhy836svsHAZDIsfcSrfLwEqTCcEjlLB 3D+w== ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=m3kw2wvrgufz5godrsrytgd7.apphosting.bounces.google.com); spf=pass (google.com: domain of linux-kernel+bounces-35064-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-35064-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=appspotmail.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id z10-20020a056402274a00b0055c211f83desi2639526edd.631.2024.01.23.02.05.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 Jan 2024 02:05:14 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-35064-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=m3kw2wvrgufz5godrsrytgd7.apphosting.bounces.google.com); spf=pass (google.com: domain of linux-kernel+bounces-35064-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-35064-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=appspotmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 7557D1F26C85 for ; Tue, 23 Jan 2024 10:05:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id CA4BB5BAF7; Tue, 23 Jan 2024 10:05:09 +0000 (UTC) Received: from mail-io1-f72.google.com (mail-io1-f72.google.com [209.85.166.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 72F2C5A790 for ; Tue, 23 Jan 2024 10:05:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.166.72 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706004309; cv=none; b=WPXPOE7UvTqkBN/dIIM3kbHfSpPOW6nYSHAnU2Vy88Z/3XW6zCJ5uZAQdcGH0s6RBSwIGFvHYHTDARJGOi3r9XlGFIWzKgy4hx2R1cpGsupj+9YZJkp1GDwkRW8vTaiLVgv+/CC6ysayboFdRfn4DZXAl68E/jIn4p/aRKqcRhY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706004309; c=relaxed/simple; bh=tBswinHhOGAiuHYYwrfJBeuwv6s6in2J1BirPS7AHa8=; h=MIME-Version:Date:In-Reply-To:Message-ID:Subject:From:To: Content-Type; b=m+VqDitLhupPDXCHF9fLtbKagCUS4ERKk2rWOKYsaxSuVCvFieTn/qOFx9lU87wZ4DQ3ivAAEeZxeltB3jqIvS8OhyQAhji7vnQmg7r6QdAA6fFEDo/OB9jXVl7V+4XWvTvErE1QYZkHVlLOR7hj6D5JudJKqCCzmtuTMimvyTY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=syzkaller.appspotmail.com; spf=pass smtp.mailfrom=M3KW2WVRGUFZ5GODRSRYTGD7.apphosting.bounces.google.com; arc=none smtp.client-ip=209.85.166.72 Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=syzkaller.appspotmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=M3KW2WVRGUFZ5GODRSRYTGD7.apphosting.bounces.google.com Received: by mail-io1-f72.google.com with SMTP id ca18e2360f4ac-7beebd130aaso415019939f.1 for ; Tue, 23 Jan 2024 02:05:07 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706004306; x=1706609106; h=to:from:subject:message-id:in-reply-to:date:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=AS2P3nQdsUNC5p4LXiOIShjbvIlAWTYX3zFAQ+Hlvpc=; b=HJQIdnDcU3cEvBs8/0PkltNbr6ZXtA07nEFEzR5c4neaLpZP6RLCpwrYw1BMnoHw42 r2BKFB3D+qpHnVstr3+fUQivPrGm0oh7odIAtmantwRfT61juMJc0vmw5YVuvM3LRnKO sOdrixxn+ol+VwB9kjw6oyg5sxHS7QKGs6AlqJkzz6NA0rgeedJyvDW3QtvrOB50OwGC wzEyb+YGZrErC2t72EPOq9mLO1i6toHN6Q4CahOhCgRw9EDTCM9T/XCqDicUMaazTrxg egJ5PQEOK+pstl+xeNkkR1nB2i3DkU9W2o88qt8l4PbNMNlaaRqNWEhmgihW7Rrdojq5 arTA== X-Gm-Message-State: AOJu0YwUkMb1zzcbyIKvxAJciCnK3cayc9p0fr4z0zStDZgRAS0UFJ07 EX9N8zeZ25awcyESQ6PdSL+2h9hmcNmNcJAvJ3fyu7mNz3b16RkPf2Q2k4R0skAlVim+fexN/wr nBiacAJC1cr+w6wQinj45OkB1i/+p15ba9G8cVu12665Wo6BJ8B7MUjc= Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Received: by 2002:a05:6638:148a:b0:46e:d877:ef75 with SMTP id j10-20020a056638148a00b0046ed877ef75mr240084jak.3.1706004306199; Tue, 23 Jan 2024 02:05:06 -0800 (PST) Date: Tue, 23 Jan 2024 02:05:06 -0800 In-Reply-To: X-Google-Appengine-App-Id: s~syzkaller X-Google-Appengine-App-Id-Alias: syzkaller Message-ID: <000000000000a80f14060f9a1430@google.com> Subject: Re: [syzbot] [can?] memory leak in j1939_netdev_start From: syzbot To: eadavis@qq.com, linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com Content-Type: text/plain; charset="UTF-8" Hello, syzbot has tested the proposed patch but the reproducer is still triggering an issue: memory leak in corrupted BUG: memory leak unreferenced object 0xffff888122468000 (size 8192): comm "syz-executor.3", pid 5871, jiffies 4294945607 hex dump (first 32 bytes): 00 80 46 22 81 88 ff ff 00 80 46 22 81 88 ff ff ..F"......F".... 00 00 00 00 00 00 00 00 00 80 03 1b 81 88 ff ff ................ backtrace (crc aa0f28f1): [] kmemleak_alloc_recursive include/linux/kmemleak.h:42 [inline] [] slab_post_alloc_hook mm/slub.c:3817 [inline] [] slab_alloc_node mm/slub.c:3860 [inline] [] kmalloc_trace+0x283/0x330 mm/slub.c:4007 [] kmalloc include/linux/slab.h:590 [inline] [] kzalloc include/linux/slab.h:711 [inline] [] j1939_priv_create net/can/j1939/main.c:135 [inline] [] j1939_netdev_start+0x159/0x6f0 net/can/j1939/main.c:272 [] j1939_sk_bind+0x21e/0x550 net/can/j1939/socket.c:486 [] __sys_bind+0x11c/0x130 net/socket.c:1847 [] __do_sys_bind net/socket.c:1858 [inline] [] __se_sys_bind net/socket.c:1856 [inline] [] __x64_sys_bind+0x1c/0x20 net/socket.c:1856 [] do_syscall_x64 arch/x86/entry/common.c:52 [inline] [] do_syscall_64+0x50/0x140 arch/x86/entry/common.c:83 [] entry_SYSCALL_64_after_hwframe+0x63/0x6b BUG: memory leak unreferenced object 0xffff888122b02200 (size 240): comm "softirq", pid 0, jiffies 4294945607 hex dump (first 32 bytes): 68 ac 2a 22 81 88 ff ff 68 ac 2a 22 81 88 ff ff h.*"....h.*".... 00 80 03 1b 81 88 ff ff 00 00 00 00 00 00 00 00 ................ backtrace (crc 54b3c139): [] kmemleak_alloc_recursive include/linux/kmemleak.h:42 [inline] [] slab_post_alloc_hook mm/slub.c:3817 [inline] [] slab_alloc_node mm/slub.c:3860 [inline] [] kmem_cache_alloc_node+0x28a/0x330 mm/slub.c:3903 [] __alloc_skb+0x1ef/0x230 net/core/skbuff.c:641 [] alloc_skb include/linux/skbuff.h:1296 [inline] [] j1939_session_fresh_new net/can/j1939/transport.c:1536 [inline] [] j1939_xtp_rx_rts_session_new net/can/j1939/transport.c:1633 [inline] [] j1939_xtp_rx_rts+0x4ba/0xa70 net/can/j1939/transport.c:1737 [] j1939_tp_cmd_recv net/can/j1939/transport.c:2060 [inline] [] j1939_tp_recv+0x1b5/0x7f0 net/can/j1939/transport.c:2147 [] j1939_can_recv+0x349/0x4e0 net/can/j1939/main.c:112 [] deliver net/can/af_can.c:572 [inline] [] can_rcv_filter+0xd4/0x290 net/can/af_can.c:606 [] can_receive+0xf0/0x140 net/can/af_can.c:663 [] can_rcv+0xf0/0x130 net/can/af_can.c:687 [] __netif_receive_skb_one_core+0x66/0x90 net/core/dev.c:5534 [] __netif_receive_skb+0x1d/0x90 net/core/dev.c:5648 [] process_backlog+0xbc/0x190 net/core/dev.c:5976 [] __napi_poll+0x3e/0x310 net/core/dev.c:6576 [] napi_poll net/core/dev.c:6645 [inline] [] net_rx_action+0x3d8/0x510 net/core/dev.c:6778 [] __do_softirq+0xbd/0x2b0 kernel/softirq.c:553 BUG: memory leak unreferenced object 0xffff888122b40000 (size 131072): comm "softirq", pid 0, jiffies 4294945607 hex dump (first 32 bytes): 0e 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ backtrace (crc f7abe560): [] __kmalloc_large_node+0xde/0x150 mm/slub.c:3935 [] __do_kmalloc_node mm/slub.c:3969 [inline] [] __kmalloc_node_track_caller+0x35f/0x420 mm/slub.c:4001 [] kmalloc_reserve+0x96/0x170 net/core/skbuff.c:582 [] __alloc_skb+0xd5/0x230 net/core/skbuff.c:651 [] alloc_skb include/linux/skbuff.h:1296 [inline] [] j1939_session_fresh_new net/can/j1939/transport.c:1536 [inline] [] j1939_xtp_rx_rts_session_new net/can/j1939/transport.c:1633 [inline] [] j1939_xtp_rx_rts+0x4ba/0xa70 net/can/j1939/transport.c:1737 [] j1939_tp_cmd_recv net/can/j1939/transport.c:2060 [inline] [] j1939_tp_recv+0x1b5/0x7f0 net/can/j1939/transport.c:2147 [] j1939_can_recv+0x349/0x4e0 net/can/j1939/main.c:112 [] deliver net/can/af_can.c:572 [inline] [] can_rcv_filter+0xd4/0x290 net/can/af_can.c:606 [] can_receive+0xf0/0x140 net/can/af_can.c:663 [] can_rcv+0xf0/0x130 net/can/af_can.c:687 [] __netif_receive_skb_one_core+0x66/0x90 net/core/dev.c:5534 [] __netif_receive_skb+0x1d/0x90 net/core/dev.c:5648 [] process_backlog+0xbc/0x190 net/core/dev.c:5976 [] __napi_poll+0x3e/0x310 net/core/dev.c:6576 [] napi_poll net/core/dev.c:6645 [inline] [] net_rx_action+0x3d8/0x510 net/core/dev.c:6778 [] __do_softirq+0xbd/0x2b0 kernel/softirq.c:553 BUG: memory leak unreferenced object 0xffff8881222aac00 (size 512): comm "softirq", pid 0, jiffies 4294945607 hex dump (first 32 bytes): 00 80 46 22 81 88 ff ff 28 90 46 22 81 88 ff ff ..F"....(.F".... 28 90 46 22 81 88 ff ff 18 ac 2a 22 81 88 ff ff (.F"......*".... backtrace (crc 32877ad9): [] kmemleak_alloc_recursive include/linux/kmemleak.h:42 [inline] [] slab_post_alloc_hook mm/slub.c:3817 [inline] [] slab_alloc_node mm/slub.c:3860 [inline] [] kmalloc_trace+0x283/0x330 mm/slub.c:4007 [] kmalloc include/linux/slab.h:590 [inline] [] kzalloc include/linux/slab.h:711 [inline] [] j1939_session_new+0x53/0x140 net/can/j1939/transport.c:1495 [] j1939_session_fresh_new net/can/j1939/transport.c:1547 [inline] [] j1939_xtp_rx_rts_session_new net/can/j1939/transport.c:1633 [inline] [] j1939_xtp_rx_rts+0x54c/0xa70 net/can/j1939/transport.c:1737 [] j1939_tp_cmd_recv net/can/j1939/transport.c:2060 [inline] [] j1939_tp_recv+0x1b5/0x7f0 net/can/j1939/transport.c:2147 [] j1939_can_recv+0x349/0x4e0 net/can/j1939/main.c:112 [] deliver net/can/af_can.c:572 [inline] [] can_rcv_filter+0xd4/0x290 net/can/af_can.c:606 [] can_receive+0xf0/0x140 net/can/af_can.c:663 [] can_rcv+0xf0/0x130 net/can/af_can.c:687 [] __netif_receive_skb_one_core+0x66/0x90 net/core/dev.c:5534 [] __netif_receive_skb+0x1d/0x90 net/core/dev.c:5648 [] process_backlog+0xbc/0x190 net/core/dev.c:5976 [] __napi_poll+0x3e/0x310 net/core/dev.c:6576 [] napi_poll net/core/dev.c:6645 [inline] [] net_rx_action+0x3d8/0x510 net/core/dev.c:6778 [] __do_softirq+0xbd/0x2b0 kernel/softirq.c:553 Tested on: commit: 7ed2632e drm/ttm: fix ttm pool initialization for no-d.. git tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master console output: https://syzkaller.appspot.com/x/log.txt?x=1681d2d7e80000 kernel config: https://syzkaller.appspot.com/x/.config?x=9f6b64adeddd3dbc dashboard link: https://syzkaller.appspot.com/bug?extid=1d37bef05da87b99c5a6 compiler: gcc (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40 patch: https://syzkaller.appspot.com/x/patch.diff?x=1770fa6be80000