summaryrefslogtreecommitdiffstats
path: root/net/bluetooth
diff options
context:
space:
mode:
authorDavid Herrmann <dh.herrmann@googlemail.com>2012-01-07 15:47:07 +0100
committerJohan Hedberg <johan.hedberg@intel.com>2012-02-13 17:01:22 +0200
commit010666a126fce7b9ecdda7209c558db21d771c56 (patch)
treeb62205772eeb78fd1d5431d48331eae98a7e96e2 /net/bluetooth
parent5a0b8159e1c65ce25382d3f5189b6a462422f065 (diff)
downloadlinux-stable-010666a126fce7b9ecdda7209c558db21d771c56.tar.gz
linux-stable-010666a126fce7b9ecdda7209c558db21d771c56.tar.bz2
linux-stable-010666a126fce7b9ecdda7209c558db21d771c56.zip
Bluetooth: Make hci-destruct callback optional
Several drivers already provide an empty callback so we can actually make this optional and then remove all those empty callbacks in the drivers. This callback isn't needed at all by most drivers as they can remove their allocated structures on device disconnect and not on hci destruction. 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 'net/bluetooth')
-rw-r--r--net/bluetooth/hci_core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c
index f84935e5cbab..f23e32a645c8 100644
--- a/net/bluetooth/hci_core.c
+++ b/net/bluetooth/hci_core.c
@@ -1551,7 +1551,7 @@ int hci_register_dev(struct hci_dev *hdev)
BT_DBG("%p name %s bus %d owner %p", hdev, hdev->name,
hdev->bus, hdev->owner);
- if (!hdev->open || !hdev->close || !hdev->destruct)
+ if (!hdev->open || !hdev->close)
return -EINVAL;
/* Do not allow HCI_AMP devices to register at index 0,