Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-23 Thread Adrian Chadd
ok, lemme go rescue my ar9462 hardware and test again.

-a

On Tue, 23 Apr 2019 at 12:46, Serge Semenenko  wrote:

> in /boot/device.hints I have
> hint.ath.0.btcoex_profile="wb222"
>
> it seems working
>
> kernel: ar9300_hw_attach: ar9300_eeprom_attach returned 0
> kernel: ath0: Enabling WB222 BTCOEX
> kernel: ath0: [HT] enabling HT modes
> kernel: ath0: [HT] enabling short-GI in 20MHz mode
> kernel: ath0: [HT] 1 stream STBC receive enabled
> kernel: ath0: [HT] 1 stream STBC transmit enabled
> kernel: ath0: [HT] LDPC transmit/receive enabled
> kernel: ath0: [HT] 2 RX streams; 2 TX streams
> kernel: ath0: AR9460 mac 640.3 RF5110 phy 3856.0
> kernel: ath0: 2GHz radio: 0x; 5GHz radio: 0x
> kernel: [ath] loaded
>
>
>
>
> вт, 23 апр. 2019 г. в 22:39, Adrian Chadd :
>
>> Do you have the kernel environment variable setup to say it's a WB222?
>>
>>
>> -a
>>
>>
>> On Tue, 23 Apr 2019 at 12:37, Serge Semenenko  wrote:
>>
>>> Could it matter that I load modules from rc.conf?
>>>
>>> kld_list="if_ath if_ath_pci linux linsysfs linprocfs xhci umass ums
>>> snd_hda /boot/modules/i915kms.ko /boot/modules/acpi_call.ko"
>>>
>>> вс, 21 апр. 2019 г. в 11:05, Matthias Apitz :
>>>
 El día sábado, abril 20, 2019 a las 02:16:49p. m. +0300, Serge
 Semenenko escribió:

 > Hi
 >
 > It works for me with such section in devd.conf
 >
 > attach 200 {
 >device-name "ubt[0-9]+";
 >match "vendor" "0x0cf3";
 >match "product" "0xe006";
 >action "sleep 2 && /usr/sbin/ath3kfw -d $ugen && sleep 2 &&
 /etc/rc.d/bluetooth quietstart $device-name";
 > };

 I have added the above lines to /etc/devd.conf, ofc with the vendor and
 product ID of my chip:

 $ usbconfig
 ...
 ugen0.3:  at usbus0, cfg=0 md=HOST
 spd=FULL (12Mbps) pwr=ON (100mA)

 and place the firmware in the directory where /usr/sbin/ath3kfw is
 looking for it, into /usr/share/firmware/ath3k/ar3k/

 The problem remains: no device /dev/ubt0 gets created (and the attach
 rule does not apply.

 When I change 'attach 200' to 'notify 100', /usr/sbin/ath3kfw gets
 called and the firmware gets loaded into the chip. But nothing of BT
 does work.

 I think some of the nd_*.ko modules do not attach and due to this the
 device is not created.

 matthias

 --
 Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
 +49-176-38902045
 Public GnuPG key: http://www.unixarea.de/key.pub
 N € I N zur EU!
 "Gegen das EU-Europa der Banken, Konzerne und Kriegstreiber.
 Für ein soziales und friedliches Europa der Völker." DKP

>>>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-23 Thread Serge Semenenko
in /boot/device.hints I have
hint.ath.0.btcoex_profile="wb222"

it seems working

kernel: ar9300_hw_attach: ar9300_eeprom_attach returned 0
kernel: ath0: Enabling WB222 BTCOEX
kernel: ath0: [HT] enabling HT modes
kernel: ath0: [HT] enabling short-GI in 20MHz mode
kernel: ath0: [HT] 1 stream STBC receive enabled
kernel: ath0: [HT] 1 stream STBC transmit enabled
kernel: ath0: [HT] LDPC transmit/receive enabled
kernel: ath0: [HT] 2 RX streams; 2 TX streams
kernel: ath0: AR9460 mac 640.3 RF5110 phy 3856.0
kernel: ath0: 2GHz radio: 0x; 5GHz radio: 0x
kernel: [ath] loaded




вт, 23 апр. 2019 г. в 22:39, Adrian Chadd :

> Do you have the kernel environment variable setup to say it's a WB222?
>
>
> -a
>
>
> On Tue, 23 Apr 2019 at 12:37, Serge Semenenko  wrote:
>
>> Could it matter that I load modules from rc.conf?
>>
>> kld_list="if_ath if_ath_pci linux linsysfs linprocfs xhci umass ums
>> snd_hda /boot/modules/i915kms.ko /boot/modules/acpi_call.ko"
>>
>> вс, 21 апр. 2019 г. в 11:05, Matthias Apitz :
>>
>>> El día sábado, abril 20, 2019 a las 02:16:49p. m. +0300, Serge Semenenko
>>> escribió:
>>>
>>> > Hi
>>> >
>>> > It works for me with such section in devd.conf
>>> >
>>> > attach 200 {
>>> >device-name "ubt[0-9]+";
>>> >match "vendor" "0x0cf3";
>>> >match "product" "0xe006";
>>> >action "sleep 2 && /usr/sbin/ath3kfw -d $ugen && sleep 2 &&
>>> /etc/rc.d/bluetooth quietstart $device-name";
>>> > };
>>>
>>> I have added the above lines to /etc/devd.conf, ofc with the vendor and
>>> product ID of my chip:
>>>
>>> $ usbconfig
>>> ...
>>> ugen0.3:  at usbus0, cfg=0 md=HOST
>>> spd=FULL (12Mbps) pwr=ON (100mA)
>>>
>>> and place the firmware in the directory where /usr/sbin/ath3kfw is
>>> looking for it, into /usr/share/firmware/ath3k/ar3k/
>>>
>>> The problem remains: no device /dev/ubt0 gets created (and the attach
>>> rule does not apply.
>>>
>>> When I change 'attach 200' to 'notify 100', /usr/sbin/ath3kfw gets
>>> called and the firmware gets loaded into the chip. But nothing of BT
>>> does work.
>>>
>>> I think some of the nd_*.ko modules do not attach and due to this the
>>> device is not created.
>>>
>>> matthias
>>>
>>> --
>>> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
>>> +49-176-38902045
>>> Public GnuPG key: http://www.unixarea.de/key.pub
>>> N € I N zur EU!
>>> "Gegen das EU-Europa der Banken, Konzerne und Kriegstreiber.
>>> Für ein soziales und friedliches Europa der Völker." DKP
>>>
>>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-23 Thread Adrian Chadd
Do you have the kernel environment variable setup to say it's a WB222?


-a


On Tue, 23 Apr 2019 at 12:37, Serge Semenenko  wrote:

> Could it matter that I load modules from rc.conf?
>
> kld_list="if_ath if_ath_pci linux linsysfs linprocfs xhci umass ums
> snd_hda /boot/modules/i915kms.ko /boot/modules/acpi_call.ko"
>
> вс, 21 апр. 2019 г. в 11:05, Matthias Apitz :
>
>> El día sábado, abril 20, 2019 a las 02:16:49p. m. +0300, Serge Semenenko
>> escribió:
>>
>> > Hi
>> >
>> > It works for me with such section in devd.conf
>> >
>> > attach 200 {
>> >device-name "ubt[0-9]+";
>> >match "vendor" "0x0cf3";
>> >match "product" "0xe006";
>> >action "sleep 2 && /usr/sbin/ath3kfw -d $ugen && sleep 2 &&
>> /etc/rc.d/bluetooth quietstart $device-name";
>> > };
>>
>> I have added the above lines to /etc/devd.conf, ofc with the vendor and
>> product ID of my chip:
>>
>> $ usbconfig
>> ...
>> ugen0.3:  at usbus0, cfg=0 md=HOST spd=FULL
>> (12Mbps) pwr=ON (100mA)
>>
>> and place the firmware in the directory where /usr/sbin/ath3kfw is
>> looking for it, into /usr/share/firmware/ath3k/ar3k/
>>
>> The problem remains: no device /dev/ubt0 gets created (and the attach
>> rule does not apply.
>>
>> When I change 'attach 200' to 'notify 100', /usr/sbin/ath3kfw gets
>> called and the firmware gets loaded into the chip. But nothing of BT does
>> work.
>>
>> I think some of the nd_*.ko modules do not attach and due to this the
>> device is not created.
>>
>> matthias
>>
>> --
>> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
>> +49-176-38902045
>> Public GnuPG key: http://www.unixarea.de/key.pub
>> N € I N zur EU!
>> "Gegen das EU-Europa der Banken, Konzerne und Kriegstreiber.
>> Für ein soziales und friedliches Europa der Völker." DKP
>>
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-23 Thread Serge Semenenko
Could it matter that I load modules from rc.conf?

kld_list="if_ath if_ath_pci linux linsysfs linprocfs xhci umass ums snd_hda
/boot/modules/i915kms.ko /boot/modules/acpi_call.ko"

вс, 21 апр. 2019 г. в 11:05, Matthias Apitz :

> El día sábado, abril 20, 2019 a las 02:16:49p. m. +0300, Serge Semenenko
> escribió:
>
> > Hi
> >
> > It works for me with such section in devd.conf
> >
> > attach 200 {
> >device-name "ubt[0-9]+";
> >match "vendor" "0x0cf3";
> >match "product" "0xe006";
> >action "sleep 2 && /usr/sbin/ath3kfw -d $ugen && sleep 2 &&
> /etc/rc.d/bluetooth quietstart $device-name";
> > };
>
> I have added the above lines to /etc/devd.conf, ofc with the vendor and
> product ID of my chip:
>
> $ usbconfig
> ...
> ugen0.3:  at usbus0, cfg=0 md=HOST spd=FULL
> (12Mbps) pwr=ON (100mA)
>
> and place the firmware in the directory where /usr/sbin/ath3kfw is
> looking for it, into /usr/share/firmware/ath3k/ar3k/
>
> The problem remains: no device /dev/ubt0 gets created (and the attach
> rule does not apply.
>
> When I change 'attach 200' to 'notify 100', /usr/sbin/ath3kfw gets
> called and the firmware gets loaded into the chip. But nothing of BT does
> work.
>
> I think some of the nd_*.ko modules do not attach and due to this the
> device is not created.
>
> matthias
>
> --
> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
> +49-176-38902045
> Public GnuPG key: http://www.unixarea.de/key.pub
> N € I N zur EU!
> "Gegen das EU-Europa der Banken, Konzerne und Kriegstreiber.
> Für ein soziales und friedliches Europa der Völker." DKP
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-21 Thread Matthias Apitz
El día sábado, abril 20, 2019 a las 02:16:49p. m. +0300, Serge Semenenko 
escribió:

> Hi
> 
> It works for me with such section in devd.conf
> 
> attach 200 {
>device-name "ubt[0-9]+";
>match "vendor" "0x0cf3";
>match "product" "0xe006";
>action "sleep 2 && /usr/sbin/ath3kfw -d $ugen && sleep 2 && 
> /etc/rc.d/bluetooth quietstart $device-name";
> };

I have added the above lines to /etc/devd.conf, ofc with the vendor and
product ID of my chip: 

$ usbconfig
...
ugen0.3:  at usbus0, cfg=0 md=HOST spd=FULL 
(12Mbps) pwr=ON (100mA)

and place the firmware in the directory where /usr/sbin/ath3kfw is
looking for it, into /usr/share/firmware/ath3k/ar3k/

The problem remains: no device /dev/ubt0 gets created (and the attach
rule does not apply.

When I change 'attach 200' to 'notify 100', /usr/sbin/ath3kfw gets
called and the firmware gets loaded into the chip. But nothing of BT does work.

I think some of the nd_*.ko modules do not attach and due to this the
device is not created.

matthias

-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
N € I N zur EU!
"Gegen das EU-Europa der Banken, Konzerne und Kriegstreiber.
Für ein soziales und friedliches Europa der Völker." DKP
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-20 Thread Adrian Chadd
ooo please send me a pull request with the device id update!


-a

On Sat, 20 Apr 2019 at 04:17, Serge Semenenko  wrote:

> Hi
>
> It works for me with such section in devd.conf
>
> attach 200 {
>device-name "ubt[0-9]+";
>match "vendor" "0x0cf3";
>match "product" "0xe006";
>action "sleep 2 && /usr/sbin/ath3kfw -d $ugen && sleep 2 &&
> /etc/rc.d/bluetooth quietstart $device-name";
> };
>
>
> More info:
>
> #  uname -UK
> 1200505 1200505
>
> #  pciconf -lv | tail -8
> subclass   = ethernet
> ath0@pci0:2:0:0: class=0x028000 card=0x03001028 chip=0x0034168c rev=0x01
> hdr=0x00
> vendor = 'Qualcomm Atheros'
> device = 'AR9462 Wireless Network Adapter'
> class  = network
>
> #  usbconfig list
> ugen0.1: <0x8086 XHCI root HUB> at usbus0, cfg=0 md=HOST spd=SUPER
> (5.0Gbps) pwr=SAVE (0mA)
> ugen0.2:  at usbus0, cfg=0 md=HOST spd=HIGH
> (480Mbps) pwr=ON (500mA)
> ugen0.4:  at usbus0, cfg=0 md=HOST spd=FULL
> (12Mbps) pwr=ON (100mA)
> ugen0.3:  at usbus0, cfg=0 md=HOST spd=FULL
> (12Mbps) pwr=ON (100mA)
>
> # ll /usr/share/firmware/ath3k/ar3k/
> total 384
> drwxr-xr-x  2 serge  wheel512 17 лист.  2017 1020201coex/
> -rw-r--r--  1 serge  wheel  55244 30 бер.   2017 AthrBT_0x01020001.dfu
> -rw-r--r--  1 serge  wheel  40724 30 бер.   2017 AthrBT_0x01020200.dfu
> -rw-r--r--  1 serge  wheel  48188 17 лист.  2017 AthrBT_0x01020201.dfu
> -rw-r--r--  1 serge  wheel  36828 30 бер.   2017 AthrBT_0x1102.dfu
> -rw-r--r--  1 serge  wheel  46852 30 бер.   2017 AthrBT_0x11020100.dfu
> -rw-r--r--  1 serge  wheel  40652 30 бер.   2017 AthrBT_0x3101.dfu
> -rw-r--r--  1 serge  wheel  37796 30 бер.   2017 AthrBT_0x31010100.dfu
> -rw-r--r--  1 serge  wheel  31500 30 бер.   2017 AthrBT_0x4102.dfu
> -rw-r--r--  1 serge  wheel   1224 30 бер.   2017 ramps_0x01020001_26.dfu
> -rw-r--r--  1 serge  wheel   1274 30 бер.   2017 ramps_0x01020200_26.dfu
> -rw-r--r--  1 serge  wheel   1204 30 бер.   2017 ramps_0x01020200_40.dfu
> -rw-r--r--  1 serge  wheel264 30 бер.   2017 ramps_0x01020201_26.dfu
> -rw-r--r--  1 serge  wheel264 30 бер.   2017 ramps_0x01020201_40.dfu
> -rw-r--r--  1 serge  wheel   1796 30 бер.   2017 ramps_0x1102_40.dfu
> -rw-r--r--  1 serge  wheel   1802 30 бер.   2017 ramps_0x11020100_40.dfu
> -rw-r--r--  1 serge  wheel   1926 30 бер.   2017 ramps_0x3101_40.dfu
> -rw-r--r--  1 serge  wheel   1922 30 бер.   2017 ramps_0x31010100_40.dfu
> -rw-r--r--  1 serge  wheel   1820 30 бер.   2017 ramps_0x4102_40.dfu
>
> And also i had to add the card to /usr/src/usr.sbin/bluetooth/ath3kfw
>
> --- main.c.orig 2018-06-23 12:32:29.564631000 +0300
> +++ main.c  2018-06-23 12:33:01.28340 +0300
> @@ -85,6 +85,7 @@
> { .vendor_id = 0x0CF3, .product_id = 0x817a, .is_3012 = 1 },
> { .vendor_id = 0x0cf3, .product_id = 0xe004, .is_3012 = 1 },
> { .vendor_id = 0x0cf3, .product_id = 0xe005, .is_3012 = 1 },
> +{ .vendor_id = 0x0cf3, .product_id = 0xe006, .is_3012 = 1 },
> { .vendor_id = 0x0cf3, .product_id = 0xe003, .is_3012 = 1 },
> { .vendor_id = 0x13d3, .product_id = 0x3362, .is_3012 = 1 },
> { .vendor_id = 0x13d3, .product_id = 0x3375, .is_3012 = 1 },
> ___
> freebsd-wireless@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
> To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org
> "
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-20 Thread Serge Semenenko
Hi

It works for me with such section in devd.conf

attach 200 {
   device-name "ubt[0-9]+";
   match "vendor" "0x0cf3";
   match "product" "0xe006";
   action "sleep 2 && /usr/sbin/ath3kfw -d $ugen && sleep 2 &&
/etc/rc.d/bluetooth quietstart $device-name";
};


More info:

#  uname -UK
1200505 1200505

#  pciconf -lv | tail -8
subclass   = ethernet
ath0@pci0:2:0:0: class=0x028000 card=0x03001028 chip=0x0034168c rev=0x01
hdr=0x00
vendor = 'Qualcomm Atheros'
device = 'AR9462 Wireless Network Adapter'
class  = network

#  usbconfig list
ugen0.1: <0x8086 XHCI root HUB> at usbus0, cfg=0 md=HOST spd=SUPER
(5.0Gbps) pwr=SAVE (0mA)
ugen0.2:  at usbus0, cfg=0 md=HOST spd=HIGH
(480Mbps) pwr=ON (500mA)
ugen0.4:  at usbus0, cfg=0 md=HOST spd=FULL
(12Mbps) pwr=ON (100mA)
ugen0.3:  at usbus0, cfg=0 md=HOST spd=FULL
(12Mbps) pwr=ON (100mA)

# ll /usr/share/firmware/ath3k/ar3k/
total 384
drwxr-xr-x  2 serge  wheel512 17 лист.  2017 1020201coex/
-rw-r--r--  1 serge  wheel  55244 30 бер.   2017 AthrBT_0x01020001.dfu
-rw-r--r--  1 serge  wheel  40724 30 бер.   2017 AthrBT_0x01020200.dfu
-rw-r--r--  1 serge  wheel  48188 17 лист.  2017 AthrBT_0x01020201.dfu
-rw-r--r--  1 serge  wheel  36828 30 бер.   2017 AthrBT_0x1102.dfu
-rw-r--r--  1 serge  wheel  46852 30 бер.   2017 AthrBT_0x11020100.dfu
-rw-r--r--  1 serge  wheel  40652 30 бер.   2017 AthrBT_0x3101.dfu
-rw-r--r--  1 serge  wheel  37796 30 бер.   2017 AthrBT_0x31010100.dfu
-rw-r--r--  1 serge  wheel  31500 30 бер.   2017 AthrBT_0x4102.dfu
-rw-r--r--  1 serge  wheel   1224 30 бер.   2017 ramps_0x01020001_26.dfu
-rw-r--r--  1 serge  wheel   1274 30 бер.   2017 ramps_0x01020200_26.dfu
-rw-r--r--  1 serge  wheel   1204 30 бер.   2017 ramps_0x01020200_40.dfu
-rw-r--r--  1 serge  wheel264 30 бер.   2017 ramps_0x01020201_26.dfu
-rw-r--r--  1 serge  wheel264 30 бер.   2017 ramps_0x01020201_40.dfu
-rw-r--r--  1 serge  wheel   1796 30 бер.   2017 ramps_0x1102_40.dfu
-rw-r--r--  1 serge  wheel   1802 30 бер.   2017 ramps_0x11020100_40.dfu
-rw-r--r--  1 serge  wheel   1926 30 бер.   2017 ramps_0x3101_40.dfu
-rw-r--r--  1 serge  wheel   1922 30 бер.   2017 ramps_0x31010100_40.dfu
-rw-r--r--  1 serge  wheel   1820 30 бер.   2017 ramps_0x4102_40.dfu

And also i had to add the card to /usr/src/usr.sbin/bluetooth/ath3kfw

--- main.c.orig 2018-06-23 12:32:29.564631000 +0300
+++ main.c  2018-06-23 12:33:01.28340 +0300
@@ -85,6 +85,7 @@
{ .vendor_id = 0x0CF3, .product_id = 0x817a, .is_3012 = 1 },
{ .vendor_id = 0x0cf3, .product_id = 0xe004, .is_3012 = 1 },
{ .vendor_id = 0x0cf3, .product_id = 0xe005, .is_3012 = 1 },
+{ .vendor_id = 0x0cf3, .product_id = 0xe006, .is_3012 = 1 },
{ .vendor_id = 0x0cf3, .product_id = 0xe003, .is_3012 = 1 },
{ .vendor_id = 0x13d3, .product_id = 0x3362, .is_3012 = 1 },
{ .vendor_id = 0x13d3, .product_id = 0x3375, .is_3012 = 1 },
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-18 Thread Adrian Chadd
Hi!

Ok, I'm going to have to find my NIC and see what's going on.


-a


>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-18 Thread Matthias Apitz
El día Thursday, April 18, 2019 a las 07:02:38PM +0200, Matthias Apitz escribió:

> El día Thursday, April 18, 2019 a las 08:05:53AM -0700, Adrian Chadd escribió:
> 
> > that means it SHOULD be ready for normal HCI operation. bcdDevice=1 is what
> > the driver uses to determine if it's only in the boot ROM. Yours either got
> > it in a previous boot, or it has a ROM with the full firmware.
> 
> btw: I switched from ChromeOS in developer mode to boot FreeBSD from USB by
> 'reboot' and not by power-cycle. Maybe that's the reason why the
> firmware is still loaded.

Yes, when I do a power-off boot the result of loading the firmware is:

# ./ath3kfw -D -d ugen0.4 -f ~guru/ath3k/share/firmware/ath3k -I 2>&1 | tee log
ath3kfw: opening dev 0.4
ath3k_is_3012: found AR3012
main: state=0x0e
ath3k_load_fwfile: 
file=/home/guru/ath3k/share/firmware/ath3k/ar3k/AthrBT_0x1102.dfu, 
size=36828
ath3k_load_fwfile: transferring 4096 bytes, offset 20
ath3k_load_fwfile: transferring 4096 bytes, offset 4116
ath3k_load_fwfile: transferring 4096 bytes, offset 8212
ath3k_load_fwfile: transferring 4096 bytes, offset 12308
ath3k_load_fwfile: transferring 4096 bytes, offset 16404
ath3k_load_fwfile: transferring 4096 bytes, offset 20500
ath3k_load_fwfile: transferring 4096 bytes, offset 24596
ath3k_load_fwfile: transferring 4096 bytes, offset 28692
ath3k_load_fwfile: transferring 4040 bytes, offset 32788
ath3k_load_fwfile: 
file=/home/guru/ath3k/share/firmware/ath3k/ar3k/ramps_0x1102_40.dfu, 
size=1796
ath3k_load_fwfile: transferring 1776 bytes, offset 20
ROM version: 285343744, build version: 155, ram version: 155, ref clock=1
ath3k_load_patch: file 
/home/guru/ath3k/share/firmware/ath3k/ar3k/AthrBT_0x1102.dfu: 
rom_ver=285343744, build_ver=370
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_bulk_transfer leave
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_bulk_transfer leave
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_bulk_transfer leave
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_bulk_transfer leave
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_bulk_transfer leave
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_bulk_transfer leave
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_bulk_transfer leave
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb

Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-18 Thread Adrian Chadd
hi,

On Thu, 18 Apr 2019 at 10:02, Matthias Apitz  wrote:

> El día Thursday, April 18, 2019 a las 08:05:53AM -0700, Adrian Chadd
> escribió:
>
> > that means it SHOULD be ready for normal HCI operation. bcdDevice=1 is
> what
> > the driver uses to determine if it's only in the boot ROM. Yours either
> got
> > it in a previous boot, or it has a ROM with the full firmware.
>
> btw: I switched from ChromeOS in developer mode to boot FreeBSD from USB by
> 'reboot' and not by power-cycle. Maybe that's the reason why the
> firmware is still loaded.
>
> > Try starting bluetooth now and do an inquiry.
>
> # grep ubt0 /var/log/messages
>
> Apr 18 14:29:46 c720-r342378-usb kernel: ubt0 on uhub1
>
>
> Apr 18 14:29:46 c720-r342378-usb kernel: ubt0:  0xe056, class 224/1, rev 1.10/0.02, addr 3> on usbus0
>
> # service bluetooth start ubt0
>
> /etc/rc.d/bluetooth: ERROR: Unable to setup Bluetooth stack for device
> ubt0
>
> # /etc/rc.d/hcsecd onestart
>
> Starting hcsecd.
>
>
> # service bluetooth start ubt0
>
> ng_hci_process_command_timeout: ubt0hci - unable to complete HCI command
> OGF=0x3, OCF=0x3. Timeout
>
> /etc/rc.d/bluetooth: ERROR: Unable to setup Bluetooth stack for device ubt0
>
> anything else to test?
>

not for now. I'll try testing it on an older device where it's connected
via USB 2.0 and see what happens.

Thanks,


-a


> matthias
> --
> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
> +49-176-38902045
> Public GnuPG key: http://www.unixarea.de/key.pub
> 70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...)
> and 70 years
> of war preparation against Russia.  -- PEACE instead of NATO !
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-18 Thread Matthias Apitz
El día Thursday, April 18, 2019 a las 08:05:53AM -0700, Adrian Chadd escribió:

> that means it SHOULD be ready for normal HCI operation. bcdDevice=1 is what
> the driver uses to determine if it's only in the boot ROM. Yours either got
> it in a previous boot, or it has a ROM with the full firmware.

btw: I switched from ChromeOS in developer mode to boot FreeBSD from USB by
'reboot' and not by power-cycle. Maybe that's the reason why the
firmware is still loaded.

> Try starting bluetooth now and do an inquiry.

# grep ubt0 /var/log/messages   
  
Apr 18 14:29:46 c720-r342378-usb kernel: ubt0 on uhub1  

  
Apr 18 14:29:46 c720-r342378-usb kernel: ubt0:  on usbus0   

# service bluetooth start ubt0  
  
/etc/rc.d/bluetooth: ERROR: Unable to setup Bluetooth stack for device ubt0 

  
# /etc/rc.d/hcsecd onestart 
  
Starting hcsecd.

  
# service bluetooth start ubt0  
  
ng_hci_process_command_timeout: ubt0hci - unable to complete HCI command 
OGF=0x3, OCF=0x3. Timeout   
 
/etc/rc.d/bluetooth: ERROR: Unable to setup Bluetooth stack for device ubt0

anything else to test?

matthias
-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...) and 
70 years
of war preparation against Russia.  -- PEACE instead of NATO !
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-18 Thread Adrian Chadd
that means it SHOULD be ready for normal HCI operation. bcdDevice=1 is what
the driver uses to determine if it's only in the boot ROM. Yours either got
it in a previous boot, or it has a ROM with the full firmware.

Try starting bluetooth now and do an inquiry.


-a


On Thu, 18 Apr 2019 at 08:03, Alexey Dokuchaev  wrote:

> On Thu, Apr 18, 2019 at 07:58:34AM -0700, Adrian Chadd wrote:
> > Ok, so it found and loaded in the bluetooth firmware into the
> > bluetooth NIC RAM.
>
> Why do you think so?
>
> > On Thu, 18 Apr 2019 at 07:50, Matthias Apitz  wrote:
> > >
> > > I have booted the other C720 from USB and here are the results:
> > >
> > > # ./ath3kfw -D -d ugen0.4 -I
> > > ath3kfw: opening dev 0.4
> > > ath3k_is_3012: found AR3012
> > > main: AR3012; bcdDevice=2, exiting
>
> /* See if its an AR3012 */
> if (ath3k_is_3012(&d)) {
> is_3012 = 1;
>
> /* If it's bcdDevice > 1, don't attach */
> if (d.bcdDevice > 0x0001) {
> ath3k_debug("%s: AR3012; bcdDevice=%d, exiting\n",
> __func__,
> d.bcdDevice);
> exit(0);
> }
> }
>
> It looks to me it never reached the stage of loading the firmware because
> of bcdDevice=2.
>
> ./danfe
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-18 Thread Alexey Dokuchaev
On Thu, Apr 18, 2019 at 07:58:34AM -0700, Adrian Chadd wrote:
> Ok, so it found and loaded in the bluetooth firmware into the
> bluetooth NIC RAM.

Why do you think so?

> On Thu, 18 Apr 2019 at 07:50, Matthias Apitz  wrote:
> >
> > I have booted the other C720 from USB and here are the results:
> >
> > # ./ath3kfw -D -d ugen0.4 -I
> > ath3kfw: opening dev 0.4
> > ath3k_is_3012: found AR3012
> > main: AR3012; bcdDevice=2, exiting

/* See if its an AR3012 */
if (ath3k_is_3012(&d)) {
is_3012 = 1;

/* If it's bcdDevice > 1, don't attach */
if (d.bcdDevice > 0x0001) {
ath3k_debug("%s: AR3012; bcdDevice=%d, exiting\n",
__func__,
d.bcdDevice);
exit(0);
}
}

It looks to me it never reached the stage of loading the firmware because
of bcdDevice=2.

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-18 Thread Adrian Chadd
Ok, so it found and loaded in the bluetooth firmware into the bluetooth NIC
RAM.

https://www.freebsd.org/doc/handbook/network-bluetooth.html

Your goal is to have devices show up in in an inquiry command.


-a



On Thu, 18 Apr 2019 at 07:50, Matthias Apitz  wrote:

>
> I have booted the other C720 from USB and here are the results:
>
>
> root@c720-r342378-usb:~guru/ath3k/src/usr.bin/ath3k # grep ath dmesg*
> ath0:  mem 0xe040-0xe047 at device 0.0 on
> pci1
> ath0: Enabling WB222 BTCOEX
> ath0: [HT] enabling HT modes
> ath0: [HT] enabling short-GI in 20MHz mode
> ath0: [HT] 1 stream STBC receive enabled
> ath0: [HT] 1 stream STBC transmit enabled
> ath0: [HT] LDPC transmit/receive enabled
> ath0: [HT] 2 RX streams; 2 TX streams
> ath0: AR9460 mac 640.2 RF5110 phy 1638.6
> ath0: 2GHz radio: 0x; 5GHz radio: 0x
>
>
> root@c720-r342378-usb:~guru/ath3k/src/usr.bin/ath3k # usbconfig
> ugen1.1:  at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps)
> pwr=SAVE (0mA)
> ugen0.1: <0x8086 XHCI root HUB> at usbus0, cfg=0 md=HOST spd=SUPER
> (5.0Gbps) pwr=SAVE (0mA)
> ugen0.2:  at usbus0, cfg=0 md=HOST spd=HIGH
> (480Mbps) pwr=ON (200mA)
> ugen1.2:  at usbus1, cfg=0 md=HOST spd=HIGH
> (480Mbps) pwr=SAVE (0mA)
> ugen0.3:  at usbus0, cfg=0 md=HOST spd=HIGH
> (480Mbps) pwr=ON (500mA)
> ugen0.4:  at usbus0, cfg=0 md=HOST spd=FULL
> (12Mbps) pwr=ON (100mA)
> root@c720-r342378-usb:~guru/ath3k/src/usr.bin/ath3k # ./ath3kfw -D -d
> ugen0.4 -I
> ath3kfw: opening dev 0.4
> ath3k_is_3012: found AR3012
> main: AR3012; bcdDevice=2, exiting
>
> attached is the full output of 'dmesg'
>
> And now?
>
> matthias
>
> --
> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
> +49-176-38902045
> Public GnuPG key: http://www.unixarea.de/key.pub
> 70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...)
> and 70 years
> of war preparation against Russia.  -- PEACE instead of NATO !
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-18 Thread Matthias Apitz

I have booted the other C720 from USB and here are the results:


root@c720-r342378-usb:~guru/ath3k/src/usr.bin/ath3k # grep ath dmesg*
ath0:  mem 0xe040-0xe047 at device 0.0 on pci1
ath0: Enabling WB222 BTCOEX
ath0: [HT] enabling HT modes
ath0: [HT] enabling short-GI in 20MHz mode
ath0: [HT] 1 stream STBC receive enabled
ath0: [HT] 1 stream STBC transmit enabled
ath0: [HT] LDPC transmit/receive enabled
ath0: [HT] 2 RX streams; 2 TX streams
ath0: AR9460 mac 640.2 RF5110 phy 1638.6
ath0: 2GHz radio: 0x; 5GHz radio: 0x


root@c720-r342378-usb:~guru/ath3k/src/usr.bin/ath3k # usbconfig
ugen1.1:  at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps) 
pwr=SAVE (0mA)
ugen0.1: <0x8086 XHCI root HUB> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) 
pwr=SAVE (0mA)
ugen0.2:  at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) 
pwr=ON (200mA)
ugen1.2:  at usbus1, cfg=0 md=HOST spd=HIGH 
(480Mbps) pwr=SAVE (0mA)
ugen0.3:  at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) 
pwr=ON (500mA)
ugen0.4:  at usbus0, cfg=0 md=HOST spd=FULL 
(12Mbps) pwr=ON (100mA)
root@c720-r342378-usb:~guru/ath3k/src/usr.bin/ath3k # ./ath3kfw -D -d ugen0.4 -I
ath3kfw: opening dev 0.4
ath3k_is_3012: found AR3012
main: AR3012; bcdDevice=2, exiting

