diff options
author | Cheng-Yi Chiang <cychiang@chromium.org> | 2020-09-22 14:23:16 +0800 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2020-09-22 12:48:03 +0100 |
commit | 55c5cc63ab3277aa20637dc20f6528987ac23743 (patch) | |
tree | c831f74be19b718ac67909120649e54ae64ee9fc /sound/soc/codecs | |
parent | 376dd57d88633e455da0fdf54adc1f8682ab8d95 (diff) | |
download | linux-stable-55c5cc63ab3277aa20637dc20f6528987ac23743.tar.gz linux-stable-55c5cc63ab3277aa20637dc20f6528987ac23743.tar.bz2 linux-stable-55c5cc63ab3277aa20637dc20f6528987ac23743.zip |
ASoC: hdmi-codec: Use set_jack ops to set jack
Use set_jack ops to set jack so machine drivers do not need to include
hdmi-codec.h explicitly.
Signed-off-by: Cheng-Yi Chiang <cychiang@chromium.org>
Reviewed-by: Tzung-Bi Shih <tzungbi@google.com>
Link: https://lore.kernel.org/r/20200922062316.1172935-1-cychiang@chromium.org
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs')
-rw-r--r-- | sound/soc/codecs/hdmi-codec.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/sound/soc/codecs/hdmi-codec.c b/sound/soc/codecs/hdmi-codec.c index 8c6f540533ba..403d4c6a49a8 100644 --- a/sound/soc/codecs/hdmi-codec.c +++ b/sound/soc/codecs/hdmi-codec.c @@ -698,13 +698,9 @@ static void plugged_cb(struct device *dev, bool plugged) hdmi_codec_jack_report(hcp, 0); } -/** - * hdmi_codec_set_jack_detect - register HDMI plugged callback - * @component: the hdmi-codec instance - * @jack: ASoC jack to report (dis)connection events on - */ -int hdmi_codec_set_jack_detect(struct snd_soc_component *component, - struct snd_soc_jack *jack) +static int hdmi_codec_set_jack(struct snd_soc_component *component, + struct snd_soc_jack *jack, + void *data) { struct hdmi_codec_priv *hcp = snd_soc_component_get_drvdata(component); int ret = -EOPNOTSUPP; @@ -720,7 +716,6 @@ int hdmi_codec_set_jack_detect(struct snd_soc_component *component, } return ret; } -EXPORT_SYMBOL_GPL(hdmi_codec_set_jack_detect); static int hdmi_dai_spdif_probe(struct snd_soc_dai *dai) { @@ -806,6 +801,7 @@ static const struct snd_soc_component_driver hdmi_driver = { .use_pmdown_time = 1, .endianness = 1, .non_legacy_dai_naming = 1, + .set_jack = hdmi_codec_set_jack, }; static int hdmi_codec_probe(struct platform_device *pdev) |