Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 01EE43191AF for ; Wed, 24 Dec 2025 10:57:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1766573871; cv=none; b=mftEWk/L91WY5nzJ8jetivbk0ZMVFKsXwYY7zE+Y7ki2arwN+1kUf8kCyUByewgdaVDhMR9mmgb+pzjAnEHz9ctiaLnSez0b72G9f6SEF8QE/xm76xVMV0x2qWQnfjGJY+WPKGYrmFk55YjLbh0c27OHPIphc2G34k/5PEv4Yws= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1766573871; c=relaxed/simple; bh=rJP6jG6YP9Mg7DRda0WTQGpqSKFz+E1iBirxx2f33Rs=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=GOQ2SisPZrd5NfMlnhynsTBclXZnMzrqapuoq9n2fgmHnLdCvv7EdhV45kNQ6s/lJhvgSpV+Siij7s7QNfeJRpP8pYDuVIGIhYq9lTqIZ5KN5P5TFq6OuaTRmmKbTiWzdbgH+lkQAydxKCKesC4iqB9s2WtkaTzd5OVV0a2UUCw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=ezSnHXjx; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="ezSnHXjx" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 099CBC4CEFB; Wed, 24 Dec 2025 10:57:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1766573869; bh=rJP6jG6YP9Mg7DRda0WTQGpqSKFz+E1iBirxx2f33Rs=; h=From:To:Cc:Subject:Date:Reply-To:From; b=ezSnHXjxx376XMRtI3HhSEFvgQhPPKtijBEnIifxBSM9lK6YbDPVGCpvwkzNREdUu k5ddDlQJZ7ixxr4Vz5hXHKtLeLZIxcAuu0c2uwzgdjyJKliK/QDE8wboeyEUa75Ao7 0Gspgtg/7Srx2GqynCaTcwGK05cZyU9YufXTeVcY= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2023-54000: net: hns3: fix deadlock issue when externel_lb and reset are executed together Date: Wed, 24 Dec 2025 11:56:44 +0100 Message-ID: <2025122426-CVE-2023-54000-b0c0@gregkh> X-Mailer: git-send-email 2.52.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=3737; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=yEk3hJJCzys4LZnX0I6GnXVeQEwfIh04b66gh6Rp98g=; b=owGbwMvMwCRo6H6F97bub03G02pJDJnex27Hv7JZ/eZLxOMF5i1tWnudOC5E31407/ArzpZ9L 7YeW2zzoyOWhUGQiUFWTJHlyzaeo/srDil6GdqehpnDygQyhIGLUwAm4h3BME+Bw0AmnS9jYvWR 2Yv5XW2Vuh17tjMs6Ip+/WvBpYeZXm/elJX9+Xv33kad8wA= 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: net: hns3: fix deadlock issue when externel_lb and reset are executed together When externel_lb and reset are executed together, a deadlock may occur: [ 3147.217009] INFO: task kworker/u321:0:7 blocked for more than 120 seconds. [ 3147.230483] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. [ 3147.238999] task:kworker/u321:0 state:D stack: 0 pid: 7 ppid: 2 flags:0x00000008 [ 3147.248045] Workqueue: hclge hclge_service_task [hclge] [ 3147.253957] Call trace: [ 3147.257093] __switch_to+0x7c/0xbc [ 3147.261183] __schedule+0x338/0x6f0 [ 3147.265357] schedule+0x50/0xe0 [ 3147.269185] schedule_preempt_disabled+0x18/0x24 [ 3147.274488] __mutex_lock.constprop.0+0x1d4/0x5dc [ 3147.279880] __mutex_lock_slowpath+0x1c/0x30 [ 3147.284839] mutex_lock+0x50/0x60 [ 3147.288841] rtnl_lock+0x20/0x2c [ 3147.292759] hclge_reset_prepare+0x68/0x90 [hclge] [ 3147.298239] hclge_reset_subtask+0x88/0xe0 [hclge] [ 3147.303718] hclge_reset_service_task+0x84/0x120 [hclge] [ 3147.309718] hclge_service_task+0x2c/0x70 [hclge] [ 3147.315109] process_one_work+0x1d0/0x490 [ 3147.319805] worker_thread+0x158/0x3d0 [ 3147.324240] kthread+0x108/0x13c [ 3147.328154] ret_from_fork+0x10/0x18 In externel_lb process, the hns3 driver call napi_disable() first, then the reset happen, then the restore process of the externel_lb will fail, and will not call napi_enable(). When doing externel_lb again, napi_disable() will be double call, cause a deadlock of rtnl_lock(). This patch use the HNS3_NIC_STATE_DOWN state to protect the calling of napi_disable() and napi_enable() in externel_lb process, just as the usage in ndo_stop() and ndo_start(). The Linux kernel CVE team has assigned CVE-2023-54000 to this issue. Affected and fixed versions =========================== Issue introduced in 6.1 with commit 04b6ba143521f4485b7f2c36c655b262a79dae97 and fixed in 6.1.46 with commit 743f7c1762e098048ede8cdf8c89a118f8d12391 Issue introduced in 6.1 with commit 04b6ba143521f4485b7f2c36c655b262a79dae97 and fixed in 6.4.11 with commit ef2d6bf9695669d31ece9f2ef39dec84874a87c7 Issue introduced in 6.1 with commit 04b6ba143521f4485b7f2c36c655b262a79dae97 and fixed in 6.5 with commit ac6257a3ae5db5193b1f19c268e4f72d274ddb88 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-2023-54000 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: drivers/net/ethernet/hisilicon/hns3/hns3_enet.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/d9f609cb50ebab4aa6341112f406bf9d3928ac81 https://git.kernel.org/stable/c/743f7c1762e098048ede8cdf8c89a118f8d12391 https://git.kernel.org/stable/c/ef2d6bf9695669d31ece9f2ef39dec84874a87c7 https://git.kernel.org/stable/c/ac6257a3ae5db5193b1f19c268e4f72d274ddb88