]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
Bluetooth: Fix incorrectly overriding conn->src_type
authorJohan Hedberg <johan.hedberg@intel.com>
Thu, 5 Jun 2014 09:19:54 +0000 (12:19 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 9 Jul 2014 18:21:27 +0000 (11:21 -0700)
commit035f657a1668eaf7999909d6bb7cf293b56cedba
tree1854fa6ab8024eb4be0dba2ee738b884dc36f3d1
parentf6f7bbbf4b08d6f96821029e13ef91f7c3689b57
Bluetooth: Fix incorrectly overriding conn->src_type

commit b62b65055bcc5372d5c3f4103629176cb8db3678 upstream.

The src_type member of struct hci_conn should always reflect the address
type of the src_member. It should never be overridden. There is already
code in place in the command status handler of HCI_LE_Create_Connection
to copy the right initiator address into conn->init_addr_type.

Without this patch, if privacy is enabled, we will send the wrong
address type in the SMP identity address information PDU (it'll e.g.
contain our public address but a random address type).

Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/bluetooth/hci_conn.c