[PATCHv2 2/2] Bluetooth: Fix debug printing unallocated name |
|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
From: Andrei Emeltchenko <andrei.emeltchenko@xxxxxxxxx>
It does make sense to print hdev name after allocation.
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@xxxxxxxxx>
---
net/bluetooth/hci_core.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c
index 9596a82..a3c955f 100644
--- a/net/bluetooth/hci_core.c
+++ b/net/bluetooth/hci_core.c
@@ -1744,8 +1744,6 @@ int hci_register_dev(struct hci_dev *hdev)
int i, id, error;
unsigned long *inuse;
- BT_DBG("%p name %s bus %d", hdev, hdev->name, hdev->bus);
-
if (!hdev->open || !hdev->close)
return -EINVAL;
@@ -1768,6 +1766,8 @@ int hci_register_dev(struct hci_dev *hdev)
sprintf(hdev->name, "hci%d", id);
hdev->id = id;
+ BT_DBG("%p name %s bus %d", hdev, hdev->name, hdev->bus);
+
list_add_tail(&hdev->list, &hci_dev_list);
mutex_init(&hdev->lock);
--
1.7.9.1
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bluez Devel]
[Linux USB Devel]
[Video for Linux]
[Linux Audio Users]
[Photo]
[Yosemite News]
[Yosemite Photos]
[Free Online Dating]
[Bluez Devel]
[Linux Kernel]
[Linux SCSI]
[XFree86]
[Devices]
[Big List of Linux Books]