Received: by 2002:a05:7412:98c1:b0:fa:551:50a7 with SMTP id kc1csp1803876rdb; Mon, 8 Jan 2024 10:40:04 -0800 (PST) X-Google-Smtp-Source: AGHT+IFHCjBraYZtdARp1e1G736bOfZ/mYcRaWfBmOqXHXyE4rcNSMNV+NDnDKZ9e/LuR6FdnfuG X-Received: by 2002:a2e:be08:0:b0:2cd:5519:35e2 with SMTP id z8-20020a2ebe08000000b002cd551935e2mr960390ljq.5.1704739204121; Mon, 08 Jan 2024 10:40:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704739204; cv=none; d=google.com; s=arc-20160816; b=q/rkXsI1j4RDggnpyAd+5woYc87e674fYlLEYaIopWjbKMZbBZ6NWibC8mE0AWBRKi tqVBBFsdGVcSXXk0jUXCUCJlGMjRrC7SP4P7iZroMPD2zqx6XS3dy2X4Y3hsBmSeBKSf 1UrcnAok6M0aQab8czcqcx4Np6mPZOMo+cGLoaGTXWhPwXFi8O9k0yriOzWbEE0tOtj9 gU5Q2Gbk9qnK1t6z9o6vx4RPtLa7zsyTymRsQ5Bi1VX6h7I+barsc4QF1pt+Um6cxZt2 GFlxOc4j7p8IHrsnG0LNuVsxlprCe/f/qwmEjGBqo9bQLxCesI6+z6u4hRPHbbtOYZQt joXg== 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=SMK/wSd6d/Jmc+GAE8QusKMi/OIZjE6aD2/POvitZgM=; fh=3AqDzvZy8BuFcn015+g5AB3sGQnZc/edyFwniXfpO+U=; b=Jvux0FyJfGkN4UckFyXtKtyl7QqA4yH50Node4qUlM8XJRoUtux0+qgr8E8qxti21V rCdAE3LCZalYgR0/DBLwmZpQX/PIV3wZbZZi33Zv/IGFVRGIIRJIl+Vw1o7hXpwZqXcS izESKergQHj86ERILXYMClJYC6li1S7E3rPyayEQC5fRKAIyECZSZHKibtZ+nHmYcTEi 5nj9lg/R2b4xKkz5IixvHfVPuiDq6qRxpXzmnXPrm3yX9nPek5uSNLt0u8NV+ODwqAeD I/Ugj+nSrlOSGVfBD2EIQK81tfhRIYaGXiSAA66uO5jQaHq7JhShVC5NbfmPnFN4ShlM NPKw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-19980-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-19980-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id y6-20020a056402440600b0054cfd045e4esi96062eda.363.2024.01.08.10.40.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 10:40:04 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-19980-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-19980-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-19980-linux.lists.archive=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 am.mirrors.kernel.org (Postfix) with ESMTPS id D52F51F23C65 for ; Mon, 8 Jan 2024 18:40:03 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id F375B54F94; Mon, 8 Jan 2024 18:39:50 +0000 (UTC) X-Original-To: linux-kernel@vger.kernel.org Received: from mout-p-101.mailbox.org (mout-p-101.mailbox.org [80.241.56.151]) (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 5CB0D54F83; Mon, 8 Jan 2024 18:39:46 +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 smtp202.mailbox.org (smtp202.mailbox.org [10.196.197.202]) (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-101.mailbox.org (Postfix) with ESMTPS id 4T82sq1N58z9sch; Mon, 8 Jan 2024 19:39:43 +0100 (CET) From: =?UTF-8?q?Jonas=20Dre=C3=9Fler?= To: Marcel Holtmann , Johan Hedberg , Luiz Augusto von Dentz Cc: =?UTF-8?q?Jonas=20Dre=C3=9Fler?= , linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org Subject: [PATCH v2 0/4] Bluetooth: Improve retrying of connection attempts Date: Mon, 8 Jan 2024 19:39:32 +0100 Message-ID: <20240108183938.468426-1-verdre@v0yd.nl> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since commit 4c67bc74f016 ("[Bluetooth] Support concurrent connect requests"), 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 refactores the handling of concurrent connection requests by serializing all "Create Connection" commands for ACL connections similar to how we do it for LE connections. --- v1: https://lore.kernel.org/linux-bluetooth/20240102185933.64179-1-verdre@v0yd.nl/ v2: - Move to using hci_sync queue for "Create Connection" and therefore always serialize those requests. - Follow commit message style better and properly cite patches Jonas Dreßler (4): Bluetooth: Remove superfluous call to hci_conn_check_pending() Bluetooth: hci_event: Use HCI error defines instead of magic values Bluetooth: hci_conn: Only do ACL connections sequentially Bluetooth: Remove pending ACL connection attempts include/net/bluetooth/hci.h | 3 ++ include/net/bluetooth/hci_core.h | 1 - net/bluetooth/hci_conn.c | 51 ++++++++++++++++---------------- net/bluetooth/hci_event.c | 29 +++++------------- 4 files changed, 35 insertions(+), 49 deletions(-) -- 2.43.0