Re: [PATCHv2] android/hidhost: Fix connecting HOGP over BREDR

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

 



Hi Mariusz,

On Tuesday 19 of May 2015 10:56:28 Mariusz Skamra wrote:
> This patch fixes issue related to HID connection over BREDR.
> To avoid HOG connection with dual mode device connected over
> BREDR, bearer type is checked not the features of remote device.
> ---
>  android/hidhost.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/android/hidhost.c b/android/hidhost.c
> index 729b884..1543685 100644
> --- a/android/hidhost.c
> +++ b/android/hidhost.c
> @@ -891,7 +891,7 @@ static void bt_hid_connect(const void *buf, uint16_t
> len) ba2str(&dev->dst, addr);
>  	DBG("connecting to %s", addr);
> 
> -	if (bt_is_device_le(&dst)) {
> +	if (bt_device_last_seen_bearer(&dev->dst)) {

I'd prefer explicit check
if (bt_device_last_seen_bearer(&dev->dst) != BDADDR_BREDR)

>  		if (!hog_connect(dev)) {
>  			status = HAL_STATUS_FAILED;
>  			hid_device_remove(dev);

-- 
BR
Szymon Janc
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




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

  Powered by Linux