From patchwork Thu Aug 22 05:23:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hao Qin X-Patchwork-Id: 13772662 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EF630C3DA4A for ; Thu, 22 Aug 2024 05:24:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:MIME-Version: Message-ID:Date:Subject:CC:To:From:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=Zi1oFdwslpFsySYhI5Npfy3fFU8blZB+R3aDcpwYrDk=; b=LFl2dDuVkakCuHlAV+Ei2X1UqV 24R51ODXAKm/uX8WohZgblpA8K9NrvJeIjy2mF1LTYHltVqlbgn5q6+tlpfAtb55Ml54dy4bPfSpO Vw1Ibq15i/jFKHDkfBtNzAHauOapJq4TTC3pW2RT76aBjDEUaaLlx5JJ9JXdtQhT2ySNWu+qFnhoH NhJPdMwMg0pmuBaOt82dvLTy6wTkJMnL+BCVDdnyRV2Rin8gMM/k9exSYsMbUZoQWwM8gNR3P2Eyj aQi81TJViRngR576qK1y3Q3x8dozEz4YVJv87Is5nH7nRXjocmkHIQVKfIbDbg3S4HlwHAbAvJ+Yo y5TgukMw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sh0Ih-0000000BSXL-3B1E; Thu, 22 Aug 2024 05:23:59 +0000 Received: from mailgw02.mediatek.com ([216.200.240.185]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sh0If-0000000BSWg-1MgG for linux-mediatek@lists.infradead.org; Thu, 22 Aug 2024 05:23:58 +0000 X-UUID: b6320b60604611efba0aef63c0775dbf-20240821 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:MIME-Version:Message-ID:Date:Subject:CC:To:From; bh=Zi1oFdwslpFsySYhI5Npfy3fFU8blZB+R3aDcpwYrDk=; b=EJr90hX42QkxH5dLceei7o5zekXmK+Pwhs2mRyBjUfQcBcwmw+KL9cbzmRLLGJ4O36eiUkKLgrejl+OfoRCKiURwE7/J+zc/N/nUEO51kpaLfk73jzFlOkhW+lZBOilPRGLXw/s5vP/eTkVKxP+c9NHAJ6JsvgYqpakZAA8sSKg=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.41,REQID:51e79f95-0053-4756-8f11-43588ec00e86,IP:0,U RL:0,TC:0,Content:-5,EDM:0,RT:0,SF:0,FILE:0,BULK:0,RULE:Release_Ham,ACTION :release,TS:-5 X-CID-META: VersionHash:6dc6a47,CLOUDID:9ce8fdce-7921-4900-88a1-3aef019a55ce,B ulkID:nil,BulkQuantity:0,Recheck:0,SF:102,TC:nil,Content:0,EDM:-3,IP:nil,U RL:0,File:nil,RT:nil,Bulk:nil,QS:nil,BEC:nil,COL:0,OSI:0,OSA:0,AV:0,LES:1, SPR:NO,DKR:0,DKP:0,BRR:0,BRE:0,ARC:0 X-CID-BVR: 0,NGT X-CID-BAS: 0,NGT,0,_ X-CID-FACTOR: TF_CID_SPAM_SNR X-UUID: b6320b60604611efba0aef63c0775dbf-20240821 Received: from mtkmbs13n2.mediatek.inc [(172.21.101.108)] by mailgw02.mediatek.com (envelope-from ) (musrelay.mediatek.com ESMTP with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 2140867284; Wed, 21 Aug 2024 22:23:49 -0700 Received: from mtkmbs13n1.mediatek.inc (172.21.101.193) by MTKMBS14N1.mediatek.inc (172.21.101.75) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Thu, 22 Aug 2024 13:23:14 +0800 Received: from mhfsdcap04.gcn.mediatek.inc (10.17.3.154) by mtkmbs13n1.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.1118.26 via Frontend Transport; Thu, 22 Aug 2024 13:23:13 +0800 From: Hao Qin To: Marcel Holtmann , Johan Hedberg , Luiz Von Dentz CC: Chris Lu , Sean Wang , Deren Wu , Aaron Hou , "Steve Lee" , linux-bluetooth , linux-kernel , linux-mediatek , Hao Qin Subject: [PATCH] Bluetooth: btmtk: Remove resetting mt7921 before downloading the fw Date: Thu, 22 Aug 2024 13:23:10 +0800 Message-ID: <20240822052310.25220-1-hao.qin@mediatek.com> X-Mailer: git-send-email 2.18.0 MIME-Version: 1.0 X-TM-AS-Product-Ver: SMEX-14.0.0.3152-9.1.1006-23728.005 X-TM-AS-Result: No-10--4.498600-8.000000 X-TMASE-MatchedRID: hQ3LGvLpFaKGsPek1xLHVhuZoNKc6pl+Kx5ICGp/WtGIoW+1yT7Gw43q EYKsEnZO8DRYXhYkzdkwc9Bdak/KgMcUiDRLzlgWRlqShqb35p59LQinZ4QefPcjNeVeWlqY+gt Hj7OwNO34ZhR52Rc1ar8VznWR013yuuTZ49+OrM4KkaNHlVdn53Hot+sf2xIPIBp7MM+pUoZl7Z Lan9xbOfC4Kd09x+FJ9Wlxn6Xuslj+Nzym4pugNUma3zYT97IFAYfQIAUhBayZvmCbKVb49sZL6 x5U/HridGByp+zdaDg= X-TM-AS-User-Approved-Sender: No X-TM-AS-User-Blocked-Sender: No X-TMASE-Result: 10--4.498600-8.000000 X-TMASE-Version: SMEX-14.0.0.3152-9.1.1006-23728.005 X-TM-SNTS-SMTP: CC8BD9FB5F7243A38A9609A53706687D8166E6C3555EE50B17BC3AC959645F4E2000:8 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240821_222357_403038_71CB488A X-CRM114-Status: GOOD ( 10.41 ) X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org Remove resetting mt7921 before downloading the fw, as it may cause command timeout when performing the reset. Signed-off-by: Hao Qin --- drivers/bluetooth/btmtk.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/bluetooth/btmtk.c b/drivers/bluetooth/btmtk.c index 2b7c80043aa2..a46f70135cbd 100644 --- a/drivers/bluetooth/btmtk.c +++ b/drivers/bluetooth/btmtk.c @@ -1326,7 +1326,6 @@ int btmtk_usb_setup(struct hci_dev *hdev) fwname = FIRMWARE_MT7668; break; case 0x7922: - case 0x7961: case 0x7925: /* Reset the device to ensure it's in the initial state before * downloading the firmware to ensure. @@ -1334,7 +1333,8 @@ int btmtk_usb_setup(struct hci_dev *hdev) if (!test_bit(BTMTK_FIRMWARE_LOADED, &btmtk_data->flags)) btmtk_usb_subsys_reset(hdev, dev_id); - + fallthrough; + case 0x7961: btmtk_fw_get_filename(fw_bin_name, sizeof(fw_bin_name), dev_id, fw_version, fw_flavor);