diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-11-22 17:02:09 +0900 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-12-03 16:34:09 +0900 |
commit | 78b76dbec8da6437e30519e6bbe4fb44d798addf (patch) | |
tree | adf8c7b4d0b37593645dd2c8faa9d856c13c9145 /lib/strncpy_from_user.c | |
parent | f02b0de0f0925ea6dd1c5eee0a9e7748e38af4e6 (diff) | |
download | op-kernel-dev-78b76dbec8da6437e30519e6bbe4fb44d798addf.zip op-kernel-dev-78b76dbec8da6437e30519e6bbe4fb44d798addf.tar.gz |
ASoC: wm8994: Simplify button detection code
Currently the WM8994 driver allows the WM8958 microphone detection code to
be replaced in its entirety, providing a default implementation. This
doesn't actually reflect the needs of users well. They generally wish to
replace only the accessory identification parts of the algorithm (eg,
using an external GPIO to provide the equivalent of the JACKDET support in
the WM1811A).
In preparation for supporting these users better refactor the existing code
so that we have separate identification and button detection callbacks,
selecting between them rather than using the mic_detecting flag in the
existing callback. This also simplifies the code by introducing a more
explicit state machine for the detecting and button states.
In anticipation of future refactoring the callback is left in the signature
for wm8958_mic_detect(), it will be removed at a later stage.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'lib/strncpy_from_user.c')
0 files changed, 0 insertions, 0 deletions