Message ID | 20240102185933.64179-1-verdre@v0yd.nl |
---|---|
Headers |
Return-Path: <linux-kernel+bounces-14750-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:6f82:b0:100:9c79:88ff with SMTP id tb2csp4629214dyb; Tue, 2 Jan 2024 11:00:05 -0800 (PST) X-Google-Smtp-Source: AGHT+IHNG/D3+8st4BKz8AcjcU9wYORh7fiCKIJeY1pBiJC7qRCOF/3P1l4IHqXQfWRpyfkX5kOh X-Received: by 2002:a05:6808:2385:b0:3bc:22f5:a3e9 with SMTP id bp5-20020a056808238500b003bc22f5a3e9mr208194oib.78.1704222005068; Tue, 02 Jan 2024 11:00:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704222005; cv=none; d=google.com; s=arc-20160816; b=K8APk8igfv+hlsbkswtiJMNB+7I0SlVKPFgL+Xd/d5/ZGBXv+C1RuigVpYsGkO2sr4 0JyeeBhaTqnH8mH+D48/m3POWPGMQ9A+WLr0hiLDMF7zHvLbavV72zarCS/xNwTidLfx LUPK8pRcoUgJ6GbfX3Hz1AmqYkJYDis+7kbcGohx2707j2lsEaoJfssuXDDav4tCyCSg HSgqPFEmvHfpUmL/EH2epj7PqmYymlPrW624Zlil6Q5gDPWRgrMtTcWbFxRcXtWSpzd/ NTkO0zUheehdYK04Z7IhpOukPEYh/18ubcZc5KHVB2kEBdw7YefKFSYg7KjvPl4Gh8Sv Ss6Q== ARC-Message-Signature: i=1; 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:message-id:date:subject:cc:to :from; bh=CtSlQbl/HHG32tCEDl7RTc4AYBfU5eoD2U3oKTYQXM0=; fh=3AqDzvZy8BuFcn015+g5AB3sGQnZc/edyFwniXfpO+U=; b=jxTeSZWcdH+UJhtM62zAYFU+ghMO8k5ZLTB+CydyakaVRJcEmkfVXZoyCLRKvUjBSu k4dW8qrpFeATqLG/gKc58ETfuwBhdCsbGGS76KTR6FYIJ0s6PEhcoFaqEEsmngjy60+C 1g8oR0AkfVD0GdgAdQ9jnCbAFuGqyJ5vdYVO8xCjmsmNgrUuZ15zvCubKVu4jbS0IqcY HKgNfcowzxy2Lzm6N4HHLnOTcnDBMQqviak4fKZIWbu443oAn8KTrVLe200nvndnn6J1 gV14YLyU9V6I9+6c1G/rRjGgNedeqj/ioyeXP0tZvv4GrkpgzQim6F4E5IZwo/IBDdNH wTyQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-14750-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-14750-ouuuleilei=gmail.com@vger.kernel.org" Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id y17-20020a0cd991000000b0067f86df1ed8si27116787qvj.238.2024.01.02.11.00.04 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 Jan 2024 11:00:05 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-14750-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-14750-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-14750-ouuuleilei=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 ny.mirrors.kernel.org (Postfix) with ESMTPS id D0B6E1C214E4 for <ouuuleilei@gmail.com>; Tue, 2 Jan 2024 19:00:04 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2E09515E9F; Tue, 2 Jan 2024 18:59:43 +0000 (UTC) X-Original-To: linux-kernel@vger.kernel.org Received: from mout-p-201.mailbox.org (mout-p-201.mailbox.org [80.241.56.171]) (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 A7F0D15AC7; Tue, 2 Jan 2024 18:59:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=v0yd.nl Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=v0yd.nl Received: from smtp1.mailbox.org (smtp1.mailbox.org [IPv6:2001:67c:2050:b231:465::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-201.mailbox.org (Postfix) with ESMTPS id 4T4MbW62Cxz9smm; Tue, 2 Jan 2024 19:59:35 +0100 (CET) From: =?utf-8?q?Jonas_Dre=C3=9Fler?= <verdre@v0yd.nl> To: Marcel Holtmann <marcel@holtmann.org>, Johan Hedberg <johan.hedberg@gmail.com>, Luiz Augusto von Dentz <luiz.dentz@gmail.com> Cc: =?utf-8?q?Jonas_Dre=C3=9Fler?= <verdre@v0yd.nl>, linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org Subject: [PATCH 0/5] Bluetooth: Improve retrying of connection attempts Date: Tue, 2 Jan 2024 19:59:27 +0100 Message-ID: <20240102185933.64179-1-verdre@v0yd.nl> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 4T4MbW62Cxz9smm X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1787006292936724683 X-GMAIL-MSGID: 1787006292936724683 |
Series |
Bluetooth: Improve retrying of connection attempts
|
|
Message
Jonas Dreßler
Jan. 2, 2024, 6:59 p.m. UTC
Since commit 4c67bc74f016b0d360b8573e18969c0ff7926974, the kernel supports trying to connect again in case the bluetooth card is busy and fails to connect. The logic that should handle this became a bit spotty over time, and also cards these days appear to fail with more errors than just "Command Disallowed". This series tries to improve the logic for retrying "HCI Create Connection" and adds support for two more errors that can indicate the hardware being busy. Jonas Dreßler (5): Bluetooth: Remove superfluous call to hci_conn_check_pending() Bluetooth: hci_event: Use HCI error defines instead of magic values Bluetooth: hci_event: Remove limit of 2 reconnection attempts Bluetooth: hci_event: Do sanity checks before retrying to connect Bluetooth: hci_event: Try reconnecting on more kinds of errors include/net/bluetooth/hci.h | 3 ++ net/bluetooth/hci_event.c | 57 +++++++++++++++++++++++++++++++------ 2 files changed, 51 insertions(+), 9 deletions(-)