• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/linux/linux-2.6/drivers/bluetooth/

Lines Matching defs:hdev

72 	struct hci_dev		*hdev;
156 data->hdev->name, urb, err);
201 if (!test_bit(HCI_RUNNING, &data->hdev->flags))
205 data->hdev->stat.byte_tx += skb->len;
207 data->hdev->stat.err_tx++;
252 data->hdev->name, urb, err);
266 BT_ERR("%s error in block", data->hdev->name);
279 BT_ERR("%s unexpected start block", data->hdev->name);
285 BT_ERR("%s no packet type found", data->hdev->name);
297 BT_ERR("%s event block is too short", data->hdev->name);
307 BT_ERR("%s data block is too short", data->hdev->name);
317 BT_ERR("%s audio block is too short", data->hdev->name);
325 BT_ERR("%s no memory for the packet", data->hdev->name);
329 skb->dev = (void *) data->hdev;
335 BT_ERR("%s unexpected continuation block", data->hdev->name);
363 if (!test_bit(HCI_RUNNING, &data->hdev->flags))
369 data->hdev->stat.byte_rx += count;
388 data->hdev->name);
413 data->hdev->name, urb, err);
420 static int bfusb_open(struct hci_dev *hdev)
422 struct bfusb_data *data = hdev->driver_data;
426 BT_DBG("hdev %p bfusb %p", hdev, data);
428 if (test_and_set_bit(HCI_RUNNING, &hdev->flags))
438 clear_bit(HCI_RUNNING, &hdev->flags);
446 static int bfusb_flush(struct hci_dev *hdev)
448 struct bfusb_data *data = hdev->driver_data;
450 BT_DBG("hdev %p bfusb %p", hdev, data);
457 static int bfusb_close(struct hci_dev *hdev)
459 struct bfusb_data *data = hdev->driver_data;
462 BT_DBG("hdev %p bfusb %p", hdev, data);
464 if (!test_and_clear_bit(HCI_RUNNING, &hdev->flags))
471 bfusb_flush(hdev);
478 struct hci_dev *hdev = (struct hci_dev *) skb->dev;
484 BT_DBG("hdev %p skb %p type %d len %d", hdev, skb, bt_cb(skb)->pkt_type, skb->len);
486 if (!hdev) {
487 BT_ERR("Frame for unknown HCI device (hdev=NULL)");
491 if (!test_bit(HCI_RUNNING, &hdev->flags))
494 data = hdev->driver_data;
498 hdev->stat.cmd_tx++;
501 hdev->stat.acl_tx++;
504 hdev->stat.sco_tx++;
555 static void bfusb_destruct(struct hci_dev *hdev)
557 struct bfusb_data *data = hdev->driver_data;
559 BT_DBG("hdev %p bfusb %p", hdev, data);
564 static int bfusb_ioctl(struct hci_dev *hdev, unsigned int cmd, unsigned long arg)
653 struct hci_dev *hdev;
708 hdev = hci_alloc_dev();
709 if (!hdev) {
714 data->hdev = hdev;
716 hdev->type = HCI_USB;
717 hdev->driver_data = data;
718 SET_HCIDEV_DEV(hdev, &intf->dev);
720 hdev->open = bfusb_open;
721 hdev->close = bfusb_close;
722 hdev->flush = bfusb_flush;
723 hdev->send = bfusb_send_frame;
724 hdev->destruct = bfusb_destruct;
725 hdev->ioctl = bfusb_ioctl;
727 hdev->owner = THIS_MODULE;
729 if (hci_register_dev(hdev) < 0) {
731 hci_free_dev(hdev);
752 struct hci_dev *hdev = data->hdev;
756 if (!hdev)
761 bfusb_close(hdev);
763 if (hci_unregister_dev(hdev) < 0)
764 BT_ERR("Can't unregister HCI device %s", hdev->name);
766 hci_free_dev(hdev);