Received: by 2002:ab2:1149:0:b0:1f3:1f8c:d0c6 with SMTP id z9csp718619lqz; Sat, 30 Mar 2024 16:42:52 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUvVEN48Liuqv6pbe1riO4jn2ETyC4b5d5ooRbH46TZvqMful+pymKQ4BeaDmeKtD5JwcuOS8ZT3tEAbwXzhgoE9X18qL0D/uZUwGIqwQ== X-Google-Smtp-Source: AGHT+IFKRQntsq6YeQMCv4udYj+6Kc9uMtGMI8XZhGSQLs9eYKgN8EN5dWRD3hAUh95LxfPgfuTZ X-Received: by 2002:a05:6a20:d705:b0:1a5:7979:3349 with SMTP id iz5-20020a056a20d70500b001a579793349mr7011018pzb.6.1711842172453; Sat, 30 Mar 2024 16:42:52 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711842172; cv=pass; d=google.com; s=arc-20160816; b=B0HPRytdv5WRlWDMvvqL6NWf0TpPEo13AFFCmbdf7N/ixbIgSRy4uEZ3lNFkGuj7Sn cF5MNON9+ETsXVkZpXh/Rf05AP/ZIsTvmAlI9oyPO0kAeSRsY0qvKlGZ3sJpSM71Y5EF +FDwnIt05T2W/hGqLyMu0BhIfIYqHcUFHX2vgRNm+Y95Ou+7ZtYNUy9mmNBC54MIatKI 88gxuZ+lDgErw6Z5MtojiHyG0QqKWmwfRYF0mzkU/08e350lYb02Q85o7r4XR/mLNYhU +RLWfM5q3aoeNCP14J624L6M1OPdue8iWF3kk6NCeNDn1rX5ZYxuAG99aVHEUN137lID guyA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from; bh=7gszfGe11lcoGeyPcGF7aGo4hlOjgp30fH8DF/0ci/I=; fh=Xyn9Xj2gdyr2uCX+sXQ868jhMHETD8rbs01IV60LLJ8=; b=umS/p8yobOuFN2LDlSo3zTOhMvj58EzrtyC9xjr/YQHMH+l7JZW1VdlEOGTibb+eY7 52wrR76+6bboG1NHJeZBHkSGw6DBzSwPEiaSZKH3I1JCD5DxQajivR/WnqR1UkJnWhRR zlJOgfeK5dsmhXxH4Cm7mb0p+UkF2eJge8fWl/+WVsh9U8ktPEr74WXds27yPRYH6fkZ 3DqyLf1AGTHyXL1D2RCRJlmt/wNXuM0ydqZGUKQNfLpnrvDm/uDINDeEyXVkgttkmMZf 5j2Oj5rdYLkKId7hqEfmz38787gp+WoEseEAwlO0hyEuSkcreTOHDwjZv9FVh+MnisjO TwKw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=sina.com); spf=pass (google.com: domain of linux-kernel+bounces-125908-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-125908-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id x11-20020a17090a970b00b002a2062ecbcasi6305152pjo.165.2024.03.30.16.42.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 30 Mar 2024 16:42:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-125908-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=sina.com); spf=pass (google.com: domain of linux-kernel+bounces-125908-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-125908-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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 84D5C2825EC for ; Sat, 30 Mar 2024 23:42:51 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C68F14A99C; Sat, 30 Mar 2024 23:42:45 +0000 (UTC) Received: from mail114-240.sinamail.sina.com.cn (mail114-240.sinamail.sina.com.cn [218.30.114.240]) (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 D9C7A2E3E8 for ; Sat, 30 Mar 2024 23:42:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=218.30.114.240 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711842165; cv=none; b=a0aFpyuINsvc2+3sz8d3pSzaGca9anXaM9CaAhr5uWcQMfCTQcbX85T7iM/9TxSDijsSnFOOyVP3nSKMaEGT52bZeG+aH2j9S3tCjjr5nR+1O1kqne51anYdhCyJ0SOeczluC/hxG94i0SJzJ7qe9O4UyjZF7/0GVHNM+hnAEgI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711842165; c=relaxed/simple; bh=LkcPu3aiN8+Pp7SgssHAmiDSJJkhOmSWWOszD6D8tLE=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=jNcn5ynCPPk3y55UtdcRBz2O5cKLTox/Sr4c3yZbZYIH0+0ckbnDKQh06IB6pfm3nf7HfrYLPHgTIg4HDy93nxW1U/6fsO0ro9AqUTZsBkoIowjKuKys8cKDUgMxKdNt/su+rJYqFUYBIhLdmgyVhIGgZcaXSco2Kq6TB9Ev98c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=sina.com; spf=pass smtp.mailfrom=sina.com; arc=none smtp.client-ip=218.30.114.240 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=sina.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=sina.com X-SMAIL-HELO: localhost.localdomain Received: from unknown (HELO localhost.localdomain)([113.118.64.152]) by sina.com (172.16.235.24) with ESMTP id 6608A36300007CAB; Sat, 31 Mar 2024 07:42:30 +0800 (CST) X-Sender: hdanton@sina.com X-Auth-ID: hdanton@sina.com Authentication-Results: sina.com; spf=none smtp.mailfrom=hdanton@sina.com; dkim=none header.i=none; dmarc=none action=none header.from=hdanton@sina.com X-SMAIL-MID: 14092045089264 X-SMAIL-UIID: 77F8267D54D24F6CBA4FD1B63BC82AA7-20240331-074230-1 From: Hillf Danton To: syzbot Cc: linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com Subject: Re: [syzbot] [bpf?] possible deadlock in kvfree_call_rcu Date: Sun, 31 Mar 2024 07:42:17 +0800 Message-Id: <20240330234217.3169-1-hdanton@sina.com> In-Reply-To: <000000000000716bb60614acbf37@google.com> References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit On Wed, 27 Mar 2024 16:27:19 -0700 > syzbot has found a reproducer for the following issue on: > > HEAD commit: 443574b03387 riscv, bpf: Fix kfunc parameters incompatibil.. > git tree: bpf > C reproducer: https://syzkaller.appspot.com/x/repro.c?x=16ca53c9180000 #syz test https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git fe46a7dd189e --- x/kernel/rcu/tree.c +++ y/kernel/rcu/tree.c @@ -2957,7 +2957,8 @@ krc_this_cpu_lock(unsigned long *flags) local_irq_save(*flags); // For safely calling this_cpu_ptr(). krcp = this_cpu_ptr(&krc); - raw_spin_lock(&krcp->lock); + while (!raw_spin_trylock(&krcp->lock)) + ; return krcp; } --