attached is the full output of 'dmesg'

And now?

matthias

-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...) and 
70 years
of war preparation against Russia.  -- PEACE instead of NATO !
---<>---
Copyright (c) 1992-2018 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 13.0-CURRENT GENERIC amd64
FreeBSD clang version 7.0.1 (tags/RELEASE_701/final 349250) (based on LLVM 
7.0.1)
WARNING: WITNESS option enabled, expect reduced performance.
VT(vga): resolution 640x480
CPU: Intel(R) Celeron(R) 2955U @ 1.40GHz (1396.80-MHz K8-class CPU)
  Origin="GenuineIntel"  Id=0x40651  Family=0x6  Model=0x45  Stepping=1
  
Features=0xbfebfbff
  
Features2=0x4ddaebbf
  AMD Features=0x2c100800
  AMD Features2=0x21
  Structured Extended Features=0x2603
  XSAVE Features=0x1
  VT-x: (disabled in BIOS) PAT,HLT,MTF,PAUSE,EPT,UG,VPID
  TSC: P-state invariant, performance statistics
real memory  = 4301258752 (4102 MB)
avail memory = 1917231104 (1828 MB)
Event timer "LAPIC" quality 600
ACPI APIC Table: 
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
FreeBSD/SMP: 1 package(s) x 2 core(s)
random: unblocking device.
ioapic0  irqs 0-39 on motherboard
Launching APs: 1
Timecounter "TSC" frequency 1396798980 Hz quality 1000
Cuse v0.1.35 @ /dev/cuse
random: entropy device external interface
[ath_hal] loaded
kbd1 at kbdmux0
module_register_init: MOD_LOAD (vesa, 0x81124550, 0) error 19
random: registering fast source Intel Secure Key RNG
random: fast provider: "Intel Secure Key RNG"
000.52 [4184] netmap_init   netmap: loaded module
nexus0
vtvga0:  on motherboard
cryptosoft0:  on motherboard
acpi0:  on motherboard
acpi0: Power Button (fixed)
hpet0:  iomem 0xfed0-0xfed003ff on acpi0
Timecounter "HPET" frequency 14318180 Hz quality 950
Event timer "HPET" frequency 14318180 Hz quality 550
Event timer "HPET1" frequency 14318180 Hz quality 440
Event timer "HPET2" frequency 14318180 Hz quality 440
Event timer "HPET3" frequency 14318180 Hz quality 440
Event timer "HPET4" frequency 14318180 Hz quality 440
Event timer "HPET5" frequency 14318180 Hz quality 440
Event timer "HPET6" frequency 14318180 Hz quality 440
cpu0:  on acpi0
atrtc0:  port 0x70-0x77 on acpi0
atrtc0: registered as a time-of-day clock, resolution 1.00s
Event timer "RTC" frequency 32768 Hz quality 0
attimer0:  port 0x40-0x43,0x50-0x53 irq 0 on acpi0
Timecounter "i8254" frequency 1193182 Hz quality 0
Event timer "i8254" frequency 1193182 Hz quality 100
Timecounter "ACPI-fast" frequency 3579545 Hz quality 900
acpi_timer0: <24-bit timer at 3.579545MHz> port 0x1008-0x100b on acpi0
acpi_ec0:  port 0x62,0x66 on acpi0
acpi_lid0:  on acpi0
acpi_button0:  on acpi0
acpi_button1:  irq 37 on acpi0
acpi_button2:  irq 38 on acpi0
pcib0:  port 0xcf8-0xcff on acpi0
pci0:  on pcib0
vgapci0:  port 0x1800-0x183f mem 
0xe000-0xe03f,0xd000-0xdfff at device 2.0 on pci0
vgapci0: Boot video device
hdac0:  mem 0xe051-0xe0513fff at device 3.0 
on pci0
xhci0:  mem 0xe050-0xe050 at 
device 20.0 on pci0
xhci0: 32 bytes context size, 64-bit DMA
xhci0: Port routing mask set to 0x
usbus0 on xhci0
usbus0: 5.0Gbps Super Speed USB v3.0
pci0:  at device 21.0 (no driver attached)
ig4iic_pci0:  mem 
0xe051a000-0xe051afff,0xe051b000-0xe051bfff at device 21.1 on pci0
ig4iic_pci0: Using MSI
ig4iic_pci1:  mem 
0xe051c000-0xe051cfff,0xe051d000-0xe051dfff at device 21.2 on pci0
ig4iic_pci1: Using MSI
hdac1:  mem 0xe0514000-

Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-17 Thread Adrian Chadd
Try loading firmware, see if it can do a bt scan.

