input: qcom-hv-haptics: reset haptics module if it's stuck in SWR mode
The haptics module would get stuck in SWR mode if SWR port is
disconnected during SWR play, and this can happen if ADSP SSR
(subsystem reset) is triggered when playing in SWR mode. This
stuck condition can be detected by checking if haptics module
has already been in SWR mode when swr-haptics driver requests
to enable SWR haptics. When it's detected, ignore SWR mode
temporarily and toggle HAPTICS_EN for a HW reset. When SWR play
is attempted again i.e. when swr_haptics driver request to turn
on SWR slave device, SWR mode would get re-enabled.
Change-Id: Ie55d331e3c689972b42dd9688f0d2b182b3fd282
Signed-off-by:
Fenglin Wu <fenglinw@codeaurora.org>
Loading
Please register or sign in to comment