答复: 答复: [PATCH v2] Bluetooth: btusb: Add Realtek 8723/8761 support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Daniel,
	The 8761 module used with different wifi chip can only be distinguished by pid, and do not support vendor command to get information from rom code.
The setup function only has hci_dev parameter . 
we can add driver_info and set different setup funcitons. Will this be acceptable or do you have other suggestions? 
	
(1)
#define BTUSB_RTL			0x200
#define BTUSB_RTL8761AW8192EU	0x400
#define BTUSB_RTL8761AU8192EE	0x800
#define BTUSB_RTL8761AU8812AE	0x1000

(2)
blacklist_table[] = {
.....
	/*RTL8761AW + 8192EU*/
	{ USB_DEVICE(0x818B, 0x0bda), .driver_info = BTUSB_RTL8761AW8192EU},
	{ USB_DEVICE(0x818c, 0x0bda), .driver_info = BTUSB_RTL8761AW8192EU},
	/*Rtl8761AU + 8192EE*/
	{ USB_DEVICE(0x8760, 0x0bda), .driver_info = BTUSB_RTL8761AU8192EE},
	{ USB_DEVICE(0x8761, 0x0bda), .driver_info = BTUSB_RTL8761AU8192EE},
	{ USB_DEVICE(0xB761, 0x0bda), .driver_info = BTUSB_RTL8761AU8192EE},
	/*RTL8761AU + 8812AE*/
	{ USB_DEVICE(0x8A60, 0x0bda), .driver_info = BTUSB_RTL8761AU8812AE},

(3) 
btusb_probe(){
	if (id->driver_info & BTUSB_RTL)
		hdev->setup = btusb_setup_rtl;
	if (id->driver_info & BTUSB_RTL8761AW8192EU)
		hdev->setup = btusb_setup_rtl8761aw8192eu;
	if (id->driver_info & BTUSB_RTL8761AU8192EE)
		hdev->setup = btusb_setup_rtl8761au8192ee;
	if (id->driver_info & BTUSB_RTL8761AU8812AE)
		hdev->setup = btusb_setup_rtl8761au8812ae;

For these special cases, we are still under develop , I think we can update next time.

" However, your new code also drops usage of the config firmware files e.g. rtl8723b_config.
Can you explain what these files are for, and if they are safe to ignore like your new code does?" 
For each module, there may be used as one antenna or two antenna . Config file can be used to change the antenna settings and other feature such as bt address and power. If config file is not provided ,modules will use the default settings.
I will add the config file in driver .


Champion
Ext:6325


-----邮件原件-----
发件人: Daniel Drake [mailto:drake@xxxxxxxxxxxx] 
发送时间: 2014年7月8日 15:57
收件人: 陈艳萍
抄送: Marcel Holtmann; Larry Finger; Gustavo F. Padovan; Johan Hedberg; Linux Bluetooth mailing list
主题: Re: 答复: [PATCH v2] Bluetooth: btusb: Add Realtek 8723/8761 support

Hi Champion,

On Fri, Jul 4, 2014 at 11:11 AM, 陈艳萍 <champion_chen@xxxxxxxxxxxxxx> wrote:
>          Attached file includes vendor commands of realtek Bluetooth modules in initialize procedure.
>
> And btusb is example of add rtl setup callbacks (not finished)

Thanks a lot for providing this information!

The btusb example you attached also the USB-ID-to-firmware-name lookup table that Marcel was not so happy about. Instead it reads the version info from the device and uses that to decide which of the firmware files to use (e.g. rtl8723a_fw). It can do this because it drops support for the following "problematic" RTL8761-based devices which need a special firmware for each variant of the card:

    { 0x818B, 0x8761, "rtl8761aw8192eu_fw", "rtl8761a_config", NULL, 0 }, //Rtl8761Aw + 8192EU
    { 0x8760, 0x8761, "rtl8761au8192ee_fw", "rtl8761a_config", NULL, 0 }, //Rtl8761AU + 8192EE
    { 0xB761, 0x8761, "rtl8761au8192ee_fw", "rtl8761a_config", NULL, 0 }, //Rtl8761AU + 8192EE
    { 0x8761, 0x8761, "rtl8761au8192ee_fw", "rtl8761a_config", NULL, 0 }, //Rtl8761AU + 8192EE for LI
    { 0x8A60, 0x8761, "rtl8761au8812ae_fw", "rtl8761a_config", NULL, 0 }, //Rtl8761AU + 8812AE (from https://github.com/lwfinger/rtl8723au_bt/blob/new/rtk_btusb.c#L1450 )

If these particular devices are not common then indeed maybe we can not worry about supporting them for now.

However, your new code also drops usage of the config firmware files e.g. rtl8723b_config.
Can you explain what these files are for, and if they are safe to ignore like your new code does?

Your new code references 2 firmware files that we don't have:
rtl8821a_fw and rtl8761a_fw. Please could you send them over, and confirm that they are redistributable?

Please also confirm that we have the latest versions of the other 2 files:

rtl8723a_fw: 24356 bytes
md5sum b4a329212ab150b88c3c6ff4c42c51d6

rtl8723b_fw: 38976 bytes
md5sum ebf894b7b91cbebce8aeb5ba63c22914

These can be found at https://github.com/lwfinger/rtl8723au_bt/tree/new

Thanks
Daniel
��.n��������+%������w��{.n�����{����^n�r������&��z�ޗ�zf���h���~����������_��+v���)ߣ�


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux