mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-09 23:00:21 +00:00
Bluetooth: hci_sync: Fix not able to set force_static_address
force_static_address shall be writable while hdev is initing but is not considered powered yet since the static address is written only when powered. Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com> Tested-by: Brian Gix <brian.gix@intel.com>
This commit is contained in:
parent
e411443c32
commit
eeb1aafe97
@ -757,7 +757,7 @@ static ssize_t force_static_address_write(struct file *file,
|
|||||||
bool enable;
|
bool enable;
|
||||||
int err;
|
int err;
|
||||||
|
|
||||||
if (test_bit(HCI_UP, &hdev->flags))
|
if (hdev_is_powered(hdev))
|
||||||
return -EBUSY;
|
return -EBUSY;
|
||||||
|
|
||||||
err = kstrtobool_from_user(user_buf, count, &enable);
|
err = kstrtobool_from_user(user_buf, count, &enable);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user