Skip to content

Commit e8500a7

Browse files
simontrimmerbroonie
authored andcommitted
ASoC: cs35l56: Add an ACPI match table
An ACPI ID has been allocated for CS35L56 ASoC devices so that they can be instantiated from ACPI Device entries. Signed-off-by: Simon Trimmer <simont@opensource.cirrus.com> Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://lore.kernel.org/r/20230817112712.16637-3-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 897a6b5 commit e8500a7

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

sound/soc/codecs/cs35l56-i2c.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,19 @@ static const struct i2c_device_id cs35l56_id_i2c[] = {
6262
};
6363
MODULE_DEVICE_TABLE(i2c, cs35l56_id_i2c);
6464

65+
#ifdef CONFIG_ACPI
66+
static const struct acpi_device_id cs35l56_asoc_acpi_match[] = {
67+
{ "CSC355C", 0 },
68+
{},
69+
};
70+
MODULE_DEVICE_TABLE(acpi, cs35l56_asoc_acpi_match);
71+
#endif
72+
6573
static struct i2c_driver cs35l56_i2c_driver = {
6674
.driver = {
6775
.name = "cs35l56",
6876
.pm = &cs35l56_pm_ops_i2c_spi,
77+
.acpi_match_table = ACPI_PTR(cs35l56_asoc_acpi_match),
6978
},
7079
.id_table = cs35l56_id_i2c,
7180
.probe = cs35l56_i2c_probe,

sound/soc/codecs/cs35l56-spi.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,19 @@ static const struct spi_device_id cs35l56_id_spi[] = {
5959
};
6060
MODULE_DEVICE_TABLE(spi, cs35l56_id_spi);
6161

62+
#ifdef CONFIG_ACPI
63+
static const struct acpi_device_id cs35l56_asoc_acpi_match[] = {
64+
{ "CSC355C", 0 },
65+
{},
66+
};
67+
MODULE_DEVICE_TABLE(acpi, cs35l56_asoc_acpi_match);
68+
#endif
69+
6270
static struct spi_driver cs35l56_spi_driver = {
6371
.driver = {
6472
.name = "cs35l56",
6573
.pm = &cs35l56_pm_ops_i2c_spi,
74+
.acpi_match_table = ACPI_PTR(cs35l56_asoc_acpi_match),
6675
},
6776
.id_table = cs35l56_id_spi,
6877
.probe = cs35l56_spi_probe,

0 commit comments

Comments
 (0)