qpnp-qnovo: add debounce for charger
The request is to delay ok_to_qnovo for 15 seconds after a charger is
inserted.
To achive that:
Make ok_to_qnovo variable as a votable that can be voted on by
A. HW error conditions
B. Charger is ready after debounce
Moreover since there could be two chargers -usb and dc, create another
votable to track their individual debounce states. The result of this
votable will feed in to ok_to_qnovo votable as branch B above.
Also since we need to stay awake for the debounce time, create an
awake_votable and vote on it while debounce on either usb or dc is in
progress.
Change-Id: I32dc07ba16ef0515a9683f2702d317c39baa2eba
Signed-off-by:
Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Loading
Please register or sign in to comment