Commit e59fda8d authored by Johan Hedberg's avatar Johan Hedberg

Bluetooth: Fix EIR data clearing when powering off

When powering off we should assume that the EIR data isn't valid
anymore. This patch makes sure it gets cleared in hci_dev_do_close and
thereby ensures that a correct new EIR is recreated when powering on
again.
Signed-off-by: default avatarJohan Hedberg <johan.hedberg@intel.com>
Acked-by: default avatarMarcel Holtmann <marcel@holtmann.org>
parent 06199cf8
...@@ -794,6 +794,8 @@ static int hci_dev_do_close(struct hci_dev *hdev) ...@@ -794,6 +794,8 @@ static int hci_dev_do_close(struct hci_dev *hdev)
/* Clear flags */ /* Clear flags */
hdev->flags = 0; hdev->flags = 0;
memset(hdev->eir, 0, sizeof(hdev->eir));
hci_req_unlock(hdev); hci_req_unlock(hdev);
hci_dev_put(hdev); hci_dev_put(hdev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment