Received: by 2002:ab2:620c:0:b0:1ef:ffd0:ce49 with SMTP id o12csp1348631lqt; Wed, 20 Mar 2024 00:31:13 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCV23RP8kuXkH6diFgYRqRotuAT+nPEHJVYOyWt95skskpy6dIe/o8Fb83mWsNbrM1ZTd3YknkK7Yk7/wo5E6M5FG2jhJF+vOFBeY1IUrw== X-Google-Smtp-Source: AGHT+IHsIbsTluo6dnI0SAJzLy/XVg1hH0fOUdM6EP/4WhSzu9Cd7xgFlD3a3W+kqTXBkbTzFiuG X-Received: by 2002:a17:906:b297:b0:a46:f2fa:1bc9 with SMTP id q23-20020a170906b29700b00a46f2fa1bc9mr798488ejz.57.1710919872809; Wed, 20 Mar 2024 00:31:12 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710919872; cv=pass; d=google.com; s=arc-20160816; b=KEqkwdE6ZnOpnWV0JZdRSRbiYxmkEV5LFUUUQtdNJ/YVScPdpiZJPdJZzumglkGuGA beukx0G46PBYG8hLTXedYpdTWQD7Bgrr3T+8Ie5U2d0Ut1mx7cetYhMOLjhUKzMLePKN gAvNbLCYzVFfnVHfEsS+jYfAd/rKyheQTm4UBVPZ9xWnnrXtdoAiVRhEc391gus49BRa fwiNsYBtM9oQMAmsorvLtH5P6ydp5cX9Ho6f61jz3k+/EsM3kWXcLc8h0RUMR+ZLiib+ XHXiKyxvdhdfZh5HDxRXR6Qc2duZ+YFDPt9v1QRP2dZRdWHMILMqzQNaQANYr8WAXSHL wj7A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id; bh=nvSUX4tgYpx3hYoErnqpKWySI/a4rjrCeA4aG+wOp7I=; fh=lE5LT6IhwUkvE2PVKIap6VlON2I/MMhZ8AaIqhJSvzs=; b=X+YzD96tC0wAJMvf8+cCk/PNQWQL0nE8bfhh871D6P5YiRJ3i9u4XVLjnvk0IckVjk FKbJs5p9r/Nk2OOKHD0j767U3muqOtvQF9UzPMOGYihMGkOrgJHy6rHggDjONEpZZLge zmRjZ9N+xIdSnZCPN5lujZUe5Z011Z14dOLy/jom+YhXdul0ZwB8KLtzQRIsQhIo9JFo aVrn9zpciyT242qaCHrq3ZJXIwaDG/G18DOJSKBj93fuS7fwf963naEXsows6T+d99kr UjnkzVja+iei5elidvoKAfwOYyLTCi0skWrjzdLeWVncEXC3JZh4qFPzN4xXOpLHWF1J Wlag==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=i-love.sakura.ne.jp); spf=pass (google.com: domain of linux-kernel+bounces-108542-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-108542-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id qw27-20020a170906fcbb00b00a46534b54edsi6036655ejb.767.2024.03.20.00.31.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Mar 2024 00:31:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-108542-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=i-love.sakura.ne.jp); spf=pass (google.com: domain of linux-kernel+bounces-108542-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-108542-linux.lists.archive=gmail.com@vger.kernel.org" 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 7F8C31F23E78 for ; Wed, 20 Mar 2024 07:31:12 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AB6D4219E8; Wed, 20 Mar 2024 07:31:05 +0000 (UTC) Received: from www262.sakura.ne.jp (www262.sakura.ne.jp [202.181.97.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 605AA2030A for ; Wed, 20 Mar 2024 07:31:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=202.181.97.72 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710919865; cv=none; b=QAa/W7Xm3s5XvQirUBahAUJ3OaUTh7mAmQOgunfUKP/um7vqIBHYvQHNTr0kt+mvep4hrSy/rqcS1cO//qkVEeW+0uRkzABmQzC5wXsC6Ffgt+LH74RhSRHCb9Vm2aQlDjzXF701ltPlsEvd6IKJTBqDtUWvgzb+RJh322C0DBs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710919865; c=relaxed/simple; bh=2ROv1GJ5AGVwHAmuJlmT49x+qPwpZZF2PlyQYtwg5dk=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=d52nb0gnRNXvz8i1tUcXXDSf+B7sPc0FtcN0u4ser24RYv6mV9nZ67VYNraM9Am40+RFIVCVC0KIAARXLhizZ43em7enn8DUDFTY3HRvgNsaC2bpK2TFYyQ6vVMMJm+C5YlLbR9PenespP7Xpq15LyFkHJtfbPq6xCtmTxCf5Fc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=I-love.SAKURA.ne.jp; spf=pass smtp.mailfrom=I-love.SAKURA.ne.jp; arc=none smtp.client-ip=202.181.97.72 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=I-love.SAKURA.ne.jp Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=I-love.SAKURA.ne.jp Received: from fsav117.sakura.ne.jp (fsav117.sakura.ne.jp [27.133.134.244]) by www262.sakura.ne.jp (8.15.2/8.15.2) with ESMTP id 42K7UOJq005451; Wed, 20 Mar 2024 16:30:24 +0900 (JST) (envelope-from penguin-kernel@I-love.SAKURA.ne.jp) Received: from www262.sakura.ne.jp (202.181.97.72) by fsav117.sakura.ne.jp (F-Secure/fsigk_smtp/550/fsav117.sakura.ne.jp); Wed, 20 Mar 2024 16:30:24 +0900 (JST) X-Virus-Status: clean(F-Secure/fsigk_smtp/550/fsav117.sakura.ne.jp) Received: from [192.168.1.6] (M106072142033.v4.enabler.ne.jp [106.72.142.33]) (authenticated bits=0) by www262.sakura.ne.jp (8.15.2/8.15.2) with ESMTPSA id 42K7UOVc005448 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NO); Wed, 20 Mar 2024 16:30:24 +0900 (JST) (envelope-from penguin-kernel@I-love.SAKURA.ne.jp) Message-ID: Date: Wed, 20 Mar 2024 16:30:24 +0900 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [syzbot] [kernel?] possible deadlock in console_flush_all (2) Content-Language: en-US To: Alexei Starovoitov Cc: syzbot , syzkaller-bugs , Alexei Starovoitov , Daniel Borkmann , John Fastabend , Petr Mladek , Steven Rostedt , John Ogness , Sergey Senozhatsky , Thomas Gleixner , LKML , bpf References: <000000000000e40a2906072e9567@google.com> <596aad11-ee69-4ef1-b945-7b67a9fb22d7@I-love.SAKURA.ne.jp> From: Tetsuo Handa In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On 2024/03/20 16:12, Alexei Starovoitov wrote: > On Wed, Mar 20, 2024 at 12:05 AM Tetsuo Handa > wrote: >> >> On 2024/03/20 15:56, Alexei Starovoitov wrote: >>> This has nothing to do with bpf. >>> bpf never calls printk(). >> >> Please see the Sample crash report in the dashboard. >> bpf program is hitting printk() via report_bug(). > > Exactly. local_bh_neable is simply asking for a splat. > _this_ bug is in printk. > It's a generic issue. I can't catch. printk() is called due to report_bug(). If the reason report_bug() is called is that spin_unlock_bh() is bad, this is a bug in sock_map_delete_elem() rather than a bug in printk(), isn't it. > > sockmap bug is orthogonal. > It's already being looked at. Then, can we expect that this bug is also fixed shortly? > >> -> #0 (console_owner){....}-{0:0}: >> check_prev_add kernel/locking/lockdep.c:3134 [inline] >> check_prevs_add kernel/locking/lockdep.c:3253 [inline] >> validate_chain+0x18cb/0x58e0 kernel/locking/lockdep.c:3869 >> __lock_acquire+0x1346/0x1fd0 kernel/locking/lockdep.c:5137 >> lock_acquire+0x1e4/0x530 kernel/locking/lockdep.c:5754 >> console_lock_spinning_enable kernel/printk/printk.c:1873 [inline] >> console_emit_next_record kernel/printk/printk.c:2901 [inline] >> console_flush_all+0x810/0xfd0 kernel/printk/printk.c:2973 >> console_unlock+0x13b/0x4d0 kernel/printk/printk.c:3042 >> vprintk_emit+0x5a6/0x770 kernel/printk/printk.c:2342 >> _printk+0xd5/0x120 kernel/printk/printk.c:2367 >> __report_bug lib/bug.c:195 [inline] >> report_bug+0x346/0x500 lib/bug.c:219 >> handle_bug+0x3e/0x70 arch/x86/kernel/traps.c:239 >> exc_invalid_op+0x1a/0x50 arch/x86/kernel/traps.c:260 >> asm_exc_invalid_op+0x1a/0x20 arch/x86/include/asm/idtentry.h:621 >> __local_bh_enable_ip+0x1be/0x200 kernel/softirq.c:362 >> spin_unlock_bh include/linux/spinlock.h:396 [inline] >> __sock_map_delete net/core/sock_map.c:424 [inline] >> sock_map_delete_elem+0xca/0x140 net/core/sock_map.c:446 >> bpf_prog_2c29ac5cdc6b1842+0x42/0x46 >> bpf_dispatcher_nop_func include/linux/bpf.h:1234 [inline] >> __bpf_prog_run include/linux/filter.h:657 [inline] >> bpf_prog_run include/linux/filter.h:664 [inline]