Received: by 2002:a05:6500:1b41:b0:1fb:d597:ff75 with SMTP id cz1csp142914lqb; Tue, 4 Jun 2024 07:26:39 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVGGMpsb8EaefTs0ewEPEfg6qUtx+TPny8nGYP9akBLDsvw2/U99ArtaufezQCNuMhait9DNjMkDobVPDPz44zxo0Jglcu25G746fNrwA== X-Google-Smtp-Source: AGHT+IE3ZEvRLe17hoq0kESDSuamgqgTRdw9XuaWdI1bEXJTZQ6RM7ZA6azOvaIM/h4ONX+JmpNW X-Received: by 2002:a05:6870:b24f:b0:24f:cb66:3ec0 with SMTP id 586e51a60fabf-2508b7ddfddmr14339219fac.4.1717511198880; Tue, 04 Jun 2024 07:26:38 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717511198; cv=pass; d=google.com; s=arc-20160816; b=ZXXR5mTelpj7MwjZjwK6w31V6dpurIKj31E28xMSgOdAqhG8WSFFHAZRM9aeX+BykI Z9X6qLYpCpBJFh6Q0N/9pi/4kIAr26f+i67YR0EsZjvc4vvWmzubG6ixoh6IH1sdY1L+ 1pBTrSR685EPldEIo7hiiHlPEXbuA73hPPFsjML2LsQrEhror6dbVUkA+KfuO5GmSYb+ lTMVp0kJs/jVovNohl+R3SjFBHmLBQOVGjuWyrTlFF8jvW2Dz0oBXnJSYLQm0uTxNYUb QF664/AMoQHvCxghctNylHLC6ZameuwiipK2Mbq7E5N/m01Ugd9ENtXTWWX9J3WA5sXK 8P0A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=RIygmrpjr/F3XNMpwMpVtcEcYFfz2BQ0PeKPZfeJkm4=; fh=YVpF29/F1nOqKPlqvNBCEpGftlaDT9FCBi3pLTf8n10=; b=yyWVkaslfRi5pS6kA2tYdukFUm3Lk08AeTH48jPABAB/yoj5mQuf3ofosnfwkQP+vg cqinH07tAV1nqNMVTgiytXoMrOqaC/FPRTmeqsXLhLNZ/hJzNdmTT6b6nBr4ER3zpFob Q/VLZPxkmDtM57l24HqH+MqbSV866MIQ2REZUf1CQIL6GISDNYkLP0JSYuQCPTbqk99t Ohzeomp8YWeMk9qLaUmhxFUbwKtHp6QyKP7X7PQeZVRl+KJVC2HMhV4peSEIOamTsYg2 fhbs1MdyqS992NqAEAAS+TmcAovKwgg2oHXOZbKxlg8tHJT4/nt+DQjKMart8vQrK634 zdIA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@163.com header.s=s110527 header.b="pduH/RRB"; arc=pass (i=1 spf=pass spfdomain=163.com dkim=pass dkdomain=163.com dmarc=pass fromdomain=163.com); spf=pass (google.com: domain of linux-bluetooth+bounces-5110-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-bluetooth+bounces-5110-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=163.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id af79cd13be357-7952214b778si3847185a.216.2024.06.04.07.26.38 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 04 Jun 2024 07:26:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth+bounces-5110-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@163.com header.s=s110527 header.b="pduH/RRB"; arc=pass (i=1 spf=pass spfdomain=163.com dkim=pass dkdomain=163.com dmarc=pass fromdomain=163.com); spf=pass (google.com: domain of linux-bluetooth+bounces-5110-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-bluetooth+bounces-5110-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=163.com 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 28DFD1C22005 for ; Tue, 4 Jun 2024 14:26:38 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EAF6E12D215; Tue, 4 Jun 2024 14:26:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=163.com header.i=@163.com header.b="pduH/RRB" X-Original-To: linux-bluetooth@vger.kernel.org Received: from m15.mail.163.com (m15.mail.163.com [45.254.50.220]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 64BEE171C9; Tue, 4 Jun 2024 14:26:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.254.50.220 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717511190; cv=none; b=t+C4zzPygpJWSry9OGV/keEARCgWBm/QBzr2wA2OkskIT5K2h0xF4bfTsEIuuemY1CJbiXQkJFSEP7StUJ4+LkcW8Vvp3POq8qeVe2WWx0S0r1swXDJdzkrJIYFNYyq/wBj7nraSBdq09qDgXl9QfOGZzJTEpQENlssLM7zH2K4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717511190; c=relaxed/simple; bh=axNTdX4yhhIOJ+QIsoHRh/n4DoRTRP01CZzSsF18SEg=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=ezRO/ci3u6NNJJ/9blF50sMIy6LpF+B18vQijxUwlk+JwCT7TpP2E7M1X1wGLRHx7baYyjLyXD8ecQwlSXQR1D5QMxbAIrTZeYMaqYRsjGRlaR6KZcsGPGrVRZp5spBjs4/AVT2mIXl26zXr6cw5fnxJRoQfk8kxCIPweR2AtYQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=163.com; spf=pass smtp.mailfrom=163.com; dkim=pass (1024-bit key) header.d=163.com header.i=@163.com header.b=pduH/RRB; arc=none smtp.client-ip=45.254.50.220 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=163.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=163.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=Message-ID:Date:MIME-Version:Subject:From: Content-Type; bh=RIygmrpjr/F3XNMpwMpVtcEcYFfz2BQ0PeKPZfeJkm4=; b=pduH/RRBlOBTjUyQq6DWQfKd9ZvbiWFMCRGYfMhP1MM9abdhv58uH5cn0PwFQf F4MEx+wZBD8T983Qc25ZZcNeayUmDVtwfnUg7YnCoMY6viOiUBgCi3JvvhY3/S3l DjZjN9KtutmztC8cVGXv1razjQnmQWMQpQIKZxpWD/xSc= Received: from [192.168.1.26] (unknown [183.195.6.89]) by gzga-smtp-mta-g0-1 (Coremail) with SMTP id _____wD3P0XHI19mOdXWBw--.39291S2; Tue, 04 Jun 2024 22:25:12 +0800 (CST) Message-ID: <29333872-4ff2-4f4e-8166-4c847c7605c1@163.com> Date: Tue, 4 Jun 2024 22:25:11 +0800 Precedence: bulk X-Mailing-List: linux-bluetooth@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2] Bluetooth: qca: Fix BT enable failure again for QCA6390 after warm reboot To: Krzysztof Kozlowski , Zijun Hu , luiz.dentz@gmail.com, luiz.von.dentz@intel.com, marcel@holtmann.org Cc: linux-bluetooth@vger.kernel.org, wt@penguintechs.org, regressions@lists.linux.dev, pmenzel@molgen.mpg.de, stable@vger.kernel.org References: <1715866294-1549-1-git-send-email-quic_zijuhu@quicinc.com> <7927abbe-3395-4a53-9eed-7b4204d57df5@linaro.org> Content-Language: en-US From: Lk Sii In-Reply-To: <7927abbe-3395-4a53-9eed-7b4204d57df5@linaro.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-CM-TRANSID:_____wD3P0XHI19mOdXWBw--.39291S2 X-Coremail-Antispam: 1Uf129KBjvJXoWxGFW3uFy7WrykCr1rAF4fXwb_yoW5CFy7pF W5KF1qyrWUtr18Ka17A34xKFy2vwnI9F1rWr1kG3y5J3y5ZF95WFWSgrW5Xa4DCryxuw1j van7X34qgrZ0kaDanT9S1TB71UUUUU7qnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDUYxBIdaVFxhVjvjDU0xZFpf9x07jxHUDUUUUU= X-CM-SenderInfo: 5onb2xrl6rljoofrz/1tbiyQnzNWV4JejwvQAAsb On 2024/5/22 00:02, Krzysztof Kozlowski wrote: > On 16/05/2024 15:31, Zijun Hu wrote: >> Commit 272970be3dab ("Bluetooth: hci_qca: Fix driver shutdown on closed >> serdev") will cause below regression issue: >> >> BT can't be enabled after below steps: >> cold boot -> enable BT -> disable BT -> warm reboot -> BT enable failure >> if property enable-gpios is not configured within DT|ACPI for QCA6390. >> >> The commit is to fix a use-after-free issue within qca_serdev_shutdown() >> by adding condition to avoid the serdev is flushed or wrote after closed >> but also introduces this regression issue regarding above steps since the >> VSC is not sent to reset controller during warm reboot. >> >> Fixed by sending the VSC to reset controller within qca_serdev_shutdown() >> once BT was ever enabled, and the use-after-free issue is also fixed by >> this change since the serdev is still opened before it is flushed or wrote. >> >> Verified by the reported machine Dell XPS 13 9310 laptop over below two >> kernel commits: > > I don't understand how does it solve my question. I asked you: on which > hardware did you, not the reporter, test? >It seems Zijun did NOT perform any tests obviously. All these tests were performed by reporter Wren with her machine "Dell XPS 13 9310 laptop". From previous discussion, it seems she have tested this change several times with positive results over different trees with her machine. i noticed she given you reply for your questions within below v1 discussion link as following: Here are v1 discussion link. https://lore.kernel.org/linux-bluetooth/d553edef-c1a4-4d52-a892-715549d31ebe@163.com/T/#m7371df555fd58ba215d0da63055134126a43c460 Here are Krzysztof's questions. "I asked already *two times*: 1. On which kernel did you test it? 2. On which hardware did you test it?" Here are Wren's reply for Krzysztof's questions "I thought I had already chimed in with this information. I am using a Dell XPS 13 9310. It's the only hardware I have access to. I can say that the fix seems to work as advertised in that it fixes the warm boot issue I have been experiencing." >> commit e00fc2700a3f ("Bluetooth: btusb: Fix triggering coredump >> implementation for QCA") of bluetooth-next tree. >> commit b23d98d46d28 ("Bluetooth: btusb: Fix triggering coredump >> implementation for QCA") of linus mainline tree. > > ? Same commit with different hashes? No, it looks like you are working > on some downstream tree with cherry picks. > From Zijun's commit message, for the same commit, it seems bluetooth-next tree has different hashes as linus tree. not sure if this scenario is normal during some time window. > No, test it on mainline and answer finally, after *five* tries, which > kernel and which hardware did you use for testing this. > > it seems there are two issues mentioned with Zijun's commit message. regression issue A: BT enable failure after warm reboot. issue B: use-after-free issue, namely, kernel crash. @Krzysztof which issue to test based on your concerns with mainline tree? > > Best regards, > Krzysztof >