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=1796388910; b=E7NGK9DTGINoAODOdw+wuOC+maHl4EBHnaYKyWEEJ95mepaZ2OzhSIedPkcAtKqmAil9 LW0SYPtbXzi5XCSLzMhVHKjziVEtCvtkFriXJvZkWHyXCBTZELtZ3YTGhAQyoT2YABtJY 9g44Lucf5vMjny7H4iypwW0tm9ptVc1M1AVZ5AKkiSGn0GXg3nvKNPyUTKdG2RriuolHN EmD/mHXj/Sr9aCDGc8v30EgYbSYa3XHcC2xhPYNw68qyY1VhWX1nkGf0Im+J8/Ahwba4N /X+mGqR6COg3fny+fODdrULyxC7VlfbzVQmLUaxacU0KYrQCyt8X1ZI9d+Z2661ejYQ== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796388910; 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=8xzJ/pWAyCqHOnAm8tI7HoC8HfMbePZRy99oe9V16mg=; b=Dj9DNlpZvZmZwJ8xsqaW6LkVnacEyv9Fc08vObtaOcEP2RlfqUjWIT/mMsFt6wrsY/OD Yo1VBjUjonWzTci7UHjv4k3XwefYOU9uH0lgUt624hi5a/H6fnwLqJm+t0fAhE4cUgZwP 6KxT+5BPjgcUAOC25dt56UlYZot70143VWdJlkHeYX1oiHcWxekWn4XwlqGZ96XSTgmRW vAxUHPtaNWsbq7RhMN3RSUvaJYQMe93t7q0Gp+0XgTRZjbyGI4o1XaAOjxCapB+EpIr5g gutDOqY91UC+hwfIfn+DNUqu1zu2bAuMWh9s9IACDhW+8NHWDoj7hwszroxOo4Zkpag== 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=1phwfMXk; 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 7F3B4606A332; Fri, 4 Dec 2026 12:55:10 +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=1phwfMXk Received: by smtp.kernel.org (Postfix) with ESMTPSA id D621C1F0093A; Fri, 4 Dec 2026 12:55:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796388910; bh=8xzJ/pWAyCqHOnAm8tI7HoC8HfMbePZRy99oe9V16mg=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=1phwfMXkiCi/7IkH5bv6pPLfJfULm/iPjaaS75L5Ws0qzNe5KhBOzuElX5Tby57Yy OdqANSIt0JFjLUozjXHzQ7S9iHRlieX9aDTcyk1dW64nuJOONBjX+LLsf0/w28fqjH Ey2Oiv3Qxg4z6fwdxro3Xwbbn2WOtsxgTPZ/P2rU= 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 6.1 0795/1059] Bluetooth: mgmt: Reject zero multi advertising rotation duration Date: Fri, 4 Dec 2026 19:05:26 +0900 Message-ID: <20261204100704.624297713@linuxfoundation.org> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261204100643.980430235@linuxfoundation.org> References: <20261204100643.980430235@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 6.1-stable review patch. If anyone has any objections, please let me know. ------------------ From: Luiz Augusto von Dentz [ Upstream commit 4e0dc0523bd98adbd45ce1c66dd1a96d4f6a3ec9 ] A zero def_multi_adv_rotation_duration makes hci_schedule_adv_instance_sync() requeue itself with no delay, spinning the request workqueue. Reject it in Set Default System Configuration. Reported-by: Sashiko Link: https://sashiko.dev/#/bug/linux-24ecb695-0c5c-408a-a016-a980c3115e95 Fixes: 17896406ff35 ("Bluetooth: implement read/set default system parameters mgmt") Assisted-by: OpenCode:claude-fable-5.2 Signed-off-by: Luiz Augusto von Dentz Signed-off-by: Sasha Levin --- net/bluetooth/mgmt_config.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/net/bluetooth/mgmt_config.c b/net/bluetooth/mgmt_config.c index 6ef701c27da48..3b1593f35f25f 100644 --- a/net/bluetooth/mgmt_config.c +++ b/net/bluetooth/mgmt_config.c @@ -206,6 +206,14 @@ int set_def_system_config(struct sock *sk, struct hci_dev *hdev, void *data, MGMT_STATUS_INVALID_PARAMS); } + /* A zero rotation duration would make the advertising instance + * scheduler requeue itself with no delay. + */ + if (type == 0x000c && !TLV_GET_LE16(buffer)) + return mgmt_cmd_status(sk, hdev->id, + MGMT_OP_SET_DEF_SYSTEM_CONFIG, + MGMT_STATUS_INVALID_PARAMS); + buffer_left -= exp_len; buffer += exp_len; } -- 2.53.0