ASoC: wm8782: add device-tree matching table

This is needed when the codec is instanciated from from a device tree.

Signed-off-by: Daniel Mack <daniel@zonque.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Daniel Mack 2018-05-21 23:54:49 +02:00 committed by Mark Brown
parent 05f38281c5
commit 9e2a877467
No known key found for this signature in database
GPG Key ID: 24D68B725D5487D0
1 changed files with 9 additions and 0 deletions

View File

@ -67,9 +67,18 @@ static int wm8782_probe(struct platform_device *pdev)
&soc_component_dev_wm8782, &wm8782_dai, 1); &soc_component_dev_wm8782, &wm8782_dai, 1);
} }
#ifdef CONFIG_OF
static const struct of_device_id wm8782_of_match[] = {
{ .compatible = "wlf,wm8782", },
{ }
};
MODULE_DEVICE_TABLE(of, wm8782_of_match);
#endif
static struct platform_driver wm8782_codec_driver = { static struct platform_driver wm8782_codec_driver = {
.driver = { .driver = {
.name = "wm8782", .name = "wm8782",
.of_match_table = of_match_ptr(wm8782_of_match),
}, },
.probe = wm8782_probe, .probe = wm8782_probe,
}; };