]> git.baikalelectronics.ru Git - kernel.git/commit
Bluetooth: Remove pointless bdaddr_to_le() helper function
authorMarcel Holtmann <marcel@holtmann.org>
Sun, 13 Oct 2013 10:57:38 +0000 (03:57 -0700)
committerJohan Hedberg <johan.hedberg@intel.com>
Sun, 13 Oct 2013 14:45:55 +0000 (17:45 +0300)
commit4d41dc7cdc44e375ca0bf3cde338550e5d730764
tree0d754ad5b9675344a2b014bf88dfaae4b2c7fe39
parent3b196d2d5a5a6edaf3267708b1ea1d3beb10ce2b
Bluetooth: Remove pointless bdaddr_to_le() helper function

The bdaddr_to_le() function tries to convert the internal address
type to one that matches the HCI address type for LE. It does not
handle any address types not used by LE and in the end just make
the code a lot harder to read.

So instead of just hiding behind a magic function, just convert
the internal address type where it needs to be converted. And it
turns out that these are only two cases anyway. One when creating
new LE connections and the other when loading the long term keys.
In both cases this makes it more clear on what it going on.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
include/net/bluetooth/hci_core.h
net/bluetooth/hci_conn.c
net/bluetooth/hci_core.c
net/bluetooth/mgmt.c