Hi, > This change adds a new hci_uart proto callback entry i.e., power off. > This poweroff Callback is exposed to the drivers and called during BT OFF > immediately after port close. This will ensure that Voltages sources are > powered off after sending all the data before port close. Previously as > part of hdev shutdown callback, voltages sources are powered off. But we > have seen cases where post shutdown sequence completion some packets which > are already queued are sent to UART. As controller is powered off, UART > can’t send the data out or it is sending partial data due RTS line high. > > Signed-off-by: saluvala <saluvala@xxxxxxxxxxxxxx> this really has to stop. Read the documentation on how to submit patches and start configuring your .gitconfig correct so that you include you clear text name etc. > --- > drivers/bluetooth/hci_qca.c | 26 +++++++++++++++++++------- > drivers/bluetooth/hci_serdev.c | 3 +++ > drivers/bluetooth/hci_uart.h | 1 + > 3 files changed, 23 insertions(+), 7 deletions(-) > > diff --git a/drivers/bluetooth/hci_qca.c b/drivers/bluetooth/hci_qca.c > index dd768a8..e1dee75 100644 > --- a/drivers/bluetooth/hci_qca.c > +++ b/drivers/bluetooth/hci_qca.c > @@ -231,6 +231,7 @@ static int qca_regulator_enable(struct qca_serdev *qcadev); > static void qca_regulator_disable(struct qca_serdev *qcadev); > static void qca_power_shutdown(struct hci_uart *hu); > static int qca_power_off(struct hci_dev *hdev); > +static int qca_power_off_reg(struct hci_uart *hu); > static void qca_controller_memdump(struct work_struct *work); > > static enum qca_btsoc_type qca_soc_type(struct hci_uart *hu) > @@ -554,7 +555,6 @@ static void qca_controller_memdump_timeout(struct work_struct *work) > mutex_unlock(&qca->hci_memdump_lock); > } > > - > /* Initialize protocol */ > static int qca_open(struct hci_uart *hu) > { > @@ -1815,6 +1815,7 @@ static const struct hci_uart_proto qca_proto = { > .flush = qca_flush, > .setup = qca_setup, > .recv = qca_recv, > + .poweroff = qca_power_off_reg, > .enqueue = qca_enqueue, > .dequeue = qca_dequeue, > }; I am not extending this. Write a clean serdev only driver for this hardware. Regards Marcel