]> git.baikalelectronics.ru Git - kernel.git/commit
[Bluetooth] Use a more unique bus name for connections
authorMarcel Holtmann <marcel@holtmann.org>
Mon, 14 Jul 2008 18:13:51 +0000 (20:13 +0200)
committerMarcel Holtmann <marcel@holtmann.org>
Mon, 14 Jul 2008 18:13:51 +0000 (20:13 +0200)
commit6bbe43283470f6f1d92928299c166a924c6e5eef
tree4e82fafd39eb0a32bfb0a340302dd0baf15410e0
parent723720e7d9c72263b0c30ed2507731e849a5566e
[Bluetooth] Use a more unique bus name for connections

When attaching Bluetooth low-level connections to the bus, the bus name
is constructed from the remote address since at that time the connection
handle is not assigned yet. This has worked so far, but also caused a
lot of troubles. It is better to postpone the creation of the sysfs
entry to the time when the connection actually has been established
and then use its connection handle as unique identifier.

This also fixes the case where two different adapters try to connect
to the same remote device.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
net/bluetooth/hci_conn.c
net/bluetooth/hci_event.c
net/bluetooth/hci_sysfs.c