Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp5615758ybv; Tue, 18 Feb 2020 00:31:01 -0800 (PST) X-Google-Smtp-Source: APXvYqyKsgcAoJlcoWEoPeLfLbdv9hYhMuomfQW9szv/8TDWI7HG2wusMhFa+t0P/El/R+7Y5ifx X-Received: by 2002:a05:6808:4c2:: with SMTP id a2mr499817oie.118.1582014661282; Tue, 18 Feb 2020 00:31:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582014661; cv=none; d=google.com; s=arc-20160816; b=kiJhNWhRyCPX895fzLL7oCPOWUGaJYGA2/+GMq0gwlQ2E+g+LJ8lzl4zJCLdRR8h4d XGWIfWdqxUu9JEjxpIMWpBkTYNXvHTyEBmogREVlj0Pu/Nlb+x41AgLnS/0YehHcTqsR tzmItYo8NLHCbBReUiuFsqhKg6kozq4uLeIm1Njq0+EtCvrUTXX8IRyOTfYOVZ1GjckQ HiYSmADBQ+jf1zqkl/tdpCLvN29FCjP+NNzHGTBLFcXlfQbsFoRK2HsFrjLVVsgfFUyC s1tdxqZRd43iG3/ctuojBj5BZ5gV5vhtvtcjqPiegyUAuRxz8X7yF7Bk1chP16DwBrUW E09Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:references:message-id :content-transfer-encoding:cc:date:in-reply-to:from:subject :mime-version; bh=SgOiijRefYBLWLsU5H/whhTkl1h4OmZMpSlHtCmfZLQ=; b=sCj9U+WSQJw90YN8D2W8wuldyLXPvwL7MIQFrenYxnqZYv7f9y6gYVenBo43Xg2gcJ dq6GuMVfb9p+vYaJ3bmlXNt8JbRepfy30N4ZE2pn5+kHtA58vj0cOxlWSiJNWmNYVrjC qfqhVFrzQ8gQLF8Ga6s+8YK1364RnKocY2ODRJzvAzSzO2euzx8AlNCRFw4wyUH1ZJFm 220SICCwvaNn2TOmBdNHlETxoEv7Sh58w7JakPyVQGlvzEOeL8CId6Sz47A88LYwdBrR mcpEkYE8sLP1F5vlZp92W4I+6dfIEqu53EQYvZ8u9YDX42FiC42eFuV5HB8P+TxL119M cxUg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-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 t130si7928913oib.202.2020.02.18.00.30.48; Tue, 18 Feb 2020 00:31:01 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726318AbgBRIan convert rfc822-to-8bit (ORCPT + 99 others); Tue, 18 Feb 2020 03:30:43 -0500 Received: from coyote.holtmann.net ([212.227.132.17]:40992 "EHLO mail.holtmann.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726127AbgBRIan (ORCPT ); Tue, 18 Feb 2020 03:30:43 -0500 Received: from marcel-macpro.fritz.box (p4FEFC5A7.dip0.t-ipconnect.de [79.239.197.167]) by mail.holtmann.org (Postfix) with ESMTPSA id 2FD25CED24; Tue, 18 Feb 2020 09:40:05 +0100 (CET) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 13.0 \(3608.60.0.2.5\)) Subject: Re: [PATCH v4] Bluetooth: hci_qca: Bug fixes while collecting controller memory dump From: Marcel Holtmann In-Reply-To: <20200214161715.2166-1-bgodavar@codeaurora.org> Date: Tue, 18 Feb 2020 09:30:40 +0100 Cc: Johan Hedberg , Matthias Kaehlcke , LKML , Bluez mailing list , Hemantg , MSM , Rocky Liao , Yoni Shavit , abhishekpandit@chromium.org, Venkata Lakshmi Narayana Gubba Content-Transfer-Encoding: 8BIT Message-Id: References: <20200214161715.2166-1-bgodavar@codeaurora.org> To: Balakrishna Godavarthi X-Mailer: Apple Mail (2.3608.60.0.2.5) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Balakrishna, > This patch will fix the below issues > 1. Discarding memory dump events if memdump state is moved to > MEMDUMP_TIMEOUT. > 2. Fixed race conditions between qca_hw_error() and qca_controller_memdump > while free memory dump buffers using mutex lock > 3. Moved timeout timer to delayed work queue > 4. Injecting HW error event in a case when dumps failed to receive and HW > error event is not yet received. > 5. Clearing hw error and command timeout function callbacks before > sending pre shutdown command. > > Collecting memory dump will follow any of the below sequence. > > Sequence 1: > Receiving Memory dump events from the controller > Received entire dump in stipulated time > Received HW error event from the controller > Controller Reset from HOST > > Sequence 2: > Receiving Memory dump events from the controller > Failed to Receive entire dump in stipulated time > A Timeout schedules and if no HW error event received a fake HW > error event will be injected. > Controller Reset from HOST. > > Sequence 3: > Received HW error event > HOST trigger SSR by sending crash packet to controller. > Received entire dump in stipulated time > Controller Reset from HOST > > Fixes: d841502c79e3 ("Bluetooth: hci_qca: Collect controller memory dump during SSR") > Reported-by: Abhishek Pandit-Subedi > Signed-off-by: Venkata Lakshmi Narayana Gubba > Reviewed-by: Abhishek Pandit-Subedi > --- > drivers/bluetooth/hci_qca.c | 101 ++++++++++++++++++++++++------------ > 1 file changed, 67 insertions(+), 34 deletions(-) patch has been applied to bluetooth-next tree. Regards Marcel