Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 59FCB217659 for ; Sat, 22 Aug 2026 15:39:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787413195; cv=none; b=IwUQauiU8UrjNj++92OErkB1sgtQXNH7NBa+SH7Six2oRO0ShSL/5gXbxneacRxXzWwZumUNSNptNrYEwMMZSMbptUTl3RPM3mHN2OpuibrfdzLg/C04N0nErYiBTxMcoIolweObheasuQGHmIr74Jf2zpW+S7oKs3E2JQgDAMc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787413195; c=relaxed/simple; bh=O1cwCFx1s6WniQz2LDNca1QuJIyAtiohGTa2d6xgTcA=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=VodrLcqbK3MB4OnG86nNwqZDTkQaoy7rQaw3SgE4OjsEfDqECOBNuEahW3oNOQ7iIyVEkr0kiKuxprcPIM+ZBcibdrypjoWWZoIS4Myt4aPgMPYJAASYtQnPap8PYi8dQJ2TMlvZA+n3cduVLGx6uKAtGyk8H+TUwgUdRyXG5bA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=LT15qsAc; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="LT15qsAc" Received: by smtp.kernel.org (Postfix) with ESMTPSA id A478A1F000E9; Sat, 22 Aug 2026 15:39:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1787413194; bh=zVshfTfye2hvarmw61zF3wWKBlhx3ya8T5ygBA4prCE=; h=From:To:Cc:Subject:Date:Reply-To; b=LT15qsAcn40U4gnvD6t+PM6CQwy281U6NmI50BfPpR46x4T4ZqdfyOlB9C9iy0X+Z qOHrwZ7hF2qgLYZqSl4yjuVT74GMKr3zAasMHXrgBJIltHddRhm2OQ2GvfzhAhkpQx OkLty7RBS3Z4Rs1gu4H9t98zXLs15tTE2M+4VFmU= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-74686: rqspinlock: Reset tail when preserving queue on deadlock Date: Sat, 22 Aug 2026 17:32:50 +0200 Message-ID: <2026082232-CVE-2026-74686-ccee@gregkh> X-Mailer: git-send-email 2.55.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=3840; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=0D0NCYLiTJs4erjmzf6P6i1l2bhNVtHb2ZkwSx20VY4=; b=owGbwMvMwCRo6H6F97bub03G02pJDFmdB666q2YzW5Q/OrPkicXxHCOD7pOVvL8OTn/lNeGUn dfJBKe9HbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjARiVkMCzZMeHDnxrF9Cv3v H29b2d7389dGU3+GBV07K851+/Or9Nfp3WCw/99b4c8sAQA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: rqspinlock: Reset tail when preserving queue on deadlock Currently, the destruction of the waiter queue is suppressed for rqspinlock in cases where a deadlock is detected. Deadlock checks happen relatively frequently (on entry for AA, within 1ms for ABBA), and waiter threads may not be involved in locking scenarios involving deadlocks. Thus, it is useful to not flush the queue and let other waiters take a stab at acquiring the lock after we detect a deadlock and exit. However, we need to follow the same logic as what we did previously for the waitq_timeout label: reset the tail, and if we cannot, signal the next waiter appropriately. In case of deadlocks, this signal would just mark the MCS node as unlocked, and in case of timeouts, it would signal RES_TIMEOUT_VAL. The difference thus is in the value propagated, which decides whether the queue remains active or gets flushed. Not doing the tail reset, and waiting for the next waiter can lead to cases where we are the final waiter, and thus no next waiter arrives, leading to intermittent stalls in this path. Once the next waiter does join, we will be unblocked. In the theoretical case when the next waiter never joins, we risk stalling indefinitely. This can only happen for ABBA deadlocks, since entry into the wait queue is guarded with AA checks. A precise sequence of executions leading up to this scenario can be: CPU 0 holds lock A. CPU 1 holds lock B. CPU 2 attempts lock B, becomes the pending waiter for B. CPU 0 attempts lock B. B has locked+pending bits set, thus CPU 0 queues. CPU 1 attempts lock A. CPU 0 detects an ABBA deadlock. Once deadlock detection happens for CPU 0, it will sit waiting for the next waiter in the queue to populate node->next, which will experience delays until such a waiter arrives. Fix this by adjusting the logic for the check for deadlocks preceding the waitq_timeout label. It would make sense to consolidate code for both cases and use 'ret' to distinguish the value being propagated, but that is left as an exercise for a future refactoring task to avoid diff noise in this patch. The Linux kernel CVE team has assigned CVE-2026-74686 to this issue. Affected and fixed versions =========================== Issue introduced in 6.19 with commit 7bd6e5ce5be666fb3fb873bf20f77e62555b7835 and fixed in 7.1.9 with commit f54667b0c16213285c9d9b8e3929f738b8f71826 Issue introduced in 6.19 with commit 7bd6e5ce5be666fb3fb873bf20f77e62555b7835 and fixed in 7.2 with commit 7a3c0289c3c8eb4607dff448ae9ff9f902c813af Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-74686 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: kernel/bpf/rqspinlock.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/f54667b0c16213285c9d9b8e3929f738b8f71826 https://git.kernel.org/stable/c/7a3c0289c3c8eb4607dff448ae9ff9f902c813af