Try also bringing up the 2g wifi and connect to a 2g station; see if that
also allows a bt scan to work.


-a


On Wed, 17 Apr 2019 at 11:17, Matthias Apitz  wrote:

> Am Mittwoch, 17. April 2019 19:59:17 CEST schrieb Adrian Chadd
> :
> > no flashing occurs. it's running out of ram on the chip.
> >
> >
> > -a
>
> So, what do you want me to test exactly?
>
> ma
>
>
>
> --
> Sent from my Ubuntu phone
> http://www.unixarea.de/
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-17 Thread Matthias Apitz
Am Mittwoch, 17. April 2019 19:59:17 CEST schrieb Adrian Chadd 
:

no flashing occurs. it's running out of ram on the chip.


-a


So, what do you want me to test exactly?

ma



--
Sent from my Ubuntu phone
http://www.unixarea.de/
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-17 Thread Adrian Chadd
no flashing occurs. it's running out of ram on the chip.


-a


On Wed, 17 Apr 2019 at 10:56, Matthias Apitz  wrote:

> Am Mittwoch, 17. April 2019 18:59:08 CEST schrieb Adrian Chadd
> :
> > Did you copy it into /usr/share/ or did you pass the command line arg in
> to
> > set the base directory? :)
> >
>
> I was aware of the flag -f to specify the dir or file of the
> firmware to use. I did not set this by intention to *not* flash
> the firmware into the chip.
>
> I misinterpreted the flag -I thinking that this is only for read
> and not flash. But it is meant like verbose what the tool is
> doing.
>
> Meanwhile I produced already a system on an USB key and
> when I have time on Eastern I will test the tool on the other
> C720 I have and which at the moment is only collecting dust.
>
> Stay tuned for the result or more questions.
>
> matthias
>
>
>
>
> --
> Sent from my Ubuntu phone
> http://www.unixarea.de/
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-17 Thread Matthias Apitz
Am Mittwoch, 17. April 2019 18:59:08 CEST schrieb Adrian Chadd 
:

