Merge git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth
authorGustavo Padovan <gustavo.padovan@collabora.co.uk>
Fri, 27 Sep 2013 14:56:14 +0000 (11:56 -0300)
committerGustavo Padovan <gustavo.padovan@collabora.co.uk>
Fri, 27 Sep 2013 14:56:14 +0000 (11:56 -0300)
Conflicts:
net/bluetooth/hci_core.c

1  2 
include/net/bluetooth/hci.h
net/bluetooth/hci_core.c
net/bluetooth/hci_event.c
net/bluetooth/l2cap_core.c

Simple merge
@@@ -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 (!blocked)
-               return 0;
-       hci_dev_do_close(hdev);
 +      if (test_bit(HCI_USER_CHANNEL, &hdev->dev_flags))
 +              return -EBUSY;
 +
 -}
+       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;
  }
Simple merge
Simple merge