aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/bluetooth/bt3c_cs.c
diff options
context:
space:
mode:
authorDavid Herrmann <dh.herrmann@googlemail.com>2012-02-09 15:58:32 -0500
committerJohan Hedberg <johan.hedberg@intel.com>2012-02-13 10:01:37 -0500
commit155961e8001719af6d87cbcc961111e8ce477843 (patch)
tree5b2485b5a7b2074f9e01111cf8539a34f34ce2d5 /drivers/bluetooth/bt3c_cs.c
parentaa2b86d761a95068354511de755695ef6b53afc7 (diff)
Bluetooth: Remove hci_dev->driver_data
The linux device model provides dev_set/get_drvdata so we can use this to save private driver data. This also removes several unnecessary casts. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com> Acked-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Diffstat (limited to 'drivers/bluetooth/bt3c_cs.c')
-rw-r--r--drivers/bluetooth/bt3c_cs.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/bluetooth/bt3c_cs.c b/drivers/bluetooth/bt3c_cs.c
index 0e304cb4bdea..9c09d6f05dc9 100644
--- a/drivers/bluetooth/bt3c_cs.c
+++ b/drivers/bluetooth/bt3c_cs.c
@@ -389,7 +389,7 @@ static irqreturn_t bt3c_interrupt(int irq, void *dev_inst)
389 389
390static int bt3c_hci_flush(struct hci_dev *hdev) 390static int bt3c_hci_flush(struct hci_dev *hdev)
391{ 391{
392 bt3c_info_t *info = (bt3c_info_t *)(hdev->driver_data); 392 bt3c_info_t *info = hci_get_drvdata(hdev);
393 393
394 /* Drop TX queue */ 394 /* Drop TX queue */
395 skb_queue_purge(&(info->txq)); 395 skb_queue_purge(&(info->txq));
@@ -428,7 +428,7 @@ static int bt3c_hci_send_frame(struct sk_buff *skb)
428 return -ENODEV; 428 return -ENODEV;
429 } 429 }
430 430
431 info = (bt3c_info_t *) (hdev->driver_data); 431 info = hci_get_drvdata(hdev);
432 432
433 switch (bt_cb(skb)->pkt_type) { 433 switch (bt_cb(skb)->pkt_type) {
434 case HCI_COMMAND_PKT: 434 case HCI_COMMAND_PKT:
@@ -575,7 +575,7 @@ static int bt3c_open(bt3c_info_t *info)
575 info->hdev = hdev; 575 info->hdev = hdev;
576 576
577 hdev->bus = HCI_PCCARD; 577 hdev->bus = HCI_PCCARD;
578 hdev->driver_data = info; 578 hci_set_drvdata(hdev, info);
579 SET_HCIDEV_DEV(hdev, &info->p_dev->dev); 579 SET_HCIDEV_DEV(hdev, &info->p_dev->dev);
580 580
581 hdev->open = bt3c_hci_open; 581 hdev->open = bt3c_hci_open;