Did you copy it into /usr/share/ or did you pass the command line arg in to
set the base directory? :)



I was aware of the flag -f to specify the dir or file of the
firmware to use. I did not set this by intention to *not* flash
the firmware into the chip.

I misinterpreted the flag -I thinking that this is only for read
and not flash. But it is meant like verbose what the tool is
doing.

Meanwhile I produced already a system on an USB key and
when I have time on Eastern I will test the tool on the other
C720 I have and which at the moment is only collecting dust.

Stay tuned for the result or more questions.

matthias




--
Sent from my Ubuntu phone
http://www.unixarea.de/
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-17 Thread Adrian Chadd
Did you copy it into /usr/share/ or did you pass the command line arg in to
set the base directory? :)


-a


On Wed, 17 Apr 2019 at 09:57, Matthias Apitz  wrote:

> El día Wednesday, April 17, 2019 a las 02:35:51PM +, Alexey Dokuchaev
> escribió:
>
> > On Tue, Apr 16, 2019 at 12:34:12PM +0200, Matthias Apitz wrote:
> > > # ./ath3kfw -D -d ugen0.3 -I
> > > ath3kfw: opening dev 0.3
> > > ath3k_is_3012: found AR3012
> > > main: state=0x0e
> > > ROM version: 285343744, build version: 155, ram version: 155, ref
> clock=1
> > > ath3kfw: ath3k_fw_read: open:
> /usr/share/firmware/ath3k//ar3k/AthrBT_0x1102.dfu: No such file or
> directory
> >
> > OK, so the file is not in the right place (as indicated by this message).
> >
> > > ath3k_load_patch: ath3k_fw_read() failed
> > > Loading patch file failed
> > >
> > > The ROM version: 285343744 does not look like something meaningful,
> > > maybe the tool reads the wrong place.
> >
> > It is meaningful and correct, it is just printed in decimal which is
> > probably bogus:
> >
> > $ echo 16 o 285343744 p | dc
> > 1102
>
> Yep. The printf should be corrected to something like %08x.
>
> > > Which file I should use from ath3k/share/firmware/ath3k
> > > # ls -C1
> > > ar3k
> > > ath3k-1.fw
> > > LICENCE.atheros_firmware
> > >
> > > below ar3k/ are a lot more files 
> >
> > Is there AthrBT_0x1102.dfu amongst them?  Try placing it under
> > /usr/share/firmware/ath3k/ar3k/ and repeat the procedure.
>
> We have the following files there:
>
> $ find firmware/
>
>
> firmware/ath3k
> firmware/ath3k/LICENCE.atheros_firmware
> firmware/ath3k/ar3k
> firmware/ath3k/ar3k/1020200
> firmware/ath3k/ar3k/1020200/PS_ASIC.pst
> firmware/ath3k/ar3k/1020200/RamPatch.txt
> firmware/ath3k/ar3k/1020200/ar3kbdaddr.pst
> firmware/ath3k/ar3k/1020201
> firmware/ath3k/ar3k/1020201/PS_ASIC.pst
> firmware/ath3k/ar3k/1020201/RamPatch.txt
> firmware/ath3k/ar3k/3
> firmware/ath3k/ar3k/3/PS_ASIC.pst
> firmware/ath3k/ar3k/3/RamPatch.txt
> firmware/ath3k/ar3k/3/ar3kbdaddr.pst
> firmware/ath3k/ar3k/30101
> firmware/ath3k/ar3k/30101/PS_ASIC.pst
> firmware/ath3k/ar3k/30101/RamPatch.txt
> firmware/ath3k/ar3k/30101/ar3kbdaddr.pst
> firmware/ath3k/ar3k/30101coex
> firmware/ath3k/ar3k/30101coex/PS_ASIC.pst
> firmware/ath3k/ar3k/30101coex/PS_ASIC_aclHighPri.pst
> firmware/ath3k/ar3k/30101coex/PS_ASIC_aclLowPri.pst
> firmware/ath3k/ar3k/30101coex/RamPatch.txt
> firmware/ath3k/ar3k/30101coex/ar3kbdaddr.pst
> firmware/ath3k/ar3k/AthrBT_0x01020001.dfu
> firmware/ath3k/ar3k/AthrBT_0x01020200.dfu
> firmware/ath3k/ar3k/AthrBT_0x01020201.dfu
> firmware/ath3k/ar3k/AthrBT_0x1102.dfu<*** !!!
> firmware/ath3k/ar3k/AthrBT_0x3101.dfu
> firmware/ath3k/ar3k/ramps_0x01020001_26.dfu
> firmware/ath3k/ar3k/ramps_0x01020200_26.dfu
> firmware/ath3k/ar3k/ramps_0x01020200_40.dfu
> firmware/ath3k/ar3k/ramps_0x01020201_26.dfu
> firmware/ath3k/ar3k/ramps_0x01020201_40.dfu
> firmware/ath3k/ar3k/ramps_0x1102_40.dfu
> firmware/ath3k/ar3k/ramps_0x3101_40.dfu
> firmware/ath3k/ath3k-1.fw
>
>
> --
> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
> +49-176-38902045
> Public GnuPG key: http://www.unixarea.de/key.pub
> 70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...)
> and 70 years
> of war preparation against Russia.  -- PEACE instead of NATO !
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-17 Thread Matthias Apitz
El día Wednesday, April 17, 2019 a las 02:35:51PM +, Alexey Dokuchaev 
escribió:

> On Tue, Apr 16, 2019 at 12:34:12PM +0200, Matthias Apitz wrote:
> > # ./ath3kfw -D -d ugen0.3 -I
> > ath3kfw: opening dev 0.3
> > ath3k_is_3012: found AR3012
> > main: state=0x0e
> > ROM version: 285343744, build version: 155, ram version: 155, ref clock=1
> > ath3kfw: ath3k_fw_read: open: 
> > /usr/share/firmware/ath3k//ar3k/AthrBT_0x1102.dfu: No such file or 
> > directory
> 
> OK, so the file is not in the right place (as indicated by this message).
> 
> > ath3k_load_patch: ath3k_fw_read() failed
> > Loading patch file failed
> > 
> > The ROM version: 285343744 does not look like something meaningful,
> > maybe the tool reads the wrong place.
> 
> It is meaningful and correct, it is just printed in decimal which is
> probably bogus:
> 
> $ echo 16 o 285343744 p | dc
> 1102

Yep. The printf should be corrected to something like %08x.

> > Which file I should use from ath3k/share/firmware/ath3k
> > # ls -C1
> > ar3k
> > ath3k-1.fw
> > LICENCE.atheros_firmware
> > 
> > below ar3k/ are a lot more files 
> 
> Is there AthrBT_0x1102.dfu amongst them?  Try placing it under
> /usr/share/firmware/ath3k/ar3k/ and repeat the procedure.

We have the following files there:

$ find firmware/

  
firmware/ath3k
firmware/ath3k/LICENCE.atheros_firmware
firmware/ath3k/ar3k
firmware/ath3k/ar3k/1020200
firmware/ath3k/ar3k/1020200/PS_ASIC.pst
firmware/ath3k/ar3k/1020200/RamPatch.txt
firmware/ath3k/ar3k/1020200/ar3kbdaddr.pst
firmware/ath3k/ar3k/1020201
firmware/ath3k/ar3k/1020201/PS_ASIC.pst
firmware/ath3k/ar3k/1020201/RamPatch.txt
firmware/ath3k/ar3k/3
firmware/ath3k/ar3k/3/PS_ASIC.pst
firmware/ath3k/ar3k/3/RamPatch.txt
firmware/ath3k/ar3k/3/ar3kbdaddr.pst
firmware/ath3k/ar3k/30101
firmware/ath3k/ar3k/30101/PS_ASIC.pst
firmware/ath3k/ar3k/30101/RamPatch.txt
firmware/ath3k/ar3k/30101/ar3kbdaddr.pst
firmware/ath3k/ar3k/30101coex
firmware/ath3k/ar3k/30101coex/PS_ASIC.pst
firmware/ath3k/ar3k/30101coex/PS_ASIC_aclHighPri.pst
firmware/ath3k/ar3k/30101coex/PS_ASIC_aclLowPri.pst
firmware/ath3k/ar3k/30101coex/RamPatch.txt
firmware/ath3k/ar3k/30101coex/ar3kbdaddr.pst
firmware/ath3k/ar3k/AthrBT_0x01020001.dfu
firmware/ath3k/ar3k/AthrBT_0x01020200.dfu
firmware/ath3k/ar3k/AthrBT_0x01020201.dfu
firmware/ath3k/ar3k/AthrBT_0x1102.dfu<*** !!!
firmware/ath3k/ar3k/AthrBT_0x3101.dfu
firmware/ath3k/ar3k/ramps_0x01020001_26.dfu
firmware/ath3k/ar3k/ramps_0x01020200_26.dfu
firmware/ath3k/ar3k/ramps_0x01020200_40.dfu
firmware/ath3k/ar3k/ramps_0x01020201_26.dfu
firmware/ath3k/ar3k/ramps_0x01020201_40.dfu
firmware/ath3k/ar3k/ramps_0x1102_40.dfu
firmware/ath3k/ar3k/ramps_0x3101_40.dfu
firmware/ath3k/ath3k-1.fw


-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...) and 
70 years
of war preparation against Russia.  -- PEACE instead of NATO !
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-17 Thread Alexey Dokuchaev
On Tue, Apr 16, 2019 at 12:34:12PM +0200, Matthias Apitz wrote:
> # ./ath3kfw -D -d ugen0.3 -I
> ath3kfw: opening dev 0.3
> ath3k_is_3012: found AR3012
> main: state=0x0e
> ROM version: 285343744, build version: 155, ram version: 155, ref clock=1
> ath3kfw: ath3k_fw_read: open: 
> /usr/share/firmware/ath3k//ar3k/AthrBT_0x1102.dfu: No such file or 
> directory

OK, so the file is not in the right place (as indicated by this message).

> ath3k_load_patch: ath3k_fw_read() failed
> Loading patch file failed
> 
> The ROM version: 285343744 does not look like something meaningful,
> maybe the tool reads the wrong place.

It is meaningful and correct, it is just printed in decimal which is
probably bogus:

$ echo 16 o 285343744 p | dc
1102

> Which file I should use from ath3k/share/firmware/ath3k
> # ls -C1
> ar3k
> ath3k-1.fw
> LICENCE.atheros_firmware
> 
> below ar3k/ are a lot more files 

Is there AthrBT_0x1102.dfu amongst them?  Try placing it under
/usr/share/firmware/ath3k/ar3k/ and repeat the procedure.

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-16 Thread Matthias Apitz
El día lunes, abril 15, 2019 a las 05:35:03p. m. +, Alexey Dokuchaev 
escribió:

> Ah, OK, I understand.  Anyways, now that this little confusion is resolved,
> could you try to upload the firmware using this tool?  For me it didn't
> work, but that might be because of the particular hardware (USB 3.0/xHCI).
> I don't know about C720, but it can be sufficiently different so ath3kfw
> would work on it.  This is very important to understand our next course of
> action.  Thanks,

I did:

# usbconfig list | grep 0xe056
ugen0.3:  at usbus0, cfg=0 md=HOST spd=FULL 
(12Mbps) pwr=ON (100mA)

# ./ath3kfw -D -d ugen0.3 -I
ath3kfw: opening dev 0.3
ath3k_is_3012: found AR3012
main: state=0x0e
ROM version: 285343744, build version: 155, ram version: 155, ref clock=1
ath3kfw: ath3k_fw_read: open: 
/usr/share/firmware/ath3k//ar3k/AthrBT_0x1102.dfu: No such file or directory
ath3k_load_patch: ath3k_fw_read() failed
Loading patch file failed

The ROM version: 285343744 does not look like something meaningful,
maybe the tool reads the wrong place.

Which file I should use from ath3k/share/firmware/ath3k
# ls -C1
ar3k
ath3k-1.fw
LICENCE.atheros_firmware

below ar3k/ are a lot more files 

As I said, I need this C720 for real work and can't risk to brick the
chip. I have another C720 at home collecting dust which still runs
ChromeOS. I will prepare an USB key to boot from and use this for test.
Please give me some days.

matthias

-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...) and 
70 years
of war preparation against Russia.  -- PEACE instead of NATO !!!
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-15 Thread Adrian Chadd
i thought i had the various combinations working when i last poked at this
stuff. I'll have to go re-test it all.


