From: Johan Hedberg Date: Mon, 24 Oct 2011 20:36:26 +0000 (+0200) Subject: Bluetooth: Set HCI_MGMT flag only in read_controller_info X-Git-Tag: v3.2-rc6~3^2~4^2~68^2~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=dafbde395ed560ddc3695df40f61d91c47433228;p=platform%2Fkernel%2Flinux-stable.git Bluetooth: Set HCI_MGMT flag only in read_controller_info The HCI_MGMT flag should only be set when user space requests the full controller information. This way we avoid potential issues with setting change events ariving before the actual read_controller_info command finishes. Signed-off-by: Johan Hedberg Signed-off-by: Gustavo F. Padovan --- diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c index 53e109e..99251d1 100644 --- a/net/bluetooth/mgmt.c +++ b/net/bluetooth/mgmt.c @@ -147,8 +147,6 @@ static int read_index_list(struct sock *sk) hci_del_off_timer(d); - set_bit(HCI_MGMT, &d->flags); - if (test_bit(HCI_SETUP, &d->flags)) continue;