mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: quic_zijuhu <quic_zijuhu@quicinc.com>
To: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
Cc: Marcel Holtmann <marcel@holtmann.org>,
	Johan Hedberg <johan.hedberg@gmail.com>,
	David Miller <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Luiz Augusto Von Dentz <luiz.von.dentz@intel.com>,
	<swyterzone@gmail.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"linux-bluetooth@vger.kernel.org"
	<linux-bluetooth@vger.kernel.org>,
	"open list:NETWORKING [GENERAL]" <netdev@vger.kernel.org>
Subject: Re: [PATCH v1 3/3] Bluetooth: btusb: Remove HCI_QUIRK_BROKEN_ERR_DATA_REPORTING for fake CSR
Date: Thu, 21 Jul 2022 09:28:31 +0800	[thread overview]
Message-ID: <311eba1b-d62f-7029-9775-e4843d71befa@quicinc.com> (raw)
In-Reply-To: <CABBYNZJ9Re7PZOFXhj-2tRwJ1UU2kY+QhB4dJT-=GyCYqb_Hhw@mail.gmail.com>

On 7/20/2022 11:38 PM, Luiz Augusto von Dentz wrote:
> Hi Zijun,
> 
> On Wed, Jul 20, 2022 at 7:07 AM Zijun Hu <quic_zijuhu@quicinc.com> wrote:
>>
>> Fake CSR BT controllers do not enable feature "Erroneous Data Reporting"
>> currently, BT core driver will check the feature bit instead of the quirk
>> to decide if HCI command HCI_Read|Write_Default_Erroneous_Data_Reporting
>> work fine, so remove HCI_QUIRK_BROKEN_ERR_DATA_REPORTING for fake CSR.
>>
>> Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
>> ---
>>  drivers/bluetooth/btusb.c | 1 -
>>  1 file changed, 1 deletion(-)
>>
>> diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
>> index f0f86c5c3b37..f2b3d31d56cf 100644
>> --- a/drivers/bluetooth/btusb.c
>> +++ b/drivers/bluetooth/btusb.c
>> @@ -2072,7 +2072,6 @@ static int btusb_setup_csr(struct hci_dev *hdev)
>>                  * without these the controller will lock up.
>>                  */
>>                 set_bit(HCI_QUIRK_BROKEN_STORED_LINK_KEY, &hdev->quirks);
>> -               set_bit(HCI_QUIRK_BROKEN_ERR_DATA_REPORTING, &hdev->quirks);
>>                 set_bit(HCI_QUIRK_BROKEN_FILTER_CLEAR_ALL, &hdev->quirks);
>>                 set_bit(HCI_QUIRK_NO_SUSPEND_NOTIFIER, &hdev->quirks);
> 
> You will probably need to remove HCI_QUIRK_BROKEN_ERR_DATA_REPORTING
> last otherwise it breaks the build in between patches, and please
> double check if there are no other instances of driver using it or
> perhaps leave it defined in case the feature is broken for some reason
> but then we need a macro that checks both the quirk and the feature
> bit.
> 
okay, i will split this change to solve build error between patches.

yes.  only QCA and CSR device with USB I/F use it. no other driver use it

the quirk was introduced to mark HCI_Read|Write_Default_Erroneous_Data_Reporting
broken, but the reason why these two HCI commands don't work fine is that the feature
"Erroneous Data Reporting" is not enabled by firmware.
so we need to check the feature bit instead of the quirk and don't also need the quirk.

>> --
>> The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
>>
> 
> 


      reply	other threads:[~2022-07-21  1:28 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-20 14:07 [PATCH v1 0/3] Bluetooth: Remove HCI_QUIRK_BROKEN_ERR_DATA_REPORTING Zijun Hu
2022-07-20 14:07 ` [PATCH v1 1/3] Bluetooth: hci_sync: " Zijun Hu
2022-07-20 14:07 ` [PATCH v1 2/3] Bluetooth: btusb: Remove HCI_QUIRK_BROKEN_ERR_DATA_REPORTING for QCA Zijun Hu
2022-07-20 14:07 ` [PATCH v1 3/3] Bluetooth: btusb: Remove HCI_QUIRK_BROKEN_ERR_DATA_REPORTING for fake CSR Zijun Hu
2022-07-20 15:38   ` Luiz Augusto von Dentz
2022-07-21  1:28     ` quic_zijuhu [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=311eba1b-d62f-7029-9775-e4843d71befa@quicinc.com \
    --to=quic_zijuhu@quicinc.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=johan.hedberg@gmail.com \
    --cc=kuba@kernel.org \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luiz.dentz@gmail.com \
    --cc=luiz.von.dentz@intel.com \
    --cc=marcel@holtmann.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=swyterzone@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®