-a


On Mon, 15 Apr 2019 at 10:35, Alexey Dokuchaev  wrote:

> On Mon, Apr 15, 2019 at 02:52:17PM +0200, Matthias Apitz wrote:
> > I have not missed (or deleted) any mail in this thread of 24++ mails.
> > But as Adrian said "Does ath3k load OK?" I was confused and thinking
> > in a loadable kernel module.
>
> Ah, OK, I understand.  Anyways, now that this little confusion is resolved,
> could you try to upload the firmware using this tool?  For me it didn't
> work, but that might be because of the particular hardware (USB 3.0/xHCI).
> I don't know about C720, but it can be sufficiently different so ath3kfw
> would work on it.  This is very important to understand our next course of
> action.  Thanks,
>
> ./danfe
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-15 Thread Alexey Dokuchaev
On Mon, Apr 15, 2019 at 02:52:17PM +0200, Matthias Apitz wrote:
> I have not missed (or deleted) any mail in this thread of 24++ mails.
> But as Adrian said "Does ath3k load OK?" I was confused and thinking
> in a loadable kernel module.

Ah, OK, I understand.  Anyways, now that this little confusion is resolved,
could you try to upload the firmware using this tool?  For me it didn't
work, but that might be because of the particular hardware (USB 3.0/xHCI).
I don't know about C720, but it can be sufficiently different so ath3kfw
would work on it.  This is very important to understand our next course of
action.  Thanks,

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-15 Thread Matthias Apitz
El día lunes, abril 15, 2019 a las 12:26:52p. m. +, Alexey Dokuchaev 
escribió:

> I've posted exact instructions how to use it and debug log earlier in
> this thread, you being CC'ed, I don't understand how could you've missed
> those emails.

I have not missed (or deleted) any mail in this thread of 24++ mails. But as 
Adrian
said "Does ath3k load OK?" I was confused and thinking in a loadable
kernel module. Sorry.

matthias
-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...) and 
70 years
of war preparation against Russia.  -- PEACE instead of NATO !!!
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-15 Thread Alexey Dokuchaev
On Sat, Apr 13, 2019 at 12:35:30PM -0700, Adrian Chadd wrote:
> On Sat, 13 Apr 2019 at 12:14, Alexey Dokuchaev wrote:
> > ...
> > If you tell me how to implement Linuxish usleep_range() correctly in
> > our userland, I can do that. :-)
> 
> usleep_range() is just the same as usleep() at either min, max or a value
> in between. It's just a hint to the scheduler that says "look, don't sleep
> exactly for this amount of time to wake me up; here are my bounds that are
> fine so if you schedule something else before then don't forget about me."

I understand, and it makes sense to give hints to the scheduler from the
kernel side, but less so when calling uslee() from userland.

> Just pick a value in between. :-)

Oh well, maybe that'll do.

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-15 Thread Alexey Dokuchaev
On Mon, Apr 15, 2019 at 06:48:36AM +0200, Matthias Apitz wrote:
> I git cloned it and built it, but this does not give any kernel module
> to load: [...]
> 
> $ ./ath3kfw
> Usage: ath3kfw (-D) -d ugenX.Y (-f firmware path) (-I)
> -D: enable debugging
> -d: device to operate upon
> -f: firmware path, if not default
> -I: enable informational output
> 
> What next? Will it brick my Wifi chip? I need this C720 for work. :-)

No, it should not brick your chip (well, at least it didn't brick mine,
even that it didn't manage to load the firmware correctly and left the
chip in a bogus state, but reboot seems to cure it).

I've posted exact instructions how to use it and debug log earlier in
this thread, you being CC'ed, I don't understand how could you've missed
those emails.

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-14 Thread Adrian Chadd
it's a userland program. :-) All ath3k in linux does is detect the hardware
and squeeze firmware into it. That's literally it.


-adrian

On Sun, 14 Apr 2019 at 21:48, Matthias Apitz  wrote:

> El día domingo, abril 14, 2019 a las 09:42:46a. m. -0700, Adrian Chadd
> escribió:
>
> > no, it's the userland ath3kfw tool from my git (github.com/erikarn/ath3k
> )
> >
> > Those NICs need firmware/config squirted onto them after ath(4) loads and
> > sets up the btcoex.
> >
> >
>
> I git cloned it and built it, but this does not give any kernel module
> to load:
>
> $ ls -ltr
> total 208
> -rw-r--r--  1 guru  wheel164 15 abr.  06:27 Makefile
> -rw-r--r--  1 guru  wheel   1828 15 abr.  06:27 ath3k_dbg.h
> -rw-r--r--  1 guru  wheel   2857 15 abr.  06:27 ath3k_fw.c
> -rw-r--r--  1 guru  wheel   2066 15 abr.  06:27 ath3k_fw.h
> -rw-r--r--  1 guru  wheel   7928 15 abr.  06:27 ath3k_hw.c
> -rw-r--r--  1 guru  wheel   2641 15 abr.  06:27 ath3k_hw.h
> -rw-r--r--  1 guru  wheel  10183 15 abr.  06:27 main.c
> -rw-r--r--  1 guru  wheel  21856 15 abr.  06:29 main.o
> -rw-r--r--  1 guru  wheel   9824 15 abr.  06:29 ath3k_fw.o
> -rw-r--r--  1 guru  wheel  18592 15 abr.  06:29 ath3k_hw.o
> -rwxr-xr-x  1 guru  wheel  52096 15 abr.  06:29 ath3kfw.full
> -rwxr-xr-x  1 guru  wheel  31312 15 abr.  06:29 ath3kfw.debug
> -rwxr-xr-x  1 guru  wheel  27648 15 abr.  06:29 ath3kfw
> $ ./ath3kfw
> Usage: ath3kfw (-D) -d ugenX.Y (-f firmware path) (-I)
> -D: enable debugging
> -d: device to operate upon
> -f: firmware path, if not default
> -I: enable informational output
>
> What next? Will it brick my Wifi chip? I need this C720 for work. :-)
>
> --
> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
> +49-176-38902045
> Public GnuPG key: http://www.unixarea.de/key.pub
> 70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...)
> and 70 years
> of war preparation against Russia.  -- PEACE instead of NATO !!!
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-14 Thread Matthias Apitz
El día domingo, abril 14, 2019 a las 09:42:46a. m. -0700, Adrian Chadd escribió:

> no, it's the userland ath3kfw tool from my git (github.com/erikarn/ath3k)
> 
> Those NICs need firmware/config squirted onto them after ath(4) loads and
> sets up the btcoex.
> 
> 

I git cloned it and built it, but this does not give any kernel module
to load:

$ ls -ltr
total 208
-rw-r--r--  1 guru  wheel164 15 abr.  06:27 Makefile
-rw-r--r--  1 guru  wheel   1828 15 abr.  06:27 ath3k_dbg.h
-rw-r--r--  1 guru  wheel   2857 15 abr.  06:27 ath3k_fw.c
-rw-r--r--  1 guru  wheel   2066 15 abr.  06:27 ath3k_fw.h
-rw-r--r--  1 guru  wheel   7928 15 abr.  06:27 ath3k_hw.c
-rw-r--r--  1 guru  wheel   2641 15 abr.  06:27 ath3k_hw.h
-rw-r--r--  1 guru  wheel  10183 15 abr.  06:27 main.c
-rw-r--r--  1 guru  wheel  21856 15 abr.  06:29 main.o
-rw-r--r--  1 guru  wheel   9824 15 abr.  06:29 ath3k_fw.o
-rw-r--r--  1 guru  wheel  18592 15 abr.  06:29 ath3k_hw.o
-rwxr-xr-x  1 guru  wheel  52096 15 abr.  06:29 ath3kfw.full
-rwxr-xr-x  1 guru  wheel  31312 15 abr.  06:29 ath3kfw.debug
-rwxr-xr-x  1 guru  wheel  27648 15 abr.  06:29 ath3kfw
$ ./ath3kfw
Usage: ath3kfw (-D) -d ugenX.Y (-f firmware path) (-I)
-D: enable debugging
-d: device to operate upon
-f: firmware path, if not default
-I: enable informational output

What next? Will it brick my Wifi chip? I need this C720 for work. :-)

-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...) and 
70 years
of war preparation against Russia.  -- PEACE instead of NATO !!!


signature.asc
Description: PGP signature


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-14 Thread Adrian Chadd
no, it's the userland ath3kfw tool from my git (github.com/erikarn/ath3k)

Those NICs need firmware/config squirted onto them after ath(4) loads and
sets up the btcoex.


-adrian

On Sun, 14 Apr 2019 at 09:38, Matthias Apitz  wrote:

> El día domingo, abril 14, 2019 a las 09:18:18a. m. -0700, Adrian Chadd
> escribió:
>
> > ok, so you've added the WB222 coex bits. Does ath3k load OK?
> >
>
> I do not have this module:
>
> root@c720-r342378:/home/guru # uname -a
> FreeBSD c720-r342378 13.0-CURRENT FreeBSD 13.0-CURRENT GENERIC  amd64
> root@c720-r342378:/home/guru # find /boot/ | grep -i ath3
> root@c720-r342378:/home/guru #
>
> matthias
>
>
> --
> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
> +49-176-38902045
> Public GnuPG key: http://www.unixarea.de/key.pub
> 70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...)
> and 70 years
> of war preparation against Russia.  -- PEACE instead of NATO !!!
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-14 Thread Matthias Apitz
El día domingo, abril 14, 2019 a las 09:18:18a. m. -0700, Adrian Chadd escribió:

> ok, so you've added the WB222 coex bits. Does ath3k load OK?
> 

I do not have this module:

root@c720-r342378:/home/guru # uname -a
FreeBSD c720-r342378 13.0-CURRENT FreeBSD 13.0-CURRENT GENERIC  amd64
root@c720-r342378:/home/guru # find /boot/ | grep -i ath3
root@c720-r342378:/home/guru #

matthias


-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...) and 
70 years
of war preparation against Russia.  -- PEACE instead of NATO !!!


signature.asc
Description: PGP signature


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-14 Thread Adrian Chadd
ok, so you've added the WB222 coex bits. Does ath3k load OK?


-a


On Sun, 14 Apr 2019 at 09:02, Matthias Apitz  wrote:

> El día domingo, abril 14, 2019 a las 08:56:52a. m. -0700, Adrian Chadd
> escribió:
>
> > hi!
> >
> > Ok, so there's two parts:
> >
> > * loading in the firmware and/or bt nic setup (clock rate, etc) via
> > ath3kfw; and
> > * bluetooth coex/antenna setup in ath(4).
> >
> > The latter I can do. The former may require USB stack debugging.
> >
> > Which NIC is in the C720? Ar9485, right?
>
> $ dmesg | grep ath0
> ath0:  mem 0xe040-0xe047 at device 0.0 on
> pci1
> ath0: Enabling WB222 BTCOEX
> ath0: [HT] enabling HT modes
> ath0: [HT] enabling short-GI in 20MHz mode
> ath0: [HT] 1 stream STBC receive enabled
> ath0: [HT] 1 stream STBC transmit enabled
> ath0: [HT] LDPC transmit/receive enabled
> ath0: [HT] 2 RX streams; 2 TX streams
> ath0: AR9460 mac 640.2 RF5110 phy 2456.12
> ath0: 2GHz radio: 0x; 5GHz radio: 0x
>
> matthias
>
>
> --
> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
> +49-176-38902045
> Public GnuPG key: http://www.unixarea.de/key.pub
> 70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...)
> and 70 years
> of war preparation against Russia.  -- PEACE instead of NATO !!!
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-14 Thread Matthias Apitz
El día domingo, abril 14, 2019 a las 08:56:52a. m. -0700, Adrian Chadd escribió:

> hi!
> 
> Ok, so there's two parts:
> 
> * loading in the firmware and/or bt nic setup (clock rate, etc) via
> ath3kfw; and
> * bluetooth coex/antenna setup in ath(4).
> 
> The latter I can do. The former may require USB stack debugging.
> 
> Which NIC is in the C720? Ar9485, right?

$ dmesg | grep ath0
ath0:  mem 0xe040-0xe047 at device 0.0 on pci1
ath0: Enabling WB222 BTCOEX
ath0: [HT] enabling HT modes
ath0: [HT] enabling short-GI in 20MHz mode
ath0: [HT] 1 stream STBC receive enabled
ath0: [HT] 1 stream STBC transmit enabled
ath0: [HT] LDPC transmit/receive enabled
ath0: [HT] 2 RX streams; 2 TX streams
ath0: AR9460 mac 640.2 RF5110 phy 2456.12
ath0: 2GHz radio: 0x; 5GHz radio: 0x

matthias


-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...) and 
70 years
of war preparation against Russia.  -- PEACE instead of NATO !!!


signature.asc
Description: PGP signature


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-14 Thread Adrian Chadd
hi!

Ok, so there's two parts:

* loading in the firmware and/or bt nic setup (clock rate, etc) via
ath3kfw; and
* bluetooth coex/antenna setup in ath(4).

The latter I can do. The former may require USB stack debugging.

Which NIC is in the C720? Ar9485, right?


-adrian


On Sun, 14 Apr 2019 at 08:47, Matthias Apitz  wrote:

