tty: serial: qcom_geni_serial: Fix RX cancel command failure
authorsatya priya <skakit@codeaurora.org>
Tue, 11 Feb 2020 10:13:02 +0000 (15:43 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 12 Feb 2020 19:57:38 +0000 (11:57 -0800)
commit679aac5ead2f18d223554a52b543e1195e181811
treebba2e6fa3c3e28914926d096a09b24045cd9027d
parent7febbcbc48fc92e3f33863b32ed715ba4aff18c4
tty: serial: qcom_geni_serial: Fix RX cancel command failure

RX cancel command fails when BT is switched on and off multiple times.

To handle this, poll for the cancel bit in SE_GENI_S_IRQ_STATUS register
instead of SE_GENI_S_CMD_CTRL_REG.

As per the HPG update, handle the RX last bit after cancel command
and flush out the RX FIFO buffer.

Signed-off-by: satya priya <skakit@codeaurora.org>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/1581415982-8793-1-git-send-email-skakit@codeaurora.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/qcom_geni_serial.c