Skip to content

Commit

Permalink
ASoC: nau8810: add I2C device and compatible ID
Browse files Browse the repository at this point in the history
The nau8810 driver can also compatible with nau8812 and nau8814.

Signed-off-by: Seven Lee <wtli@nuvoton.com>
Link: https://lore.kernel.org/r/20200528070510.29959-1-wtli@nuvoton.com
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
LeeWeiTse-seven authored and broonie committed May 28, 2020
1 parent e6825ba commit 2b1878a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Documentation/devicetree/bindings/sound/nau8810.txt
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
NAU8810 audio CODEC
NAU8810/NAU8812/NAU8814 audio CODEC

This device supports I2C only.

Required properties:

- compatible : "nuvoton,nau8810"
- compatible : One of "nuvoton,nau8810" or "nuvoton,nau8812" or
"nuvoton,nau8814"

- reg : the I2C address of the device.

Expand Down
4 changes: 4 additions & 0 deletions sound/soc/codecs/nau8810.c
Original file line number Diff line number Diff line change
Expand Up @@ -895,13 +895,17 @@ static int nau8810_i2c_probe(struct i2c_client *i2c,

static const struct i2c_device_id nau8810_i2c_id[] = {
{ "nau8810", 0 },
{ "nau8812", 0 },
{ "nau8814", 0 },
{ }
};
MODULE_DEVICE_TABLE(i2c, nau8810_i2c_id);

#ifdef CONFIG_OF
static const struct of_device_id nau8810_of_match[] = {
{ .compatible = "nuvoton,nau8810", },
{ .compatible = "nuvoton,nau8812", },
{ .compatible = "nuvoton,nau8814", },
{ }
};
MODULE_DEVICE_TABLE(of, nau8810_of_match);
Expand Down

0 comments on commit 2b1878a

Please sign in to comment.