msm: qpnp-haptic: Process haptics asynchronously
Blocking the timed_output sysfs node due to mutex contention causes severe device wake-up latency, as a process crucial to system resume writes to the timed_output vibrator node every time the device is resumed via the fingerprint reader (fingerprint reader triggers a haptic response on success). By processing haptics asynchronously via a worker, the timed_output sysfs won't get stalled for long periods of time (>30ms), and thus the device will consistently wake from sleep faster. Signed-off-by:Sultanxda <sultanxda@gmail.com> msm: qpnp-haptic: Prevent redundant calls to disable vibrator A redundant call to disable the vibrator right before something wants to enable it results in lack of vibration. Avoid re-disabling haptics to fix this. Signed-off-by:
Sultanxda <sultanxda@gmail.com> msm: qpnp-haptic: Start shutoff timer after haptics actually start qpnp_hap_set() sometimes lags when enabling haptics, causing the shutoff timer to kill the haptics prematurely. Start the shutoff timer after haptics are enabled so that the requested duration is actually carried out. Change-Id: I91bad94d18415476b5b05c1e1a4a60ae180947df Signed-off-by:
Sultanxda <sultanxda@gmail.com>
Loading
Please register or sign in to comment