aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/bluetooth
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/bluetooth')
-rw-r--r--drivers/bluetooth/ath3k.c15
-rw-r--r--drivers/bluetooth/bfusb.c4
-rw-r--r--drivers/bluetooth/bluecard_cs.c4
-rw-r--r--drivers/bluetooth/bt3c_cs.c4
-rw-r--r--drivers/bluetooth/btuart_cs.c4
-rw-r--r--drivers/bluetooth/btusb.c19
-rw-r--r--drivers/bluetooth/dtl1_cs.c4
-rw-r--r--drivers/bluetooth/hci_vhci.c5
8 files changed, 32 insertions, 27 deletions
diff --git a/drivers/bluetooth/ath3k.c b/drivers/bluetooth/ath3k.c
index 106beb194f3c..1622772f802d 100644
--- a/drivers/bluetooth/ath3k.c
+++ b/drivers/bluetooth/ath3k.c
@@ -30,6 +30,7 @@
30#include <net/bluetooth/bluetooth.h> 30#include <net/bluetooth/bluetooth.h>
31 31
32#define VERSION "1.0" 32#define VERSION "1.0"
33#define ATH3K_FIRMWARE "ath3k-1.fw"
33 34
34#define ATH3K_DNLOAD 0x01 35#define ATH3K_DNLOAD 0x01
35#define ATH3K_GETSTATE 0x05 36#define ATH3K_GETSTATE 0x05
@@ -400,9 +401,15 @@ static int ath3k_probe(struct usb_interface *intf,
400 return 0; 401 return 0;
401 } 402 }
402 403
403 if (request_firmware(&firmware, "ath3k-1.fw", &udev->dev) < 0) { 404 ret = request_firmware(&firmware, ATH3K_FIRMWARE, &udev->dev);
404 BT_ERR("Error loading firmware"); 405 if (ret < 0) {
405 return -EIO; 406 if (ret == -ENOENT)
407 BT_ERR("Firmware file \"%s\" not found",
408 ATH3K_FIRMWARE);
409 else
410 BT_ERR("Firmware file \"%s\" request failed (err=%d)",
411 ATH3K_FIRMWARE, ret);
412 return ret;
406 } 413 }
407 414
408 ret = ath3k_load_firmware(udev, firmware); 415 ret = ath3k_load_firmware(udev, firmware);
@@ -441,4 +448,4 @@ MODULE_AUTHOR("Atheros Communications");
441MODULE_DESCRIPTION("Atheros AR30xx firmware driver"); 448MODULE_DESCRIPTION("Atheros AR30xx firmware driver");
442MODULE_VERSION(VERSION); 449MODULE_VERSION(VERSION);
443MODULE_LICENSE("GPL"); 450MODULE_LICENSE("GPL");
444MODULE_FIRMWARE("ath3k-1.fw"); 451MODULE_FIRMWARE(ATH3K_FIRMWARE);
diff --git a/drivers/bluetooth/bfusb.c b/drivers/bluetooth/bfusb.c
index 61b591470a90..a936763b8c3d 100644
--- a/drivers/bluetooth/bfusb.c
+++ b/drivers/bluetooth/bfusb.c
@@ -751,9 +751,7 @@ static void bfusb_disconnect(struct usb_interface *intf)
751 751
752 bfusb_close(hdev); 752 bfusb_close(hdev);
753 753
754 if (hci_unregister_dev(hdev) < 0) 754 hci_unregister_dev(hdev);
755 BT_ERR("Can't unregister HCI device %s", hdev->name);
756
757 hci_free_dev(hdev); 755 hci_free_dev(hdev);
758} 756}
759 757
diff --git a/drivers/bluetooth/bluecard_cs.c b/drivers/bluetooth/bluecard_cs.c
index aed1904ea67b..c6a0c6103743 100644
--- a/drivers/bluetooth/bluecard_cs.c
+++ b/drivers/bluetooth/bluecard_cs.c
@@ -844,9 +844,7 @@ static int bluecard_close(bluecard_info_t *info)
844 /* Turn FPGA off */ 844 /* Turn FPGA off */
845 outb(0x80, iobase + 0x30); 845 outb(0x80, iobase + 0x30);
846 846
847 if (hci_unregister_dev(hdev) < 0) 847 hci_unregister_dev(hdev);
848 BT_ERR("Can't unregister HCI device %s", hdev->name);
849
850 hci_free_dev(hdev); 848 hci_free_dev(hdev);
851 849
852 return 0; 850 return 0;
diff --git a/drivers/bluetooth/bt3c_cs.c b/drivers/bluetooth/bt3c_cs.c
index 4fc01949d399..0c97e5d514b6 100644
--- a/drivers/bluetooth/bt3c_cs.c
+++ b/drivers/bluetooth/bt3c_cs.c
@@ -636,9 +636,7 @@ static int bt3c_close(bt3c_info_t *info)
636 636
637 bt3c_hci_close(hdev); 637 bt3c_hci_close(hdev);
638 638
639 if (hci_unregister_dev(hdev) < 0) 639 hci_unregister_dev(hdev);
640 BT_ERR("Can't unregister HCI device %s", hdev->name);
641
642 hci_free_dev(hdev); 640 hci_free_dev(hdev);
643 641
644 return 0; 642 return 0;
diff --git a/drivers/bluetooth/btuart_cs.c b/drivers/bluetooth/btuart_cs.c
index 526b61807d94..200b3a2877d6 100644
--- a/drivers/bluetooth/btuart_cs.c
+++ b/drivers/bluetooth/btuart_cs.c
@@ -565,9 +565,7 @@ static int btuart_close(btuart_info_t *info)
565 565
566 spin_unlock_irqrestore(&(info->lock), flags); 566 spin_unlock_irqrestore(&(info->lock), flags);
567 567
568 if (hci_unregister_dev(hdev) < 0) 568 hci_unregister_dev(hdev);
569 BT_ERR("Can't unregister HCI device %s", hdev->name);
570
571 hci_free_dev(hdev); 569 hci_free_dev(hdev);
572 570
573 return 0; 571 return 0;
diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index f9b726091ad0..2bd87d45f1c2 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -100,6 +100,9 @@ static struct usb_device_id btusb_table[] = {
100 /* Canyon CN-BTU1 with HID interfaces */ 100 /* Canyon CN-BTU1 with HID interfaces */
101 { USB_DEVICE(0x0c10, 0x0000) }, 101 { USB_DEVICE(0x0c10, 0x0000) },
102 102
103 /* Broadcom BCM20702A0 */
104 { USB_DEVICE(0x413c, 0x8197) },
105
103 { } /* Terminating entry */ 106 { } /* Terminating entry */
104}; 107};
105 108
@@ -312,7 +315,8 @@ static int btusb_submit_intr_urb(struct hci_dev *hdev, gfp_t mem_flags)
312 315
313 err = usb_submit_urb(urb, mem_flags); 316 err = usb_submit_urb(urb, mem_flags);
314 if (err < 0) { 317 if (err < 0) {
315 BT_ERR("%s urb %p submission failed (%d)", 318 if (err != -EPERM && err != -ENODEV)
319 BT_ERR("%s urb %p submission failed (%d)",
316 hdev->name, urb, -err); 320 hdev->name, urb, -err);
317 usb_unanchor_urb(urb); 321 usb_unanchor_urb(urb);
318 } 322 }
@@ -397,7 +401,8 @@ static int btusb_submit_bulk_urb(struct hci_dev *hdev, gfp_t mem_flags)
397 401
398 err = usb_submit_urb(urb, mem_flags); 402 err = usb_submit_urb(urb, mem_flags);
399 if (err < 0) { 403 if (err < 0) {
400 BT_ERR("%s urb %p submission failed (%d)", 404 if (err != -EPERM && err != -ENODEV)
405 BT_ERR("%s urb %p submission failed (%d)",
401 hdev->name, urb, -err); 406 hdev->name, urb, -err);
402 usb_unanchor_urb(urb); 407 usb_unanchor_urb(urb);
403 } 408 }
@@ -520,7 +525,8 @@ static int btusb_submit_isoc_urb(struct hci_dev *hdev, gfp_t mem_flags)
520 525
521 err = usb_submit_urb(urb, mem_flags); 526 err = usb_submit_urb(urb, mem_flags);
522 if (err < 0) { 527 if (err < 0) {
523 BT_ERR("%s urb %p submission failed (%d)", 528 if (err != -EPERM && err != -ENODEV)
529 BT_ERR("%s urb %p submission failed (%d)",
524 hdev->name, urb, -err); 530 hdev->name, urb, -err);
525 usb_unanchor_urb(urb); 531 usb_unanchor_urb(urb);
526 } 532 }
@@ -724,6 +730,9 @@ static int btusb_send_frame(struct sk_buff *skb)
724 usb_fill_bulk_urb(urb, data->udev, pipe, 730 usb_fill_bulk_urb(urb, data->udev, pipe,
725 skb->data, skb->len, btusb_tx_complete, skb); 731 skb->data, skb->len, btusb_tx_complete, skb);
726 732
733 if (skb->priority >= HCI_PRIO_MAX - 1)
734 urb->transfer_flags = URB_ISO_ASAP;
735
727 hdev->stat.acl_tx++; 736 hdev->stat.acl_tx++;
728 break; 737 break;
729 738
@@ -767,7 +776,9 @@ skip_waking:
767 776
768 err = usb_submit_urb(urb, GFP_ATOMIC); 777 err = usb_submit_urb(urb, GFP_ATOMIC);
769 if (err < 0) { 778 if (err < 0) {
770 BT_ERR("%s urb %p submission failed", hdev->name, urb); 779 if (err != -EPERM && err != -ENODEV)
780 BT_ERR("%s urb %p submission failed (%d)",
781 hdev->name, urb, -err);
771 kfree(urb->setup_packet); 782 kfree(urb->setup_packet);
772 usb_unanchor_urb(urb); 783 usb_unanchor_urb(urb);
773 } else { 784 } else {
diff --git a/drivers/bluetooth/dtl1_cs.c b/drivers/bluetooth/dtl1_cs.c
index 5e4c2de9fc3f..969bb22e493f 100644
--- a/drivers/bluetooth/dtl1_cs.c
+++ b/drivers/bluetooth/dtl1_cs.c
@@ -551,9 +551,7 @@ static int dtl1_close(dtl1_info_t *info)
551 551
552 spin_unlock_irqrestore(&(info->lock), flags); 552 spin_unlock_irqrestore(&(info->lock), flags);
553 553
554 if (hci_unregister_dev(hdev) < 0) 554 hci_unregister_dev(hdev);
555 BT_ERR("Can't unregister HCI device %s", hdev->name);
556
557 hci_free_dev(hdev); 555 hci_free_dev(hdev);
558 556
559 return 0; 557 return 0;
diff --git a/drivers/bluetooth/hci_vhci.c b/drivers/bluetooth/hci_vhci.c
index 67c180c2c1e0..2e302a11ab55 100644
--- a/drivers/bluetooth/hci_vhci.c
+++ b/drivers/bluetooth/hci_vhci.c
@@ -264,10 +264,7 @@ static int vhci_release(struct inode *inode, struct file *file)
264 struct vhci_data *data = file->private_data; 264 struct vhci_data *data = file->private_data;
265 struct hci_dev *hdev = data->hdev; 265 struct hci_dev *hdev = data->hdev;
266 266
267 if (hci_unregister_dev(hdev) < 0) { 267 hci_unregister_dev(hdev);
268 BT_ERR("Can't unregister HCI device %s", hdev->name);
269 }
270
271 hci_free_dev(hdev); 268 hci_free_dev(hdev);
272 269
273 file->private_data = NULL; 270 file->private_data = NULL;