diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-08-03 03:52:47 -0400 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-08-14 00:41:52 -0400 |
commit | 1552c8f67ea70803b18e2c7c525a8da5f90384c1 (patch) | |
tree | a3f098e0504ef3a1ab6d0fb6a92ac2e56cef8eb1 /sound/soc | |
parent | 733eef3e96726350888bd0ec1526f2561bec44ed (diff) |
ASoC: Add device tree binding for WM8711
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/codecs/wm8711.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/sound/soc/codecs/wm8711.c b/sound/soc/codecs/wm8711.c index e1db7e416675..8457d3cb5962 100644 --- a/sound/soc/codecs/wm8711.c +++ b/sound/soc/codecs/wm8711.c | |||
@@ -21,6 +21,7 @@ | |||
21 | #include <linux/platform_device.h> | 21 | #include <linux/platform_device.h> |
22 | #include <linux/spi/spi.h> | 22 | #include <linux/spi/spi.h> |
23 | #include <linux/slab.h> | 23 | #include <linux/slab.h> |
24 | #include <linux/of_device.h> | ||
24 | #include <sound/core.h> | 25 | #include <sound/core.h> |
25 | #include <sound/pcm.h> | 26 | #include <sound/pcm.h> |
26 | #include <sound/pcm_params.h> | 27 | #include <sound/pcm_params.h> |
@@ -414,6 +415,12 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8711 = { | |||
414 | .num_dapm_routes = ARRAY_SIZE(wm8711_intercon), | 415 | .num_dapm_routes = ARRAY_SIZE(wm8711_intercon), |
415 | }; | 416 | }; |
416 | 417 | ||
418 | static const struct of_device_id wm8711_of_match[] = { | ||
419 | { .compatible = "wlf,wm8711", }, | ||
420 | { } | ||
421 | }; | ||
422 | MODULE_DEVICE_TABLE(of, wm8711_of_match); | ||
423 | |||
417 | #if defined(CONFIG_SPI_MASTER) | 424 | #if defined(CONFIG_SPI_MASTER) |
418 | static int __devinit wm8711_spi_probe(struct spi_device *spi) | 425 | static int __devinit wm8711_spi_probe(struct spi_device *spi) |
419 | { | 426 | { |
@@ -445,6 +452,7 @@ static struct spi_driver wm8711_spi_driver = { | |||
445 | .driver = { | 452 | .driver = { |
446 | .name = "wm8711", | 453 | .name = "wm8711", |
447 | .owner = THIS_MODULE, | 454 | .owner = THIS_MODULE, |
455 | .of_match_table = wm8711_of_match, | ||
448 | }, | 456 | }, |
449 | .probe = wm8711_spi_probe, | 457 | .probe = wm8711_spi_probe, |
450 | .remove = __devexit_p(wm8711_spi_remove), | 458 | .remove = __devexit_p(wm8711_spi_remove), |
@@ -489,6 +497,7 @@ static struct i2c_driver wm8711_i2c_driver = { | |||
489 | .driver = { | 497 | .driver = { |
490 | .name = "wm8711", | 498 | .name = "wm8711", |
491 | .owner = THIS_MODULE, | 499 | .owner = THIS_MODULE, |
500 | .of_match_table = wm8711_of_match, | ||
492 | }, | 501 | }, |
493 | .probe = wm8711_i2c_probe, | 502 | .probe = wm8711_i2c_probe, |
494 | .remove = __devexit_p(wm8711_i2c_remove), | 503 | .remove = __devexit_p(wm8711_i2c_remove), |