• J
    Bluetooth: btusb: Detect new kind of counterfeit CSR controllers · 6cafcd95
    Johan Hedberg 提交于
    Controllers claiming to be CSR with LMP subversion 0x0c5c don't
    actually seem to be authentic CSR controllers. They also don't have
    their USB bcdDevice value matching the LMP subversion like all other
    CSR controllers:
    
    HCI:
    
    > HCI Event: Command Complete (0x0e) plen 12
          Read Local Version Information (0x04|0x0001) ncmd 1
            Status: Success (0x00)
            HCI version: Bluetooth 2.0 (0x03) - Revision 3164 (0x0c5c)
            LMP version: Bluetooth 2.0 (0x03) - Subversion 3164 (0x0c5c)
            Manufacturer: Cambridge Silicon Radio (10)
    
    USB:
    
    T: Bus=04 Lev=01 Prnt=01 Port=01 Cnt=01 Dev#= 3 Spd=12 MxCh= 0
    D: Ver= 1.10 Cls=e0(wlcon) Sub=01 Prot=01 MxPS=16 #Cfgs= 1
    P: Vendor=0a12 ProdID=0001 Rev= 1.34
    C:* #Ifs= 2 Cfg#= 1 Atr=80 MxPwr=100mA
    I:* If#= 0 Alt= 0 #EPs= 3 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
    E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl=1ms
    E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
    E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
    I:* If#= 1 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
    E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms
    E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms
    I: If#= 1 Alt= 1 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
    E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms
    E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms
    I: If#= 1 Alt= 2 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
    E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms
    E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms
    
    These controllers also have the HCI_Read_Stored_Link_Key command
    broken so it's important the right quirk is set for them.
    Reported-and-tested-by: NRhobison Alves Pereira <rhobison@hotmail.com>
    Signed-off-by: NJohan Hedberg <johan.hedberg@intel.com>
    Signed-off-by: NMarcel Holtmann <marcel@holtmann.org>
    6cafcd95
btusb.c 76.6 KB