extcon: arizona: Factor out microphone impedance into a function
authorCharles Keepax <ckeepax@opensource.cirrus.com>
Mon, 9 Dec 2019 11:09:15 +0000 (11:09 +0000)
committerChanwoo Choi <cw00.choi@samsung.com>
Mon, 9 Dec 2019 11:18:15 +0000 (20:18 +0900)
commit7e14fc437c8144d1d5587d7b3a8d33e732144227
tree0ef5a3b294ee6403fa6bfff65e62298f563db9a0
parent3dfa743dcd2e39064475ff7f622d05db61b65375
extcon: arizona: Factor out microphone impedance into a function

The microphone detection handler is very long, start breaking it up
by factoring out the actual reading of the impedance value into a
separate functions. Additionally, this also fixes a minor bug and
ensures that the microphone timeout will be rescheduled in all error
cases.

Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
drivers/extcon/extcon-arizona.c