[PATCH 12/12] ASoC: codecs: wm8994: Make mic detect functions static

From: Amadeusz Sławiński

Date: Mon Oct 26 2026 - 16:20:23 EST


Now that all callers have been switched to snd_soc_component_set_jack(),
make wm8994_mic_detect() and wm8958_mic_detect() static and unexport
them.

Signed-off-by: Amadeusz Sławiński <amade@xxxxxxxxxx>
---
sound/soc/codecs/wm8994.c | 12 +++++-------
sound/soc/codecs/wm8994.h | 6 ------
2 files changed, 5 insertions(+), 13 deletions(-)

diff --git a/sound/soc/codecs/wm8994.c b/sound/soc/codecs/wm8994.c
index 69afba1764eb..43b5a05253d4 100644
--- a/sound/soc/codecs/wm8994.c
+++ b/sound/soc/codecs/wm8994.c
@@ -3540,8 +3540,8 @@ static void wm8994_handle_pdata(struct wm8994_priv *wm8994)
* Configuration of detection levels is available via the micbias1_lvl
* and micbias2_lvl platform data members.
*/
-int wm8994_mic_detect(struct snd_soc_component *component, struct snd_soc_jack *jack,
- int micbias)
+static int wm8994_mic_detect(struct snd_soc_component *component, struct snd_soc_jack *jack,
+ int micbias)
{
struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(component);
struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component);
@@ -3608,7 +3608,6 @@ int wm8994_mic_detect(struct snd_soc_component *component, struct snd_soc_jack *

return 0;
}
-EXPORT_SYMBOL_GPL(wm8994_mic_detect);

static void wm8994_mic_work(struct work_struct *work)
{
@@ -3959,9 +3958,9 @@ static void wm1811_jackdet_bootstrap(struct work_struct *work)
* flexiblity a callback is provided which allows a completely custom
* detection algorithm.
*/
-int wm8958_mic_detect(struct snd_soc_component *component, struct snd_soc_jack *jack,
- wm1811_micdet_cb det_cb, void *det_cb_data,
- wm1811_mic_id_cb id_cb, void *id_cb_data)
+static int wm8958_mic_detect(struct snd_soc_component *component, struct snd_soc_jack *jack,
+ wm1811_micdet_cb det_cb, void *det_cb_data,
+ wm1811_mic_id_cb id_cb, void *id_cb_data)
{
struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(component);
struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component);
@@ -4050,7 +4049,6 @@ int wm8958_mic_detect(struct snd_soc_component *component, struct snd_soc_jack *

return 0;
}
-EXPORT_SYMBOL_GPL(wm8958_mic_detect);

static void wm8958_mic_work(struct work_struct *work)
{
diff --git a/sound/soc/codecs/wm8994.h b/sound/soc/codecs/wm8994.h
index e7df0a1a2314..7ed5f5e50fc0 100644
--- a/sound/soc/codecs/wm8994.h
+++ b/sound/soc/codecs/wm8994.h
@@ -47,12 +47,6 @@ enum wm8994_vmid_mode {
typedef void (*wm1811_micdet_cb)(void *data);
typedef void (*wm1811_mic_id_cb)(void *data, u16 status);

-int wm8994_mic_detect(struct snd_soc_component *component, struct snd_soc_jack *jack,
- int micbias);
-int wm8958_mic_detect(struct snd_soc_component *component, struct snd_soc_jack *jack,
- wm1811_micdet_cb det_cb, void *det_cb_data,
- wm1811_mic_id_cb id_cb, void *id_cb_data);
-
int wm8994_vmid_mode(struct snd_soc_component *component, enum wm8994_vmid_mode mode);

int wm8958_aif_ev(struct snd_soc_dapm_widget *w,
--
2.56.0