From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796380125; b=sgt7dgl0SPD7nOhI8TXdUtG6B7nFQcK/cV94mf44OqKRIVA/zi4+elR9dvgHK3QIh9wW AunuZOCQE/1CW4zlH7vgF9ICCfScD5+po7OG9HdHHSIcm8Hut5FJ6OW0KJX9g33D8FT02 eKQLELQ/PwkMuy2Kh7Jr4cYDJhGPFNRpIxggAQ4E7zwyRIo9M0ihgdaHwcXOkVXOWyYrN fSW790t6oDPYFR02eIVkWL0ekta19zT0xZeNP0T7OrTyX1bV1l1fRjUEXVEdhkvoqHwD4 lqRQ2PNoUpZvQnPatdpbbFcV3XN4Rsaha718OaP0uI6s7184uMdecha+VapLu6TVKFA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796380125; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: In-Reply-To:References:User-Agent:X-stable:X-Patchwork-Hint: MIME-Version:Content-Transfer-Encoding; bh=P90urV5ly+o6QUxL6dR47nfGi2ZwnPQlZZbPqV6pSdM=; b=S5JdYGhPIMmZC0xaIe4DYHbAjgxWmnEOtgvDaYbvz87/CrKm++OgICEVunSrZmHJbG34 GVZQIvu05bjL44ISFxLM6+q7v/dkiiV2G5ly1PLOYqlcRBDV0jMg71fnSTvu680oC+aL3 q029CdJBca5vSxR2ujZved1B0p6rLwaTBwxAptBrfvQjZB297vXF/jDECxoeXRVAOn2DE OgPYrfFtkhA9OvMk+WqRLOFV/RIkdqzZfPlEwK7cFJjvWJ0VMVGHzVMg282Kotp7rVxhG E3l3uQTstZvPCiQ6N+Svb9/XoECQH6IkAHXRPv/7lHEMkffyzX39wafDGChy7Ao7H4w== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=bpVRdmXE; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 79F03606A32C; Fri, 4 Dec 2026 10:28:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=bpVRdmXE Received: by smtp.kernel.org (Postfix) with ESMTPSA id E61C41F000C2; Fri, 4 Dec 2026 10:28:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796380125; bh=P90urV5ly+o6QUxL6dR47nfGi2ZwnPQlZZbPqV6pSdM=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=bpVRdmXEGa9/K+7F6BkuVqib2EHyNYhRRlrM2LHH5+9jA5INRbQHAm2ljXBF9Goc4 5Xkgx+J7FJ6MkGZRkL+0tpbbZT1WzYlXPjo0bu16Q/2UVLTyEHXJwe6ttJiIraam2O VhDu5fvNQTEk9Tm4a6VpM/xudrvspXXq+Un3PUjo= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Sashiko , Luiz Augusto von Dentz , Sasha Levin Subject: [PATCH 7.3 096/742] Bluetooth: hci_core: Take req_sync lock in hci_power_on() Date: Fri, 4 Dec 2026 18:59:20 +0900 Message-ID: <20261204100637.657156884@linuxfoundation.org> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261204100635.034361255@linuxfoundation.org> References: <20261204100635.034361255@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore X-Mailing-List: stable@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 7.3-stable review patch. If anyone has any objections, please let me know. ------------------ From: Luiz Augusto von Dentz [ Upstream commit 6a296a4658124490d7dddd2b751e5f9ae5c5aec7 ] hci_powered_update_sync() issues synchronous HCI commands but was called without hci_req_sync_lock(), racing with other request users. Reported-by: Sashiko Link: https://sashiko.dev/#/bug/linux-1baf7393-3aeb-4fa5-806f-19cea743b9f3 Fixes: cf75ad8b41d2 ("Bluetooth: hci_sync: Convert MGMT_SET_POWERED") Assisted-by: OpenCode:claude-fable-5.2 Signed-off-by: Luiz Augusto von Dentz Signed-off-by: Sasha Levin --- net/bluetooth/hci_core.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c index 8784c28297ac2..6433c388050fa 100644 --- a/net/bluetooth/hci_core.c +++ b/net/bluetooth/hci_core.c @@ -915,7 +915,9 @@ static void hci_power_on(struct work_struct *work) hci_dev_test_flag(hdev, HCI_MGMT) && hci_dev_test_and_clear_flag(hdev, HCI_AUTO_OFF)) { cancel_delayed_work(&hdev->power_off); + hci_req_sync_lock(hdev); err = hci_powered_update_sync(hdev); + hci_req_sync_unlock(hdev); mgmt_power_on(hdev, err); return; } -- 2.53.0