> El día sábado, abril 13, 2019 a las 02:20:06p. m. +, Alexey Dokuchaev
> escribió:
>
> > On Fri, Apr 12, 2019 at 05:12:18PM +, Alexey Dokuchaev wrote:
> > > I've then rebooted back into FreeBSD.  Apparently, this AR3012 hardware
> > > is very fragile, it can be easily left in confused state and won't
> accept
> > > further commands, "usbconfig reset" does not help.  To avoid this, it
> is
> > > better run ./ath3kfw as root, after powercycling machine (to reset the
> > > card).  This got me further:
> > >
>
> I booted my Acer C720 from an external USB disk with an Ubuntu 18.04 ;
> below is the output of the following grep (I can provide the full file if
> it
> is of interest); BlueTooth was working fine out of the box and pairing
> with my Ubuntu mobile phone
>
> $ egrep -i 'e056|blue|ath3' syslog
>
> Apr 13 19:22:47 aurora systemd[1]: Starting Bluetooth service...
> Apr 13 19:22:47 aurora kernel: [3.378263] usb 2-4: New USB device
> found, idVendor=0489, idProduct=e056, bcdDevice= 0.02
> Apr 13 19:22:47 aurora kernel: [   16.176818] Bluetooth: Core ver 2.22
> Apr 13 19:22:47 aurora kernel: [   16.176840] Bluetooth: HCI device and
> connection manager initialized
> Apr 13 19:22:47 aurora kernel: [   16.176845] Bluetooth: HCI socket layer
> initialized
> Apr 13 19:22:47 aurora kernel: [   16.176848] Bluetooth: L2CAP socket
> layer initialized
> Apr 13 19:22:47 aurora kernel: [   16.176858] Bluetooth: SCO socket layer
> initialized
> Apr 13 19:22:47 aurora kernel: [   17.403429] usbcore: registered new
> interface driver ath3k
> Apr 13 19:22:51 aurora bluetoothd[719]: Bluetooth daemon 5.48
> Apr 13 19:22:51 aurora systemd[1]: Started Bluetooth service.
> Apr 13 19:22:51 aurora systemd[1]: Reached target Bluetooth.
> Apr 13 19:22:51 aurora bluetoothd[719]: Starting SDP server
> Apr 13 19:22:51 aurora bluetoothd[719]: Bluetooth management interface
> 1.14 initialized
> Apr 13 19:22:51 aurora kernel: [   30.609088] Bluetooth: BNEP (Ethernet
> Emulation) ver 1.3
> Apr 13 19:22:51 aurora kernel: [   30.609090] Bluetooth: BNEP filters:
> protocol multicast
> Apr 13 19:22:51 aurora kernel: [   30.609096] Bluetooth: BNEP socket layer
> initialized
> Apr 13 19:22:51 aurora dbus-daemon[740]: [system] Activating via systemd:
> service name='org.freedesktop.hostname1'
> unit='dbus-org.freedesktop.hostname1.service' requested by ':1.11' (uid=0
> pid=719 comm="/usr/lib/bluetooth/bluetoothd " label="unconfined")
> Apr 13 19:22:54 aurora NetworkManager[797]:   [1555176174.1461]
> Loaded device plugin: NMBluezManager
> (/usr/lib/x86_64-linux-gnu/NetworkManager/libnm-device-plugin-bluetooth.so)
> Apr 13 19:22:54 aurora NetworkManager[797]:   [1555176174.4358]
> bluez: use BlueZ version 5
> Apr 13 19:22:54 aurora NetworkManager[797]:   [1555176174.4421]
> bluez5: NAP: added interface 90:48:9A:92:9E:44
> Apr 13 19:23:23 aurora /usr/lib/gdm3/gdm-x-session[1324]: (II) modeset(0):
> blueX: 0.160 blueY: 0.144   whiteX: 0.313 whiteY: 0.329
> Apr 13 19:23:29 aurora bluetoothd[719]: Endpoint registered: sender=:1.80
> path=/MediaEndpoint/A2DPSource
> Apr 13 19:23:29 aurora bluetoothd[719]: Endpoint registered: sender=:1.80
> path=/MediaEndpoint/A2DPSink
> Apr 13 19:23:29 aurora kernel: [   68.884106] Bluetooth: RFCOMM TTY layer
> initialized
> Apr 13 19:23:29 aurora kernel: [   68.884115] Bluetooth: RFCOMM socket
> layer initialized
> Apr 13 19:23:29 aurora kernel: [   68.884122] Bluetooth: RFCOMM ver 1.11
> Apr 13 19:24:01 aurora kernel: [  100.963505] Bluetooth: hci0: last event
> is not cmd complete (0x0f)
> Apr 13 19:24:02 aurora dbus-daemon[1340]: [session uid=1000 pid=1340]
> Activating via systemd: service name='org.bluez.obex'
> unit='dbus-org.bluez.obex.service' requested by ':1.58' (uid=1000 pid=1823
> comm="gnome-control-center bluetooth " label="unconfined")
> Apr 13 19:24:02 aurora systemd[1306]: Starting Bluetooth OBEX service...
> Apr 13 19:24:02 aurora dbus-daemon[1340]: [session uid=1000 pid=1340]
> Successfully activated service 'org.bluez.obex'
> Apr 13 19:24:02 aurora systemd[1306]: Started Bluetooth OBEX service.
> Apr 13 19:24:17 aurora kernel: [  116.965447] Bluetooth: hci0: last event
> is not cmd complete (0x0f)
> --
> Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/
> +49-176-38902045
> Public GnuPG key: http://www.unixarea.de/key.pub
> 70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...)
> and 70 years
> of war preparation against Russia.  -- PEACE instead of NATO !!!
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any 

Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-14 Thread Matthias Apitz
El día sábado, abril 13, 2019 a las 02:20:06p. m. +, Alexey Dokuchaev 
escribió:

> On Fri, Apr 12, 2019 at 05:12:18PM +, Alexey Dokuchaev wrote:
> > I've then rebooted back into FreeBSD.  Apparently, this AR3012 hardware
> > is very fragile, it can be easily left in confused state and won't accept
> > further commands, "usbconfig reset" does not help.  To avoid this, it is
> > better run ./ath3kfw as root, after powercycling machine (to reset the
> > card).  This got me further:
> > 

I booted my Acer C720 from an external USB disk with an Ubuntu 18.04 ;
below is the output of the following grep (I can provide the full file if it
is of interest); BlueTooth was working fine out of the box and pairing
with my Ubuntu mobile phone 

$ egrep -i 'e056|blue|ath3' syslog

Apr 13 19:22:47 aurora systemd[1]: Starting Bluetooth service...
Apr 13 19:22:47 aurora kernel: [3.378263] usb 2-4: New USB device found, 
idVendor=0489, idProduct=e056, bcdDevice= 0.02
Apr 13 19:22:47 aurora kernel: [   16.176818] Bluetooth: Core ver 2.22
Apr 13 19:22:47 aurora kernel: [   16.176840] Bluetooth: HCI device and 
connection manager initialized
Apr 13 19:22:47 aurora kernel: [   16.176845] Bluetooth: HCI socket layer 
initialized
Apr 13 19:22:47 aurora kernel: [   16.176848] Bluetooth: L2CAP socket layer 
initialized
Apr 13 19:22:47 aurora kernel: [   16.176858] Bluetooth: SCO socket layer 
initialized
Apr 13 19:22:47 aurora kernel: [   17.403429] usbcore: registered new interface 
driver ath3k
Apr 13 19:22:51 aurora bluetoothd[719]: Bluetooth daemon 5.48
Apr 13 19:22:51 aurora systemd[1]: Started Bluetooth service.
Apr 13 19:22:51 aurora systemd[1]: Reached target Bluetooth.
Apr 13 19:22:51 aurora bluetoothd[719]: Starting SDP server
Apr 13 19:22:51 aurora bluetoothd[719]: Bluetooth management interface 1.14 
initialized
Apr 13 19:22:51 aurora kernel: [   30.609088] Bluetooth: BNEP (Ethernet 
Emulation) ver 1.3
Apr 13 19:22:51 aurora kernel: [   30.609090] Bluetooth: BNEP filters: protocol 
multicast
Apr 13 19:22:51 aurora kernel: [   30.609096] Bluetooth: BNEP socket layer 
initialized
Apr 13 19:22:51 aurora dbus-daemon[740]: [system] Activating via systemd: 
service name='org.freedesktop.hostname1' 
unit='dbus-org.freedesktop.hostname1.service' requested by ':1.11' (uid=0 
pid=719 comm="/usr/lib/bluetooth/bluetoothd " label="unconfined")
Apr 13 19:22:54 aurora NetworkManager[797]:   [1555176174.1461] Loaded 
device plugin: NMBluezManager 
(/usr/lib/x86_64-linux-gnu/NetworkManager/libnm-device-plugin-bluetooth.so)
Apr 13 19:22:54 aurora NetworkManager[797]:   [1555176174.4358] bluez: 
use BlueZ version 5
Apr 13 19:22:54 aurora NetworkManager[797]:   [1555176174.4421] bluez5: 
NAP: added interface 90:48:9A:92:9E:44
Apr 13 19:23:23 aurora /usr/lib/gdm3/gdm-x-session[1324]: (II) modeset(0): 
blueX: 0.160 blueY: 0.144   whiteX: 0.313 whiteY: 0.329
Apr 13 19:23:29 aurora bluetoothd[719]: Endpoint registered: sender=:1.80 
path=/MediaEndpoint/A2DPSource
Apr 13 19:23:29 aurora bluetoothd[719]: Endpoint registered: sender=:1.80 
path=/MediaEndpoint/A2DPSink
Apr 13 19:23:29 aurora kernel: [   68.884106] Bluetooth: RFCOMM TTY layer 
initialized
Apr 13 19:23:29 aurora kernel: [   68.884115] Bluetooth: RFCOMM socket layer 
initialized
Apr 13 19:23:29 aurora kernel: [   68.884122] Bluetooth: RFCOMM ver 1.11
Apr 13 19:24:01 aurora kernel: [  100.963505] Bluetooth: hci0: last event is 
not cmd complete (0x0f)
Apr 13 19:24:02 aurora dbus-daemon[1340]: [session uid=1000 pid=1340] 
Activating via systemd: service name='org.bluez.obex' 
unit='dbus-org.bluez.obex.service' requested by ':1.58' (uid=1000 pid=1823 
comm="gnome-control-center bluetooth " label="unconfined")
Apr 13 19:24:02 aurora systemd[1306]: Starting Bluetooth OBEX service...
Apr 13 19:24:02 aurora dbus-daemon[1340]: [session uid=1000 pid=1340] 
Successfully activated service 'org.bluez.obex'
Apr 13 19:24:02 aurora systemd[1306]: Started Bluetooth OBEX service.
Apr 13 19:24:17 aurora kernel: [  116.965447] Bluetooth: hci0: last event is 
not cmd complete (0x0f)
-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
70 years of NATO - 70 years of wars (Jugoslavia, Afghanistan, Syria, ...) and 
70 years
of war preparation against Russia.  -- PEACE instead of NATO !!!


signature.asc
Description: PGP signature


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-13 Thread Adrian Chadd
On Sat, 13 Apr 2019 at 12:14, Alexey Dokuchaev  wrote:

> On Sat, Apr 13, 2019 at 11:44:25AM -0700, Adrian Chadd wrote:
> > Hm, is this a problem with our usb3 stack itself?
> >
> > If you send me a pull request against ath3k I'll merge it into my git
> > tree just for completeness.
>
> If you tell me how to implement Linuxish usleep_range() correctly in our
> userland, I can do that. :-)
>

usleep_range() is just the same as usleep() at either min, max or a value
in between. It's just a hint to the scheduler that says "look, don't sleep
exactly for this amount of time to wake me up; here are my bounds that are
fine so if you schedule something else before then don't forget about me."
Just pick a value in between. :-)


>
> > Maybe we need to loop in hps@ with a bunch of usbdump output to see what
> > the transactions look like...
>
> CC'ed (sorry for the lack of context hps@, but it's hard with Adrian's
> top-post replies).  Please see the archives for the gory details.
>

Sorry, life is busy nowdays - I was making breakfast and keeping two kids
from eating things they shouldn't. Top posting is quick. :)



-a
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-13 Thread Alexey Dokuchaev
On Sat, Apr 13, 2019 at 11:44:25AM -0700, Adrian Chadd wrote:
> Hm, is this a problem with our usb3 stack itself?
> 
> If you send me a pull request against ath3k I'll merge it into my git
> tree just for completeness.

If you tell me how to implement Linuxish usleep_range() correctly in our
userland, I can do that. :-)

> Maybe we need to loop in hps@ with a bunch of usbdump output to see what
> the transactions look like...

CC'ed (sorry for the lack of context hps@, but it's hard with Adrian's
top-post replies).  Please see the archives for the gory details.

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-13 Thread Adrian Chadd
Hm, is this a problem with our usb3 stack itself?

If you send me a pull request against ath3k I'll merge it into my git tree
just for completeness.

Maybe we need to loop in hps@ with a bunch of usbdump output to see what
the transactions look like...



-adrian


