summaryrefslogtreecommitdiffstats
path: root/net/bluetooth/hci_core.c
diff options
context:
space:
mode:
authorMarcel Holtmann2013-10-11 15:19:18 +0200
committerJohan Hedberg2013-10-11 15:28:03 +0200
commit7bd8f09f69f8a190f9b8334a07bb0a9237612314 (patch)
treea5d892d5129194953e29eb9dc986f5773e59ef14 /net/bluetooth/hci_core.c
parentBluetooth: Provide hdev parameter to hci_recv_frame() driver callback (diff)
downloadkernel-qcow2-linux-7bd8f09f69f8a190f9b8334a07bb0a9237612314.tar.gz
kernel-qcow2-linux-7bd8f09f69f8a190f9b8334a07bb0a9237612314.tar.xz
kernel-qcow2-linux-7bd8f09f69f8a190f9b8334a07bb0a9237612314.zip
Bluetooth: Add hdev parameter to hdev->send driver callback
Instead of masking hdev inside the skb->dev parameter, hand it directly to the driver as a parameter to hdev->send. This makes the driver interface more clear and simpler. This patch fixes all drivers to accept and handle the new parameter of hdev->send callback. Special care has been taken for bpa10x and btusb drivers that require having skb->dev set to hdev for the URB transmit complete handlers. Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Diffstat (limited to 'net/bluetooth/hci_core.c')
-rw-r--r--net/bluetooth/hci_core.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c
index 4f0d4b443171..a097a623912a 100644
--- a/net/bluetooth/hci_core.c
+++ b/net/bluetooth/hci_core.c
@@ -2713,9 +2713,7 @@ static void hci_send_frame(struct hci_dev *hdev, struct sk_buff *skb)
/* Get rid of skb owner, prior to sending to the driver. */
skb_orphan(skb);
- skb->dev = (void *) hdev;
-
- if (hdev->send(skb) < 0)
+ if (hdev->send(hdev, skb) < 0)
BT_ERR("%s sending frame failed", hdev->name);
}