Bluetooth: Add flag to track the real advertising state
authorJohan Hedberg <johan.hedberg@intel.com>
Tue, 8 Jul 2014 12:07:47 +0000 (15:07 +0300)
committerMarcel Holtmann <marcel@holtmann.org>
Tue, 8 Jul 2014 12:22:05 +0000 (14:22 +0200)
commit66c417c1ee01398ac5ab1c749a20c4d8ba50e9a9
tree80181e7387748ebd19496e5bb8dc50265400b5d4
parenta70f4b5f14a029c14c3901f429e4d3d7e5477b4f
Bluetooth: Add flag to track the real advertising state

Having a single HCI_ADVERTISING flag is problematic since it tries to
track both the real advertising state and the corresponding mgmt
setting. To make the logic simpler and more reliable add a new flag that
only tracks the actual advertising state that has been written to the
controller.

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