From: Gustavo Padovan Date: Fri, 27 Sep 2013 14:56:14 +0000 (-0300) Subject: Merge git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=1025c04cecd19882e28f16c4004034b475c372c5;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git Merge git://git./linux/kernel/git/bluetooth/bluetooth Conflicts: net/bluetooth/hci_core.c --- 1025c04cecd19882e28f16c4004034b475c372c5 diff --cc net/bluetooth/hci_core.c index 3d9f02b2f010,1b66547a3ca6..4549b5cbfac5 --- a/net/bluetooth/hci_core.c +++ b/net/bluetooth/hci_core.c @@@ -1642,13 -1570,13 +1646,16 @@@ static int hci_rfkill_set_block(void *d BT_DBG("%p name %s blocked %d", hdev, hdev->name, blocked); + if (test_bit(HCI_USER_CHANNEL, &hdev->dev_flags)) + return -EBUSY; + - if (!blocked) - return 0; - - hci_dev_do_close(hdev); + if (blocked) { + set_bit(HCI_RFKILLED, &hdev->dev_flags); + if (!test_bit(HCI_SETUP, &hdev->dev_flags)) + hci_dev_do_close(hdev); + } else { + clear_bit(HCI_RFKILLED, &hdev->dev_flags); -} ++ } return 0; }