On Sat, 13 Apr 2019 at 07:21, Alexey Dokuchaev  wrote:

> On Fri, Apr 12, 2019 at 05:12:18PM +, Alexey Dokuchaev wrote:
> > I've then rebooted back into FreeBSD.  Apparently, this AR3012 hardware
> > is very fragile, it can be easily left in confused state and won't accept
> > further commands, "usbconfig reset" does not help.  To avoid this, it is
> > better run ./ath3kfw as root, after powercycling machine (to reset the
> > card).  This got me further:
> >
> > ath3kfw: opening dev 2.2
> > main: state=0x0e
> > ROM version: 285343744, build version: 155, ram version: 155, ref clock=1
> > ath3k_init_firmware: loading ath3k-1.fw
> > ath3k_load_fwfile:
> file=/home/danfe/ath3k/share/firmware/ath3k/ath3k-1.fw,
> > size=246804
> > ath3k_load_fwfile: transferring 20 bytes, offset 4096
>
> Looks like there is a bug with the logging, consider this pseudo-patch:
>
> @@ ...
> ath3k_debug("%s: transferring %d bytes, offset %d\n",
> __func__,
> -   sent,
> -   size);
> +   size, sent);
>
> > ...
> > ath3k_load_fwfile: transferring 65556 bytes, offset 4096
> > LIBUSB_FUNCTION: libusb_bulk_transfer enter
> > LIBUSB_FUNCTION: libusb_submit_transfer enter
> > LIBUSB_FUNCTION: libusb_submit_transfer leave 0
> > LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
> > LIBUSB_FUNCTION: libusb10_handle_events_sub enter
> > LIBUSB_TRANSFER: sync I/O done
> > LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
> > LIBUSB_FUNCTION: libusb_bulk_transfer leave
> > Can't load firmware: err=Timeout, size=4096
> > ath3k_load_fwfile: transferring 65556 bytes, offset 4096
>
> I've found seemingly related bug report about Atheros BT devices (ath3k)
> failing to work on USB 3.0 buses, while working well on USB 2.0:
>
> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1400215
>
> In 2015, a work-around for this problem was committed* to Linux kernel:
>
> author  Adam Lee2015-01-28
> committer   Marcel Holtmann2015-01-29
> commit  c561a5753dd631920c4459a067d22679b3d110d6
>
>   Bluetooth: ath3k: workaround the compatibility issue with xHCI controller
>
>   ath3k devices fail to load firmwares on xHCI buses, but work well on
>   EHCI, this might be a compatibility issue between xHCI and ath3k chips.
>   As my testing result, those chips will work on xHCI buses again with
>   this patch.
>
>   This workaround is from Qualcomm, they also did some workarounds in
>   Windows driver.
>
> I've patched ath3kfw tool in a similar way like this:
>
> +#define TIMEGAP_USEC_MIN 50
> +#define TIMEGAP_USEC_MAX 100
> +
> +static inline void
> +usleep_range(unsigned long min, unsigned long max)
> +{
> +usleep(min); // or usleep(max);
> +}
>  ...
>
>  while (count) {
> +/* workaround the compatibility issue with xHCI controller */
> +usleep_range(TIMEGAP_USEC_MIN, TIMEGAP_USEC_MAX);
>
> Unfortunately, this hack didn't help, neither with usleep(min) nor with
> usleep(max).  Error message is the same "Can't load firmware: err=Timeout,
> size=4096".
>
> I will try to find a USB 2.0-only laptop which supports mini-PCIe cards
> to get more data points, but not sure if I can find one easily.  It would
> be nice if someone who has pre-xHCI hardware could conduct this test.
>
> ./danfe
>
> *)
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/drivers/bluetooth/ath3k.c?id=c561a5753dd631920c4459a067d22679b3d110d6
> ___
> freebsd-wireless@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
> To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org
> "
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-13 Thread Alexey Dokuchaev
On Fri, Apr 12, 2019 at 05:12:18PM +, Alexey Dokuchaev wrote:
> I've then rebooted back into FreeBSD.  Apparently, this AR3012 hardware
> is very fragile, it can be easily left in confused state and won't accept
> further commands, "usbconfig reset" does not help.  To avoid this, it is
> better run ./ath3kfw as root, after powercycling machine (to reset the
> card).  This got me further:
> 
> ath3kfw: opening dev 2.2
> main: state=0x0e
> ROM version: 285343744, build version: 155, ram version: 155, ref clock=1
> ath3k_init_firmware: loading ath3k-1.fw
> ath3k_load_fwfile: file=/home/danfe/ath3k/share/firmware/ath3k/ath3k-1.fw,
> size=246804
> ath3k_load_fwfile: transferring 20 bytes, offset 4096

Looks like there is a bug with the logging, consider this pseudo-patch:

@@ ...
ath3k_debug("%s: transferring %d bytes, offset %d\n",
__func__,
-   sent,
-   size);
+   size, sent);

> ...
> ath3k_load_fwfile: transferring 65556 bytes, offset 4096
> LIBUSB_FUNCTION: libusb_bulk_transfer enter
> LIBUSB_FUNCTION: libusb_submit_transfer enter
> LIBUSB_FUNCTION: libusb_submit_transfer leave 0
> LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
> LIBUSB_FUNCTION: libusb10_handle_events_sub enter
> LIBUSB_TRANSFER: sync I/O done
> LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
> LIBUSB_FUNCTION: libusb_bulk_transfer leave
> Can't load firmware: err=Timeout, size=4096
> ath3k_load_fwfile: transferring 65556 bytes, offset 4096

I've found seemingly related bug report about Atheros BT devices (ath3k)
failing to work on USB 3.0 buses, while working well on USB 2.0:

https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1400215

In 2015, a work-around for this problem was committed* to Linux kernel:

author  Adam Lee2015-01-28
committer   Marcel Holtmann2015-01-29
commit  c561a5753dd631920c4459a067d22679b3d110d6

  Bluetooth: ath3k: workaround the compatibility issue with xHCI controller

  ath3k devices fail to load firmwares on xHCI buses, but work well on
  EHCI, this might be a compatibility issue between xHCI and ath3k chips.
  As my testing result, those chips will work on xHCI buses again with
  this patch.

  This workaround is from Qualcomm, they also did some workarounds in
  Windows driver.

I've patched ath3kfw tool in a similar way like this:

+#define TIMEGAP_USEC_MIN 50
+#define TIMEGAP_USEC_MAX 100
+
+static inline void
+usleep_range(unsigned long min, unsigned long max)
+{
+usleep(min); // or usleep(max);
+}
 ...

 while (count) {
+/* workaround the compatibility issue with xHCI controller */
+usleep_range(TIMEGAP_USEC_MIN, TIMEGAP_USEC_MAX);

Unfortunately, this hack didn't help, neither with usleep(min) nor with
usleep(max).  Error message is the same "Can't load firmware: err=Timeout,
size=4096".

I will try to find a USB 2.0-only laptop which supports mini-PCIe cards
to get more data points, but not sure if I can find one easily.  It would
be nice if someone who has pre-xHCI hardware could conduct this test.

./danfe

*) 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/drivers/bluetooth/ath3k.c?id=c561a5753dd631920c4459a067d22679b3d110d6
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-12 Thread Adrian Chadd
Well, yeah, qualcomm developers did a lot of the linux ath9k/ath3k support
:)


-a
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-12 Thread Alexey Dokuchaev
On Thu, Apr 11, 2019 at 02:23:50PM +, Alexey Dokuchaev wrote:
> On Thu, Apr 11, 2019 at 06:36:26AM -0700, Adrian Chadd wrote:
> > I have a tool to upload firmware -- github.com/erikarn/ath3k.
> > See if that helps!
> 
> Something's wrong:
> 
>   $ git clone https://github.com/erikarn/ath3k.git
>   $ cd ath3k/src/usr.bin/ath3k
>   $ make
>   $ usbconfig list | grep 0x0930
>   ugen2.2:  at usbus2 <...>
>   $ ./ath3kfw -D -d ugen2.2 -I
>   ath3kfw: opening dev 2.2
>   ath3k_get_state: libusb_control_transfer() failed: code=-4
>   main: ath3k_get_state() failed!

I've booted off Fedora 26 USB thumbdrive, to discover that everything
works (dualband WiFi, BT, devices can be discovered), so the hardware
is not faulty.

I've converted Linux' drivers/bluetooth/ath3k.c to libusb to obtain
rom_version and ref_clock of my card, so I know which firmware files
I need (just in case):

  # ./a.out
  get_state -> 1, state = 0xce
  get_version -> 20, rom_version = 0x1102, clock value = 40

I've then rebooted back into FreeBSD.  Apparently, this AR3012 hardware
if very fragile, it can be easily left in confused state and won't accept
further commands, "usbconfig reset" does not help.  To avoid this, it is
better run ./ath3kfw as root, after powercycling machine (to reset the
card).  This got me further:

ath3kfw: opening dev 2.2
main: state=0x0e
ROM version: 285343744, build version: 155, ram version: 155, ref clock=1
ath3k_init_firmware: loading ath3k-1.fw
ath3k_load_fwfile: file=/home/danfe/ath3k/share/firmware/ath3k/ath3k-1.fw,
size=246804
ath3k_load_fwfile: transferring 20 bytes, offset 4096
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_bulk_transfer leave
ath3k_load_fwfile: transferring 4116 bytes, offset 4096
...
ath3k_load_fwfile: transferring 8212 bytes, offset 4096
...
ath3k_load_fwfile: transferring 12308 bytes, offset 4096
...
... (numbers go 16404, 20500, 24596, 28692, 32788, 36884, 40980, 45076 ...)
...
ath3k_load_fwfile: transferring 65556 bytes, offset 4096
LIBUSB_FUNCTION: libusb_bulk_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer enter
LIBUSB_FUNCTION: libusb_submit_transfer leave 0
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed enter
LIBUSB_FUNCTION: libusb10_handle_events_sub enter
LIBUSB_TRANSFER: sync I/O done
LIBUSB_FUNCTION: libusb_handle_events_timeout_completed exit
LIBUSB_FUNCTION: libusb_bulk_transfer leave
Can't load firmware: err=Timeout, size=4096
ath3k_load_fwfile: transferring 65556 bytes, offset 4096

