Hello Marcel and Ilya,
On 17/06/2015 23:53, Ilya Faenson wrote:
Thanks a lot, Marcel.
-----Original Message-----
From: Marcel Holtmann [mailto:marcel@xxxxxxxxxxxx]
Sent: Wednesday, June 17, 2015 5:51 PM
To: Ilya Faenson
Cc: BlueZ development; Arend Van Spriel
Subject: Re: [PATCH v4 2/4] hci_uart: line discipline enhancements
Hi Ilya,
<snip>
@@ -287,15 +366,28 @@ static int hci_uart_setup(struct hci_dev *hdev)
struct hci_uart *hu = hci_get_drvdata(hdev);
struct hci_rp_read_local_version *ver;
struct sk_buff *skb;
+ unsigned int speed;
int err;
+ /* Init speed if any */
+ speed = 0;
if (hu->proto->init_speed)
- hci_uart_set_baudrate(hu, hu->proto->init_speed);
-
- if (hu->proto->set_baudrate && hu->proto->oper_speed) {
- err = hu->proto->set_baudrate(hu, hu->proto->oper_speed);
+ speed = hu->proto->init_speed;
+ else if (hu->init_speed)
+ speed = hu->init_speed;
I added the speed assignment as else statement
else
speed = 0;
Afaiu, with this change hu->proto->*speed will always be used for all
bcm device.
I think hu->*speed should be used if exist or hu->proto->*speed, so the
test should be swapped.
The equivalent change is needed in bcm_setup() of hci_bcm.c.
Ilya, do you want to do it or should I send a patch ?
Regards
Fred
--
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