Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Bluetooth: Notify about device registration before power on

It is important that the monitor interface gets notified about
a new device before its power on procedure has been started.

For some reason that is no longer working as expected and the power
on procedure runs first. It is safe to just notify about device
registration and trigger the power on procedure afterwards.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Acked-by: Johan Hedberg <johan.hedberg@intel.com>
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>

authored by

Marcel Holtmann and committed by
Gustavo Padovan
fbe96d6f 896ea28e

+2 -2
+2 -2
net/bluetooth/hci_core.c
··· 1754 1754 if (hdev->dev_type != HCI_AMP) 1755 1755 set_bit(HCI_AUTO_OFF, &hdev->dev_flags); 1756 1756 1757 - schedule_work(&hdev->power_on); 1758 - 1759 1757 hci_notify(hdev, HCI_DEV_REG); 1760 1758 hci_dev_hold(hdev); 1759 + 1760 + schedule_work(&hdev->power_on); 1761 1761 1762 1762 return id; 1763 1763