After that, ``hccontrol inquiry'' stops working at all (says "operation
timed out"), dmesg shows this:

ubt0: ubt_ctrl_write_callback:782: control transfer failed: USB_ERR_TIMEOUT
ng_hci_process_command_timeout: ubt0hci - unable to complete HCI command
OGF=0x1, OCF=0x1. Timeout

./danfe

P.S.  Fedora is amazing (just as Ubuntu) on this laptop: everything works,
WMI multimedia keys, LCD brightness control, mic/speaker mute buttons, WiFi
and Bluetooth.  Under FreeBSD, only WiFi works from this list. :-(
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Adrian Chadd
>
> Hi,
>

I'm trying to figure out an ath sta mode crash and some ath10k things. I
have the AR9485 / AR9462 hardware here so please just keep poking me here
and on irc over the next couple weeks to get it working.

There's also some weird antenna coex stuff that needs setting up in the HAL
too that I thought I did but it isn't automatic.. :(


-a
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Alexey Dokuchaev
On Thu, Apr 11, 2019 at 04:05:27PM +, Matthias Apitz wrote:
> On Thu, 11 Apr 2019 14:23:50 +, Alexey Dokuchaev wrote:
> > On Thu, Apr 11, 2019 at 06:36:26AM -0700, Adrian Chadd wrote:
> >> I have a tool to upload firmware -- github.com/erikarn/ath3k.
> >> See if that helps!
> >
> > Something's wrong:
> >
> >   $ git clone https://github.com/erikarn/ath3k.git
> >   $ cd ath3k/src/usr.bin/ath3k
> >   $ make
> >   $ usbconfig list | grep 0x0930
> >   ugen2.2:  at usbus2 <...>
> >   $ ./ath3kfw -D -d ugen2.2 -I
> >   ath3kfw: opening dev 2.2
> >   ath3k_get_state: libusb_control_transfer() failed: code=-4
> >   main: ath3k_get_state() failed!
> >
> > USB device permissions are fine.

To be clear: running it root does not change the output.

> Is this on CURRENT?

Yes, and pretty fresh one (kernel 1300018, userland 1300014).

Do you observe different results?  If so, does it help or can you
share anything?

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Matthias Apitz
On Thu, 11 Apr 2019 14:23:50 +, Alexey Dokuchaev wrote:
> On Thu, Apr 11, 2019 at 06:36:26AM -0700, Adrian Chadd wrote:
>> I have a tool to upload firmware -- github.com/erikarn/ath3k.
>> See if that helps!
>
> Something's wrong:
>
>   $ git clone https://github.com/erikarn/ath3k.git
>   $ cd ath3k/src/usr.bin/ath3k
>   $ make
>   $ usbconfig list | grep 0x0930
>   ugen2.2:  at usbus2 <...>
>   $ ./ath3kfw -D -d ugen2.2 -I
>   ath3kfw: opening dev 2.2
>   ath3k_get_state: libusb_control_transfer() failed: code=-4
>   main: ath3k_get_state() failed!
>
> USB device permissions are fine.
>

Is this on CURRENT?

matthias


-- 
Sent using Dekko from my Ubuntu device
http://www.unixarea.de/+49 176 38902045
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Alexey Dokuchaev
On Thu, Apr 11, 2019 at 06:36:26AM -0700, Adrian Chadd wrote:
> I have a tool to upload firmware -- github.com/erikarn/ath3k.
> See if that helps!

Something's wrong:

  $ git clone https://github.com/erikarn/ath3k.git
  $ cd ath3k/src/usr.bin/ath3k
  $ make
  $ usbconfig list | grep 0x0930
  ugen2.2:  at usbus2 <...>
  $ ./ath3kfw -D -d ugen2.2 -I
  ath3kfw: opening dev 2.2
  ath3k_get_state: libusb_control_transfer() failed: code=-4
  main: ath3k_get_state() failed!

USB device permissions are fine.

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Adrian Chadd
I have a tool to upload firmware - github.com/erikarn/ath3k. See if that
helps!


-a


On Thu, 11 Apr 2019 at 06:19, Alexey Dokuchaev  wrote:

> On Thu, Apr 11, 2019 at 03:13:28PM +0200, Matthias Apitz wrote:
> > # usbconfig list
> > ...
> > ugen0.3:  at usbus0, cfg=0 md=HOST
> > spd=FULL (12Mbps) pwr=ON (100mA)
> >
> > The later vendor 0x0489 product 0xe056 seems to be:
> >
> > https://cateee.net/lkddb/web-lkddb/BT_ATH3K.html
>
> Yes, it is also Atheros AR3012 (with sflash firmware), in Linux it's
> handled by the same ath3k driver as my chip.  I'll try to boot under
> Ubuntu LiveCD on the weekend to see if it really works.
>
> ./danfe
> ___
> freebsd-wireless@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
> To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org
> "
>
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Alexey Dokuchaev
On Thu, Apr 11, 2019 at 03:13:28PM +0200, Matthias Apitz wrote:
> # usbconfig list
> ...
> ugen0.3:  at usbus0, cfg=0 md=HOST
> spd=FULL (12Mbps) pwr=ON (100mA)
> 
> The later vendor 0x0489 product 0xe056 seems to be:
> 
> https://cateee.net/lkddb/web-lkddb/BT_ATH3K.html

Yes, it is also Atheros AR3012 (with sflash firmware), in Linux it's
handled by the same ath3k driver as my chip.  I'll try to boot under
Ubuntu LiveCD on the weekend to see if it really works.

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Matthias Apitz
El día jueves, abril 11, 2019 a las 12:52:42p. m. +, Alexey Dokuchaev 
escribió:

> > ath0: Enabling WB222 BTCOEX
> > ...
> > 
> > But I don't know how to further enable any BT device.
> 
> What does "usbconfig list" say about your BT device?  Mine is
> 0x0930:0x021c, which is AR3012 with sflash firmware according to
> the Linux' drivers/bluetooth/ath3k.c.  Ubuntu users had reported*
> similar problems:

# usbconfig list
ugen0.1: <0x8086 XHCI root HUB> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) 
pwr=SAVE (0mA)
ugen1.1:  at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps) 
pwr=SAVE (0mA)
ugen0.2:  at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) 
pwr=ON (500mA)
ugen1.2:  at usbus1, cfg=0 md=HOST spd=HIGH 
(480Mbps) pwr=SAVE (0mA)
ugen0.3:  at usbus0, cfg=0 md=HOST spd=FULL 
(12Mbps) pwr=ON (100mA)

The later vendor 0x0489 product 0xe056 seems to be:

https://cateee.net/lkddb/web-lkddb/BT_ATH3K.html

...
Numeric ID (from LKDDb) and names (from usb.ids) of recognized devices:

vendor: 03f0 ("HP, Inc"), product: 311d ("Atheros AR9285 Malbec Bluetooth 
Adapter")
vendor: 0489 ("Foxconn / Hon Hai"), product: e027
vendor: 0489 ("Foxconn / Hon Hai"), product: e02c ("Atheros AR5BBU12 
Bluetooth Device")
vendor: 0489 ("Foxconn / Hon Hai"), product: e036
vendor: 0489 ("Foxconn / Hon Hai"), product: e03c
vendor: 0489 ("Foxconn / Hon Hai"), product: e03d
vendor: 0489 ("Foxconn / Hon Hai"), product: e04d ("Atheros AR3012 
Bluetooth")
vendor: 0489 ("Foxconn / Hon Hai"), product: e04e
vendor: 0489 ("Foxconn / Hon Hai"), product: e056
vendor: 0489 ("Foxconn / Hon Hai"), product: e057
...

-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Alexey Dokuchaev
On Thu, Apr 11, 2019 at 12:46:47PM +0200, Matthias Apitz wrote:
> > ...
> > I've just stumbled upon this email* of Adrian's that tells how to enable
> > Bluetooth Coexistence by adding ``hint.ath.0.btcoex_profile="wb222"'' to
> > /boot/device.hints (for AR9462 cards).  I've done that, and logs tell me
> > it is enabled, but Bluetooth still does not work:
> > 
> >   % dmesg | grep -i coex
> >   ath0: Enabling WB222 BTCOEX
> >   # hccontrol inquiry
> >   ... repeated attempts, plenty of devices around ...
> >   Inquiry complete. Status: No error [00]
> 
> I own an Acer C720 and set the same in /boot/device.hints. After boot it
> says in dmesg:
> 
> $ dmesg | grep ath
> ath0:  mem 0xe040-0xe047 at device 0.0 on pci1
> ath0: RX status length: 48
> ath0: RX buffer size: 4096
> ath0: TX descriptor length: 128
> ath0: TX status length: 36
> ath0: TX buffers per descriptor: 4
> ath0: ath_edma_setup_rxfifo: type=0, FIFO depth = 16 entries
> ath0: ath_edma_setup_rxfifo: type=1, FIFO depth = 128 entries
> ath0: Enabling WB222 BTCOEX
> ...
> 
> But I don't know how to further enable any BT device.

What does "usbconfig list" say about your BT device?  Mine is
0x0930:0x021c, which is AR3012 with sflash firmware according to
the Linux' drivers/bluetooth/ath3k.c.  Ubuntu users had reported*
similar problems:

  "My BT seems to work to some extent.. answers to commands etc.
   But it doesn't discover anything

   sudo hcitool -i hci0 inq gives nothing.. even though devices
   are discoverable."

Which apparently might be solved by updating the card's firmware:

  commit 0a9640c85c781a4ec0c82f16fbf7333b7ce6daa6
  Author: Costa Yao
  Date: Wed Jul 4 17:38:09 2012 +0800

ar3k: add patch and sysconfig for Qualcomm Atheros AR9462

 add patch and sysconfig for Qualcomm Atheros AR9462

Signed-off-by: Costa Yao
Signed-off-by: Ben Hutchings

This commit is from 2012, but I'm not sure how relevant it is to
FreeBSD because it seems that ATH_EEPROM_FIRMWARE is disabled by
default in our ath(4); then again, I have no real knowledge about
our drivers and how ath3k/ath9k (BT/WiFi) parts are handled.

./danfe

*) https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1024884
   https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1394368
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Matthias Apitz
El día jueves, abril 11, 2019 a las 09:27:58a. m. +, Alexey Dokuchaev 
escribió:

> On Wed, Apr 10, 2019 at 03:22:50PM +, Alexey Dokuchaev wrote:
> > On Tue, Apr 09, 2019 at 04:03:44PM +, Alexey Dokuchaev wrote:
> > > On Sun, Jun 02, 2013 at 09:59:05AM -0700, Adrian Chadd wrote:
> > > > Hi,
> > > > 
> > > > It's supported in -HEAD.
> > 
> > Driver attaches correctly if I move module loading to loader.conf(5):
> > 
> > if_ath_load="YES"
> > if_ath_pci_load="YES"
> > 
> > Bluetooth still doesn't work though.
> 
> I've just stumbled upon this email* of Adrian's that tells how to enable
> Bluetooth Coexistence by adding ``hint.ath.0.btcoex_profile="wb222"'' to
> /boot/device.hints (for AR9462 cards).  I've done that, and logs tell me
> it is enabled, but Bluetooth still does not work:
> 
>   % dmesg | grep -i coex
>   ath0: Enabling WB222 BTCOEX
>   # hccontrol inquiry
>   ... repeated attempts, plenty of devices around ...
>   Inquiry complete. Status: No error [00]

I own an Acer C720 and set the same in /boot/device.hints. After boot it
says in dmesg:

$ dmesg | grep ath
ath0:  mem 0xe040-0xe047 at device 0.0 on pci1
ath0: RX status length: 48
ath0: RX buffer size: 4096
ath0: TX descriptor length: 128
ath0: TX status length: 36
ath0: TX buffers per descriptor: 4
ath0: ath_edma_setup_rxfifo: type=0, FIFO depth = 16 entries
ath0: ath_edma_setup_rxfifo: type=1, FIFO depth = 128 entries
ath0: Enabling WB222 BTCOEX
...

But I don't know how to further enable any BT device. The above
hcccontrol just says:

# hccontrol inquiry
hccontrol: Could not create socket: Address family not supported by protocol 
family

What in addition I should load or do to get BT working?
Thanks

matthias

-- 
Matthias Apitz, ✉ g...@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-11 Thread Alexey Dokuchaev
On Wed, Apr 10, 2019 at 03:22:50PM +, Alexey Dokuchaev wrote:
> On Tue, Apr 09, 2019 at 04:03:44PM +, Alexey Dokuchaev wrote:
> > On Sun, Jun 02, 2013 at 09:59:05AM -0700, Adrian Chadd wrote:
> > > Hi,
> > > 
> > > It's supported in -HEAD.
> 
> Driver attaches correctly if I move module loading to loader.conf(5):
> 
> if_ath_load="YES"
> if_ath_pci_load="YES"
> 
> Bluetooth still doesn't work though.

I've just stumbled upon this email* of Adrian's that tells how to enable
Bluetooth Coexistence by adding ``hint.ath.0.btcoex_profile="wb222"'' to
/boot/device.hints (for AR9462 cards).  I've done that, and logs tell me
it is enabled, but Bluetooth still does not work:

  % dmesg | grep -i coex
  ath0: Enabling WB222 BTCOEX
  # hccontrol inquiry
  ... repeated attempts, plenty of devices around ...
  Inquiry complete. Status: No error [00]

./danfe

*) https://lists.freebsd.org/pipermail/freebsd-wireless/2016-June/006766.html
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-10 Thread Alexey Dokuchaev
On Tue, Apr 09, 2019 at 04:03:44PM +, Alexey Dokuchaev wrote:
> On Sun, Jun 02, 2013 at 09:59:05AM -0700, Adrian Chadd wrote:
> > Hi,
> > 
> > It's supported in -HEAD.
> 
> Hmm, almost six years later, apparently it is still not:
> 
> % uname -UK
> 1300014 1300014
> 
> # kldload if_ath_pci if_ath

Driver attaches correctly if I move module loading to loader.conf(5):

if_ath_load="YES"
if_ath_pci_load="YES"

Bluetooth still doesn't work though.

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2019-04-09 Thread Alexey Dokuchaev
On Sun, Jun 02, 2013 at 09:59:05AM -0700, Adrian Chadd wrote:
> Hi,
> 
> It's supported in -HEAD.

Hmm, almost six years later, apparently it is still not:

% uname -UK
1300014 1300014

# kldload if_ath_pci if_ath

% pciconf -lv | tail -4
none2@pci0:3:0:0:   class=0x028000 card=0x66ad chip=0x0034168c
rev=0x01 hdr=0x00
vendor = 'Qualcomm Atheros'
device = 'AR9462 Wireless Network Adapter'
class  = network

> Bluetooth may or may not work. I've not sat down and focused on that,
> sorry.

Looks like it does not work either: ``hccontrol inquiry'' does not see
any devices around. :-(

./danfe
___
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"


Re: Atheros AR5B22 WLAN+Bluetooth support on FreeBSD

2013-06-02 Thread Adrian Chadd
Hi,

It's supported in -HEAD.

Bluetooth may or may not work. I've not sat down and focused on that, sorry.


adrian

On 2 June 2013 08:00, Miguel Clara  wrote:
> Hi,
>
> Sorry for the direct mail, but I not sure about the correct steps to
> take when a driver is missing... if there a mailling list I should
> contact first please do tell me and ignore the rest of the message, I
> understand you probably have much important things to do.
>
> In any case there's no arm in trying...
>
> I recently bought a Acer S3 Ultrabook, the machine does not have a LAN
> port so Wireless support is really important in this module, this
> seams to be common in other Ultrabooks...
>
> Anyway the model of the wifi card is as stated in the subject Atheros AR5B22.
> From what I read in wiki.freebsd.org/dev/ath(4) this device doesn't
> have support yet, and I'm wondering if it ever will?
>
> pciconf -lv show the following output:
>
> none2@pci0:2:0:0:class=0x028000 card=0xe052105b chip=0x0034168c
> rev=0x01 hdr=0x00
>  vendor = 'Atheros Communications Inc.'
>  class = network
>
> Not sure if any additional info is needed.
>
> Thanks
___
freebsd-wireless@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"