Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp3522637pxb; Wed, 13 Oct 2021 07:42:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy3IJNj/aDGAuTSBip8kew6jo3J7TDMPU9avhhv1pPm7nfzwK7FAjs7yizOByVNNV9NyCR7 X-Received: by 2002:a17:902:c643:b0:13f:68b4:4abf with SMTP id s3-20020a170902c64300b0013f68b44abfmr3539262pls.82.1634136148487; Wed, 13 Oct 2021 07:42:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634136148; cv=none; d=google.com; s=arc-20160816; b=cvetfkhMcClLLnT8hpw0/P7A2hg1U44PC+ZT6VrudVj+lxxPWMbZYeClSydPp0HTFH xEMq05jLVaAjcvqiQ6490BTbgFwqdCHdRTfwAdZfGmcVAauLgEb6La67JNPx9QIT2UXa yGaiZdIdlesXwlWdr+hWTStZwZke4Wvdinv9DS3/sVJLFgTrzGBTwQ6T0l72/a2fpS1s tnSoLhcRKgXv1Fn9lyIKe4FzD7RgXS2a5JcWOGC/TYUxJ0tnJzlpNaXx1Lq3+0dWURit fujgCFXiSL+rsjuxnT3/0JsEcBfjeZk86siWLoY6ttYaUmWrhcUEnYVvBIvQApjgkdpc 4QlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:to:from:subject:message-id :dkim-signature; bh=vXA8djbogp7Sw2Cx9pnk662UT7IyGOIMEvk8gNSftSc=; b=mIiVkLfR+qvbJhsj1our9m1kKwTgMuJsT1eu3WuV9PJ/UVvI9TZ/8xLzNCAyL7202r XK1wrOeHNfeFGSNsuyPNLiB2OUrCyxzxybpTk2Jm7niXErhClD9Ah9ND8sugMVTT7Qbu zaV5ml+TAsWbWP5aJXcEf6SrBTYNcUF+zM95bMdcZ3N2U/6Fqz5W5X1VoxuHHC33zQ1J wGUmh5zgC5Usmh7xfkMT2AFXjN15CFWnhPXWLo19qwBSFOAanAIyK20pVhPF75KXxSuU yo54EO90J0IayPZL9Y0zGBC6J1SkpYnM2p0B7r26wgGbCl1RnLvtACnWvZbBAaD1JDpr O3YA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=hZOSuUQb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q4si19673636plb.162.2021.10.13.07.42.15; Wed, 13 Oct 2021 07:42:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=hZOSuUQb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236692AbhJMOnP (ORCPT + 99 others); Wed, 13 Oct 2021 10:43:15 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:27998 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237036AbhJMOnO (ORCPT ); Wed, 13 Oct 2021 10:43:14 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1634136071; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=vXA8djbogp7Sw2Cx9pnk662UT7IyGOIMEvk8gNSftSc=; b=hZOSuUQbXII24Lk5lurbAOHgYfQ9sIH3xkdxZXdO2lkfmjmkCZcb5DKEZ3AMR2vv7zK0ZR J4e+bQfdC9sgaEOZ6hd0yD8g6rLnQ98qVFWXI1wUIpsxgcF/WsTUb/JSm1eYFiFc4AKzNE /3IrTiMtzT1eZ8HlHMesnMAy+Pze8DE= Received: from mail-wr1-f69.google.com (mail-wr1-f69.google.com [209.85.221.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-265-dlqmoio3OxmbR0gTU-w-oQ-1; Wed, 13 Oct 2021 10:41:10 -0400 X-MC-Unique: dlqmoio3OxmbR0gTU-w-oQ-1 Received: by mail-wr1-f69.google.com with SMTP id h11-20020adfa4cb000000b00160c791a550so2173047wrb.6 for ; Wed, 13 Oct 2021 07:41:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:subject:from:to:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=vXA8djbogp7Sw2Cx9pnk662UT7IyGOIMEvk8gNSftSc=; b=lyAgdMhhMAVT3yrbAnqAIse6wcILJ1vNlHwSoT9t9Q3Ul7RyQW8d5Yhb0K2M/DGbwa L5UrkGoOai5YdGTp0NqxZL/20tRHImnJ35vxHiRbVU+DlAAqeTWGQ+odyYQgqmzphyBK AWMBIkNo9/4n32GOS2/vMfcxQ7ol5Vz1xftcbOznIhM/EsEwXfJFHTLekiB/LJ3DBP4q xNtokqjMihxUXjNV/dOFFBxro+80uXi1NV/T88H+5jfL2ypKs+E3UkRZNaUje+Zw0M01 uwvq5n88R7HeJcq1Ud9IUYqK1uCbyfEMmNpgZ27XgZQc7Rk84JRTh3/kyetuO6MKiPUm GR6g== X-Gm-Message-State: AOAM530zQIMaU+riTrDRvUQfSFzwINkS5RdDAxv9diuLpvy4AbLq6Azm 2cp+KcccpfjfgwfLk++GHQuIyly7UY4u19MmH+tTkqA2Dk7nDv3embcpI3poja51guxdfgjs97n mDE3bAvAXWnnxoxneCWivcoOy X-Received: by 2002:a05:600c:b41:: with SMTP id k1mr13372436wmr.4.1634136067602; Wed, 13 Oct 2021 07:41:07 -0700 (PDT) X-Received: by 2002:a05:600c:b41:: with SMTP id k1mr13372409wmr.4.1634136067387; Wed, 13 Oct 2021 07:41:07 -0700 (PDT) Received: from gerbillo.redhat.com (146-241-231-16.dyn.eolo.it. [146.241.231.16]) by smtp.gmail.com with ESMTPSA id y5sm8490227wrq.85.2021.10.13.07.41.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Oct 2021 07:41:07 -0700 (PDT) Message-ID: Subject: Re: [syzbot] BUG: corrupted list in netif_napi_add From: Paolo Abeni To: syzbot , andrii@kernel.org, ast@kernel.org, bpf@vger.kernel.org, daniel@iogearbox.net, davem@davemloft.net, hawk@kernel.org, john.fastabend@gmail.com, kafai@fb.com, kpsingh@kernel.org, kuba@kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, songliubraving@fb.com, syzkaller-bugs@googlegroups.com, yhs@fb.com Date: Wed, 13 Oct 2021 16:41:05 +0200 In-Reply-To: <0000000000005639cd05ce3a6d4d@google.com> References: <0000000000005639cd05ce3a6d4d@google.com> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.36.5 (3.36.5-2.fc32) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2021-10-13 at 04:40 -0700, syzbot wrote: > Hello, > > syzbot found the following issue on: > > HEAD commit: 683f29b781ae Add linux-next specific files for 20211008 > git tree: linux-next > console output: https://syzkaller.appspot.com/x/log.txt?x=1525a614b00000 > kernel config: https://syzkaller.appspot.com/x/.config?x=673b3589d970c > dashboard link: https://syzkaller.appspot.com/bug?extid=62e474dd92a35e3060d8 > compiler: gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2 > syz repro: https://syzkaller.appspot.com/x/repro.syz?x=17c98e98b00000 > > IMPORTANTIMPORTANT: if you fix the issue, please add the following tag to the commit: > Reported-by: syzbot+62e474dd92a35e3060d8@syzkaller.appspotmail.com > > IPv6: ADDRCONF(NETDEV_CHANGE): vcan0: link becomes ready > list_add double add: new=ffff888023417160, prev=ffff88807de3a050, next=ffff888023417160. > ------------[ cut here ]------------ > kernel BUG at lib/list_debug.c:29! > invalid opcode: 0000 [#1] PREEMPT SMP KASAN > CPU: 0 PID: 9490 Comm: syz-executor.1 Not tainted 5.15.0-rc4-next-20211008-syzkaller #0 > Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 > RIP: 0010:__list_add_valid.cold+0x26/0x3c lib/list_debug.c:29 > Code: b1 24 c3 fa 4c 89 e1 48 c7 c7 60 56 04 8a e8 f2 8c f1 ff 0f 0b 48 89 f2 4c 89 e1 48 89 ee 48 c7 c7 a0 57 04 8a e8 db 8c f1 ff <0f> 0b 48 89 f1 48 c7 c7 20 57 04 8a 4c 89 e6 e8 c7 8c f1 ff 0f 0b > RSP: 0018:ffffc90002c26a48 EFLAGS: 00010286 > RAX: 0000000000000058 RBX: 0000000000000040 RCX: 0000000000000000 > RDX: ffff888023263a00 RSI: ffffffff815e0d78 RDI: fffff52000584d3b > RBP: ffff888023417160 R08: 0000000000000058 R09: 0000000000000000 > R10: ffffffff815dab5e R11: 0000000000000000 R12: ffff888023417160 > R13: ffff888023417000 R14: ffff888023417160 R15: ffff888023417160 > FS: 00007f841e9e8700(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000 > CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 > CR2: 0000000000000000 CR3: 00000000601bd000 CR4: 00000000003506f0 > DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 > DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 > Call Trace: > > __list_add_rcu include/linux/rculist.h:79 [inline] > list_add_rcu include/linux/rculist.h:106 [inline] > netif_napi_add+0x3fd/0x9c0 net/core/dev.c:6889 > veth_enable_xdp_range+0x1b1/0x300 drivers/net/veth.c:1009 > veth_enable_xdp+0x2a5/0x620 drivers/net/veth.c:1063 > veth_xdp_set drivers/net/veth.c:1483 [inline] > veth_xdp+0x4d4/0x780 drivers/net/veth.c:1523 > bond_xdp_set drivers/net/bonding/bond_main.c:5217 [inline] > bond_xdp+0x325/0x920 drivers/net/bonding/bond_main.c:5263 > dev_xdp_install+0xd5/0x270 net/core/dev.c:9365 > dev_xdp_attach+0x83d/0x1010 net/core/dev.c:9513 > dev_change_xdp_fd+0x246/0x300 net/core/dev.c:9753 > do_setlink+0x2fb4/0x3970 net/core/rtnetlink.c:2931 > rtnl_group_changelink net/core/rtnetlink.c:3242 [inline] > __rtnl_newlink+0xc06/0x1750 net/core/rtnetlink.c:3396 > rtnl_newlink+0x64/0xa0 net/core/rtnetlink.c:3506 > rtnetlink_rcv_msg+0x413/0xb80 net/core/rtnetlink.c:5572 > netlink_rcv_skb+0x153/0x420 net/netlink/af_netlink.c:2491 > netlink_unicast_kernel net/netlink/af_netlink.c:1319 [inline] > netlink_unicast+0x533/0x7d0 net/netlink/af_netlink.c:1345 > netlink_sendmsg+0x86d/0xda0 net/netlink/af_netlink.c:1916 > sock_sendmsg_nosec net/socket.c:704 [inline] > sock_sendmsg+0xcf/0x120 net/socket.c:724 > ____sys_sendmsg+0x6e8/0x810 net/socket.c:2409 > ___sys_sendmsg+0xf3/0x170 net/socket.c:2463 > __sys_sendmsg+0xe5/0x1b0 net/socket.c:2492 > do_syscall_x64 arch/x86/entry/common.c:50 [inline] > do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 > entry_SYSCALL_64_after_hwframe+0x44/0xae > RIP: 0033:0x7f841f2718d9 > Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 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 73 01 c3 48 c7 c1 bc ff ff ff f7 d8 64 89 01 48 > RSP: 002b:00007f841e9e8188 EFLAGS: 00000246 ORIG_RAX: 000000000000002e > RAX: ffffffffffffffda RBX: 00007f841f375f60 RCX: 00007f841f2718d9 > RDX: 0000000000000000 RSI: 0000000020000140 RDI: 0000000000000003 > RBP: 00007f841f2cbcb4 R08: 0000000000000000 R09: 0000000000000000 > R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 > R13: 00007ffc8978d37f R14: 00007f841e9e8300 R15: 0000000000022000 > > Modules linked in: > ---[ end trace 7281cadbc8534f23 ]--- > RIP: 0010:__list_add_valid.cold+0x26/0x3c lib/list_debug.c:29 > Code: b1 24 c3 fa 4c 89 e1 48 c7 c7 60 56 04 8a e8 f2 8c f1 ff 0f 0b 48 89 f2 4c 89 e1 48 89 ee 48 c7 c7 a0 57 04 8a e8 db 8c f1 ff <0f> 0b 48 89 f1 48 c7 c7 20 57 04 8a 4c 89 e6 e8 c7 8c f1 ff 0f 0b > RSP: 0018:ffffc90002c26a48 EFLAGS: 00010286 > RAX: 0000000000000058 RBX: 0000000000000040 RCX: 0000000000000000 > RDX: ffff888023263a00 RSI: ffffffff815e0d78 RDI: fffff52000584d3b > RBP: ffff888023417160 R08: 0000000000000058 R09: 0000000000000000 > R10: ffffffff815dab5e R11: 0000000000000000 R12: ffff888023417160 > R13: ffff888023417000 R14: ffff888023417160 R15: ffff888023417160 > FS: 00007f841e9e8700(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000 > CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 > CR2: 0000000000000000 CR3: 00000000601bd000 CR4: 00000000003506f0 > DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 > DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 For the record: I'm wild guessing this is related to: https://syzkaller.appspot.com/bug?extid=67f89551088ea1a6850e (hopefully they share the same root cause) I spent some time investigating the latter, with no real clue. This has a repro, so I'll ask syzbot to provide more info with debug patches. Cheers, Paolo