Hi Fred,
<snip>
quoted
quoted
@@ -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 ?
if I screwed this up, then please send a patch right away.
Regards
Marcel