diff options
author | Mark Brown <broonie@kernel.org> | 2022-10-18 13:01:34 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2022-10-18 13:01:34 +0100 |
commit | a474dce8aa95752eed03436515e80425f630a9da (patch) | |
tree | 9cb242c56f39999e50aab311e128e4dd3f788709 /sound/soc | |
parent | 46234fbefe788a83edd752e1c53f83f9c083b4f3 (diff) | |
parent | 74a6a948c8fc28c8937e24178739979b3cd2ce14 (diff) | |
download | lwn-a474dce8aa95752eed03436515e80425f630a9da.tar.gz lwn-a474dce8aa95752eed03436515e80425f630a9da.zip |
ASoC: add devicetree support for WM8961 codec
Merge series from Doug Brown <doug@schmorgal.com>:
This series adds devicetree support for the Wolfson WM8961 codec. The
first patch adds a schema, the second patch hooks it up in the code, and
the third patch allows it to be selected in Kconfig.
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/codecs/Kconfig | 2 | ||||
-rw-r--r-- | sound/soc/codecs/wm8961.c | 7 |
2 files changed, 8 insertions, 1 deletions
diff --git a/sound/soc/codecs/Kconfig b/sound/soc/codecs/Kconfig index 7022e6286e6c..7a13e750751a 100644 --- a/sound/soc/codecs/Kconfig +++ b/sound/soc/codecs/Kconfig @@ -1930,7 +1930,7 @@ config SND_SOC_WM8960 depends on I2C config SND_SOC_WM8961 - tristate + tristate "Wolfson Microelectronics WM8961 CODEC" depends on I2C config SND_SOC_WM8962 diff --git a/sound/soc/codecs/wm8961.c b/sound/soc/codecs/wm8961.c index 7dc6aaf65576..a4857024711d 100644 --- a/sound/soc/codecs/wm8961.c +++ b/sound/soc/codecs/wm8961.c @@ -971,9 +971,16 @@ static const struct i2c_device_id wm8961_i2c_id[] = { }; MODULE_DEVICE_TABLE(i2c, wm8961_i2c_id); +static const struct of_device_id wm8961_of_match[] __maybe_unused = { + { .compatible = "wlf,wm8961", }, + { } +}; +MODULE_DEVICE_TABLE(of, wm8961_of_match); + static struct i2c_driver wm8961_i2c_driver = { .driver = { .name = "wm8961", + .of_match_table = of_match_ptr(wm8961_of_match), }, .probe_new = wm8961_i2c_probe, .id_table = wm8961_i2c_id, |