Bluetooth: btnxpuart: Improve inband Independent Reset handling
authorNeeraj Sanjay Kale <neeraj.sanjaykale@nxp.com>
Thu, 10 Aug 2023 13:55:09 +0000 (19:25 +0530)
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Thu, 24 Aug 2023 19:19:33 +0000 (12:19 -0700)
commit491f9eff276012f3036f5546198cdf4a9e268284
tree3a3705a98366673013b1f4ec4e18f8eebce3d6b4
parent8b7630deb40e04901a09646f7c556373b1438b18
Bluetooth: btnxpuart: Improve inband Independent Reset handling

This improves the inband IR command handling for NXP BT chipsets.
When the IR vendor command is received, the driver injects a HW
error event, which causes a reset sequence in hci_error_reset().
The vendor IR command is sent to the controller while hci dev
is been closed, and FW is re-downloaded when nxp_setup() is
called during hci_dev_do_open().
The HCI_SETUP flag is set in nxp_hw_err() to make sure that
nxp_setup() is been called during hci_dev_do_open().

This also makes the nxp_setup() and power save functions more
generic.

Signed-off-by: Neeraj Sanjay Kale <neeraj.sanjaykale@nxp.com>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
drivers/bluetooth/btnxpuart.c