diff options
author | Johan Hedberg <johan.hedberg@intel.com> | 2015-02-18 14:53:54 +0200 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2015-02-19 08:44:28 +0100 |
commit | 00629e0fd56d528f0da4d9606726a4e22e576ace (patch) | |
tree | 2d46edbba4889c4ef78181d20aac8644a876d30d /net/bluetooth/hci_core.c | |
parent | 0af801b9bf34e3eb9f86a210e9928d42922f6631 (diff) | |
download | linux-00629e0fd56d528f0da4d9606726a4e22e576ace.tar.gz linux-00629e0fd56d528f0da4d9606726a4e22e576ace.tar.bz2 linux-00629e0fd56d528f0da4d9606726a4e22e576ace.zip |
Bluetooth: Add new hci_cb entries to the tail rather than the head
When processing hci_cb entries we want first registered callbacks to be
called first and later ones later. This is because eventually the L2CAP
callbacks that are part of the core will use this list and get
registered first. To keep the same order of calling L2CAP callbacks
before e.g. RFCOMM the order of elements needs to be this way.
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/bluetooth/hci_core.c')
-rw-r--r-- | net/bluetooth/hci_core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c index 980260846d25..91f557b0318a 100644 --- a/net/bluetooth/hci_core.c +++ b/net/bluetooth/hci_core.c @@ -3465,7 +3465,7 @@ int hci_register_cb(struct hci_cb *cb) BT_DBG("%p name %s", cb, cb->name); write_lock(&hci_cb_list_lock); - list_add(&cb->list, &hci_cb_list); + list_add_tail(&cb->list, &hci_cb_list); write_unlock(&hci_cb_list_lock); return 0; |