mirror of
https://github.com/torvalds/linux.git
synced 2024-11-11 14:42:24 +00:00
Bluetooth: hci_qca: Fix uninitialized access to hdev
hdev is always allocated and not only when power control is required. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Abhishek Pandit-Subedi <abhishekpandit@chromium.org> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
This commit is contained in:
parent
755dfcbca8
commit
85e90d9391
@ -1947,8 +1947,9 @@ static int qca_serdev_probe(struct serdev_device *serdev)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
hdev = qcadev->serdev_hu.hdev;
|
||||||
|
|
||||||
if (power_ctrl_enabled) {
|
if (power_ctrl_enabled) {
|
||||||
hdev = qcadev->serdev_hu.hdev;
|
|
||||||
set_bit(HCI_QUIRK_NON_PERSISTENT_SETUP, &hdev->quirks);
|
set_bit(HCI_QUIRK_NON_PERSISTENT_SETUP, &hdev->quirks);
|
||||||
hdev->shutdown = qca_power_off;
|
hdev->shutdown = qca_power_off;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user