Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp3589388iog; Tue, 21 Jun 2022 01:43:55 -0700 (PDT) X-Google-Smtp-Source: AGRyM1vXp+SY0Uf1JWGCqO+JT3nHCvEjpZkSCGkZ6Sppog3b4CMeQ6HjOZoDn6QUT9YJbV/P6oo9 X-Received: by 2002:a05:6402:51c7:b0:42d:f4ea:c09 with SMTP id r7-20020a05640251c700b0042df4ea0c09mr33492974edd.319.1655801035055; Tue, 21 Jun 2022 01:43:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655801035; cv=none; d=google.com; s=arc-20160816; b=kVuJiZpZFd8TsrTLv9yEpw4Si9BFeyuVm1Mr25DmaoQhjQJ2vH58maiQ4CdvjCBt7a WAcqSbG21eNglMcIy1MGPQJkStX3FGfzhZJX//uXFpVS8OshAKdEwO8W3HLkzccThB4R eozhLiUWCbyKmLYCG8kQyGBraI2wHscGQyYi1qYLUnwdEGnv8MWuBWdJAFtgmzwp5uwY aTCeTh8sa1uIu121tyrcL4C80QhHv8xOArrVB1RongRjHqKFZ7QLLbLy8xeyg+57a54/ TcI1ZRaNzNZ0xx68HaS9QpqhRXu/c36yYilVnIbbrplwIwIqs7jawDLEQubi4R6tx4VO WAlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id; bh=BJvpBRVUBp/IFC0mXpadGDEfJWDznb9jI2WogAq3QW0=; b=Nj9yjCIQpXQD1w4Us/lLCadcZOBxF1mF0SQOoeZs0zMXmqeGkRcl+LgUGstS4T/Se0 RJamwmbSmb/+PodMT62DT4CRO1NWmGpz8/nt1dTBqh7tzwgd5stAZVzlz5liXnRPiq6E SevhwONGyGr2O9Lex1i/jyavQHNtY8T2lfEERJ1Nn+5rKe/xPcEHd+tCwealY7f3ollF IBHJDdkIrUG0J98YvVMdH0jmOBXxW9TYROp9xkXDd7g6T4/MuB1MVxNKPYENGFuBzvXi xgLTTfwDvxIUXSdOK6K3dT8DupYolEXQBXk86Xzo030pHGw5kC/h8dJ1z+pnkW8h7/jY 74gQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g21-20020a1709065d1500b006febc5db63bsi15981025ejt.888.2022.06.21.01.43.16; Tue, 21 Jun 2022 01:43:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230181AbiFUIcJ (ORCPT + 99 others); Tue, 21 Jun 2022 04:32:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48982 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346183AbiFUIcJ (ORCPT ); Tue, 21 Jun 2022 04:32:09 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 707D21573A for ; Tue, 21 Jun 2022 01:32:08 -0700 (PDT) Received: from ptz.office.stw.pengutronix.de ([2a0a:edc0:0:900:1d::77] helo=[127.0.0.1]) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1o3ZIs-00019W-LJ; Tue, 21 Jun 2022 10:32:06 +0200 Message-ID: <1d1b76cf-df6f-3935-5cd2-c45ea78f2c33@pengutronix.de> Date: Tue, 21 Jun 2022 10:32:04 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.0 Subject: Re: [BUG] BLE device unpairing triggers kernel panic Content-Language: en-US To: Luiz Augusto von Dentz Cc: "linux-bluetooth@vger.kernel.org" , Marcel Holtmann , "regressions@lists.linux.dev" , Pengutronix Kernel Team References: <8d5c4724-d511-39b1-21d7-116c91cada45@pengutronix.de> From: Ahmad Fatoum In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-SA-Exim-Connect-IP: 2a0a:edc0:0:900:1d::77 X-SA-Exim-Mail-From: a.fatoum@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-bluetooth@vger.kernel.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Hello Luiz, On 20.06.22 22:18, Luiz Augusto von Dentz wrote: > On Mon, Jun 20, 2022 at 3:06 AM Ahmad Fatoum wrote: >> Disconnect of connection #1 being processed after new connection #2 >> concluded sounds wrong. Would I be able to reconnect >> afterwards or would all connections, but the first, be directly >> disconnected...? > > That depends on the order you have queued the commands, it will be > processed in the exact order it is received, that why I said it is > single queue design, and it is done like that to prevent messing up > with states since we know the exact order the commands will be sent. > >>> otherwise we need a >>> different queue to handle command that abort/cancel other already in >>> the queue. >> >> Is the revert an acceptable interim solution or are there issues >> I am missing? > > Afaik there were problem with concurrent connections request, so what > would really help us here is to have some tests to emulate this > scenario with our CI, in the meantime please check if the following > fixes your problem: > > https://gist.github.com/Vudentz/b4fff292c7f4ad55ca3299fd5ab797ae Doesn't help unfortunately. First pairing works as before. Second still fails: Bluetooth: hci0: Opcode 0x200d failed: -110 Bluetooth: hci0: request failed to create LE connection: err -110 Cheers, Ahmad > >> Cheers, >> Ahmad >> >>> >>>> We've been deploying the revert for a while now and I just posted >>>> it to the mailing list[1]. There have been other reports >>>> of this issue with different hardware too and fixing sent_cmd >>>> would likely be too complicated/time intensive for me. >>>> >>>> I am happy to test future patches that fix this properly though. >>>> >>>> [1]: https://lore.kernel.org/linux-bluetooth/20220616092418.738877-1-a.fatoum@pengutronix.de/T/#t >>>> >>>> Cheers, >>>> Ahmad >>>> >>>> >>>> >>>>> >>>>> Cheers, >>>>> Ahmad >>>>> >>>> >>>> >>>> -- >>>> Pengutronix e.K. | | >>>> Steuerwalder Str. 21 | http://www.pengutronix.de/ | >>>> 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | >>>> Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | >>> >>> >>> >> >> >> -- >> Pengutronix e.K. | | >> Steuerwalder Str. 21 | http://www.pengutronix.de/ | >> 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | >> Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | > > > -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |