diff options
Diffstat (limited to 'sound/soc/codecs/wm8753.c')
-rw-r--r-- | sound/soc/codecs/wm8753.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/sound/soc/codecs/wm8753.c b/sound/soc/codecs/wm8753.c index aa091a0d818..a9504710bb6 100644 --- a/sound/soc/codecs/wm8753.c +++ b/sound/soc/codecs/wm8753.c | |||
@@ -38,6 +38,7 @@ | |||
38 | #include <linux/delay.h> | 38 | #include <linux/delay.h> |
39 | #include <linux/pm.h> | 39 | #include <linux/pm.h> |
40 | #include <linux/i2c.h> | 40 | #include <linux/i2c.h> |
41 | #include <linux/of_device.h> | ||
41 | #include <linux/platform_device.h> | 42 | #include <linux/platform_device.h> |
42 | #include <linux/spi/spi.h> | 43 | #include <linux/spi/spi.h> |
43 | #include <linux/slab.h> | 44 | #include <linux/slab.h> |
@@ -1490,6 +1491,12 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8753 = { | |||
1490 | .reg_cache_default = wm8753_reg, | 1491 | .reg_cache_default = wm8753_reg, |
1491 | }; | 1492 | }; |
1492 | 1493 | ||
1494 | static const struct of_device_id wm8753_of_match[] = { | ||
1495 | { .compatible = "wlf,wm8753", }, | ||
1496 | { } | ||
1497 | }; | ||
1498 | MODULE_DEVICE_TABLE(of, wm8753_of_match); | ||
1499 | |||
1493 | #if defined(CONFIG_SPI_MASTER) | 1500 | #if defined(CONFIG_SPI_MASTER) |
1494 | static int __devinit wm8753_spi_probe(struct spi_device *spi) | 1501 | static int __devinit wm8753_spi_probe(struct spi_device *spi) |
1495 | { | 1502 | { |
@@ -1519,8 +1526,9 @@ static int __devexit wm8753_spi_remove(struct spi_device *spi) | |||
1519 | 1526 | ||
1520 | static struct spi_driver wm8753_spi_driver = { | 1527 | static struct spi_driver wm8753_spi_driver = { |
1521 | .driver = { | 1528 | .driver = { |
1522 | .name = "wm8753-codec", | 1529 | .name = "wm8753", |
1523 | .owner = THIS_MODULE, | 1530 | .owner = THIS_MODULE, |
1531 | .of_match_table = wm8753_of_match, | ||
1524 | }, | 1532 | }, |
1525 | .probe = wm8753_spi_probe, | 1533 | .probe = wm8753_spi_probe, |
1526 | .remove = __devexit_p(wm8753_spi_remove), | 1534 | .remove = __devexit_p(wm8753_spi_remove), |
@@ -1563,8 +1571,9 @@ MODULE_DEVICE_TABLE(i2c, wm8753_i2c_id); | |||
1563 | 1571 | ||
1564 | static struct i2c_driver wm8753_i2c_driver = { | 1572 | static struct i2c_driver wm8753_i2c_driver = { |
1565 | .driver = { | 1573 | .driver = { |
1566 | .name = "wm8753-codec", | 1574 | .name = "wm8753", |
1567 | .owner = THIS_MODULE, | 1575 | .owner = THIS_MODULE, |
1576 | .of_match_table = wm8753_of_match, | ||
1568 | }, | 1577 | }, |
1569 | .probe = wm8753_i2c_probe, | 1578 | .probe = wm8753_i2c_probe, |
1570 | .remove = __devexit_p(wm8753_i2c_remove), | 1579 | .remove = __devexit_p(wm8753_i2c_remove), |