Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp1259805ybl; Fri, 23 Aug 2019 16:23:47 -0700 (PDT) X-Google-Smtp-Source: APXvYqyvgQUFe5A1RYdEgwqAipKuH3I5W+er68NT08D4p9fEZiBZCgRN0l7BEJe0ipWtEv6uYZZ7 X-Received: by 2002:a17:902:f217:: with SMTP id gn23mr7408842plb.21.1566602626997; Fri, 23 Aug 2019 16:23:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1566602626; cv=none; d=google.com; s=arc-20160816; b=Ag57ZcLeX/D+yKQNfl4TGtbPx/QVmKOfPNQli+zDl1YHJl/SWiMzy7pJ5/A1KF2Vh6 bvTqsjVZVGj0YX5lde3mXwmgggPfWHbm1rnIcNu32vGQTvYS+r0k/sGOk+k8IJXStZow B9MPQUi5IhEVPG28o0o5FASMycAUqJbwt1U8hB9lq2UJ6C6X/Y3GBOgrQ2NTUEiZNxtW ssozzwxMr4JT+0XPIitgPRHjKzq2kh6Xk5mWdA7x5BWowZFXcc5m6oR9yG+pEKstM/ej WJPAPOSgi9qBy/UxGaNapGjd1id2PkHkR8SF2K8xj2oYBljug8l0M0GpjDiPDF5ev7Q9 QUMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=HPIzUD59/XZrVzmZOsT4wg/CjbkQ6dTDP4VDgkOL5j0=; b=usxQd8Kh73wT4b3JC3QZWXV8vGMe/kgz1k+0wlbsE0GM8rFUZdlkYVPLNTF3A9Ihxr uvgob6M3uXoCjpHHJj7us/ioTQD7kBKYGxhD8p/aoW8VkyLMK0ZhjjxMu4agHHRPs53i LDeLBMgirykLNbAiL0CG9vIEA472BihB5Ovu+dpExBXcMfo8q31BDMukVilW/iY3/WvR EeP/I0aBN2Kvtl1i4f5P8h1NlpwH600rpUUkRd7BjHAd/yOFlMe0sqJreHBJxd7cCJf+ 5yJnKU7HueqXc+bhOcReoVn90IAREkkT2FbhS5wy/Hw/lnqHmMfWRQuUtbQqP7ufQM0U aWhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@kemnade.info header.s=20180802 header.b=DQm5dXvt; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z11si3891617pfa.221.2019.08.23.16.23.24; Fri, 23 Aug 2019 16:23:46 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@kemnade.info header.s=20180802 header.b=DQm5dXvt; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2405680AbfHWNqF (ORCPT + 99 others); Fri, 23 Aug 2019 09:46:05 -0400 Received: from mail.andi.de1.cc ([85.214.55.253]:47268 "EHLO mail.andi.de1.cc" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2405715AbfHWNqD (ORCPT ); Fri, 23 Aug 2019 09:46:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=kemnade.info; s=20180802; h=Content-Transfer-Encoding:Content-Type: MIME-Version:References:In-Reply-To:Message-ID:Subject:Cc:To:From:Date:Sender :Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=HPIzUD59/XZrVzmZOsT4wg/CjbkQ6dTDP4VDgkOL5j0=; b=DQm5dXvtl9kX3mWWmltvM7iMmf T1e1eG+LOUGUMAXCqgUI7VI3aO4m5P+SIMvqMU0elGkkvceKZ3PsmuxneUSH0ZkC8xcXVVxUyNJVz zep2t0wkt8rXPqGXgWqbxyQ9dsl5iiVwJFaJKafgt9hg12JOZxZREXbAB2SMMBZQS1AM=; Received: from p200300ccff081c001a3da2fffebfd33a.dip0.t-ipconnect.de ([2003:cc:ff08:1c00:1a3d:a2ff:febf:d33a] helo=aktux) by mail.andi.de1.cc with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1i19tA-0005c0-M1; Fri, 23 Aug 2019 15:46:00 +0200 Date: Fri, 23 Aug 2019 15:45:59 +0200 From: Andreas Kemnade To: Carey Sonsino Cc: Marcel Holtmann , Johan Hedberg , Jamie Mccrae , "linux-bluetooth@vger.kernel.org" Subject: Re: [PATCH 1/1] bluetooth: update default BLE connection interval bounds Message-ID: <20190823154559.1f203fac@aktux> In-Reply-To: <1c707bb9-999b-7ca3-3c91-7b183dacfdd5@gmail.com> References: <1c707bb9-999b-7ca3-3c91-7b183dacfdd5@gmail.com> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -1.0 (-) Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Hi, On Tue, 20 Aug 2019 11:01:41 -0600 Carey Sonsino wrote: > Update the default BLE connection interval min/max bounds to the full=20 > range of permitted values (6-3200, corresponding to 7.25-4000ms). >=20 > Commit c49a8682fc5d298d44e8d911f4fa14690ea9485e introduced a bounds=20 > check on connection interval update requests, but the default min/max=20 > values were left at 24-40 (30-50ms) which caused problems for devices=20 > that want to negotiate connection intervals outside of those bounds. >=20 > Setting the default min/max connection interval to the full allowable=20 > range in the bluetooth specification restores the default Linux behavior= =20 > of allowing remote devices to negotiate their desired connection=20 > interval, while still permitting the system administrator to later=20 > narrow the range. >=20 > Fixes c49a8682fc5d: (validate BLE connection interval updates) >=20 Trying pair XX:XX:XX:XX:XX:XX in bluetoothctl=20 leads to create connection commands containing le_conn_max_interval > le_supv_timeout (4000ms > 420ms) which the controller does not like and is imho not allowed. < HCI Command: LE Create Connection (0x08|0x000d) plen 25 bdaddr XX:XX:XX:XX:XX:XX type 0 interval 96 window 96 initiator_filter 0 own_bdaddr_type 0 min_interval 6 max_interval 3200 latency 0 supervision_to 42 min_ce 0 max_ce 0 > HCI Event: Command Status (0x0f) plen 4 LE Create Connection (0x08|0x000d) status 0x12 ncmd 1 Error: Invalid HCI Command Parameters > Signed-off-by: Carey Sonsino >=20 > --- >=20 > diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c > index 04bc79359a17..f4f2f712c527 100644 > --- a/net/bluetooth/hci_core.c > +++ b/net/bluetooth/hci_core.c > @@ -3181,8 +3181,8 @@ struct hci_dev *hci_alloc_dev(void) > =C2=A0=C2=A0=C2=A0=C2=A0 hdev->le_adv_max_interval =3D 0x0800; > =C2=A0=C2=A0=C2=A0=C2=A0 hdev->le_scan_interval =3D 0x0060; > =C2=A0=C2=A0=C2=A0=C2=A0 hdev->le_scan_window =3D 0x0030; > -=C2=A0=C2=A0=C2=A0 hdev->le_conn_min_interval =3D 0x0018; > -=C2=A0=C2=A0=C2=A0 hdev->le_conn_max_interval =3D 0x0028; > +=C2=A0=C2=A0=C2=A0 hdev->le_conn_min_interval =3D 0x0006; > +=C2=A0=C2=A0=C2=A0 hdev->le_conn_max_interval =3D 0x0c80; > =C2=A0=C2=A0=C2=A0=C2=A0 hdev->le_conn_latency =3D 0x0000; > =C2=A0=C2=A0=C2=A0=C2=A0 hdev->le_supv_timeout =3D 0x002a; > =C2=A0=C2=A0=C2=A0=C2=A0 hdev->le_def_tx_len =3D 0x001b; hmm, what happened with the tabs here? I needed to manually apply it. Regards, Andreas