Bluetooth: bpa10x: Free private driver data on usb shutdown
authorDavid Herrmann <dh.herrmann@googlemail.com>
Sat, 7 Jan 2012 14:47:17 +0000 (15:47 +0100)
committerJohan Hedberg <johan.hedberg@intel.com>
Mon, 13 Feb 2012 15:01:24 +0000 (17:01 +0200)
commitd25442ba4b44bf1fad50c9c2156a4ca89f269713
tree47ce9f59bd0175c15841a422942022c7f371a357
parent8381088e39d03c55552b9dfb09b9b303e96acc78
Bluetooth: bpa10x: Free private driver data on usb shutdown

Instead of waiting for the hci-device to be destroyed we now free the
private driver data on driver shutdown right away. We call
hci_unregister_dev() on driver shutdown, that means, the hci-core will
never ever call our callbacks again except the destruct callback. It
also does not access hdev->driver_data so there is no reason to keep
that alive. We simply set the destruct cb to NULL to avoid getting
called again.

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>
drivers/bluetooth/bpa10x.c