diff options
Diffstat (limited to 'sound/soc/codecs/wm8711.c')
-rw-r--r-- | sound/soc/codecs/wm8711.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/sound/soc/codecs/wm8711.c b/sound/soc/codecs/wm8711.c index a537e4af6ae..8457d3cb596 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 | { |
@@ -443,8 +450,9 @@ static int __devexit wm8711_spi_remove(struct spi_device *spi) | |||
443 | 450 | ||
444 | static struct spi_driver wm8711_spi_driver = { | 451 | static struct spi_driver wm8711_spi_driver = { |
445 | .driver = { | 452 | .driver = { |
446 | .name = "wm8711-codec", | 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), |
@@ -487,8 +495,9 @@ MODULE_DEVICE_TABLE(i2c, wm8711_i2c_id); | |||
487 | 495 | ||
488 | static struct i2c_driver wm8711_i2c_driver = { | 496 | static struct i2c_driver wm8711_i2c_driver = { |
489 | .driver = { | 497 | .driver = { |
490 | .name = "wm8711-codec", | 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), |