aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2025-03-04 14:43:55 +0000
committerMark Brown <broonie@kernel.org>2025-03-04 14:43:55 +0000
commit24056de9976dfc33801d2574c1672d91f840277a (patch)
tree0da6d173d31c5b5617925f5c03095ab1ca599538
parentASoC: use inclusive language for (diff)
parentASoC: codecs: rt5677: Update definition of device_id tables (diff)
downloadwireguard-linux-24056de9976dfc33801d2574c1672d91f840277a.tar.xz
wireguard-linux-24056de9976dfc33801d2574c1672d91f840277a.zip
ASoC: codecs: Update device_id tables for Realtek
Merge series from Cezary Rojewski <cezary.rojewski@intel.com>: The series aims to streamline the formatting for ACPI IDs so that a single pattern can be used to identify the device. Work implicitly suggested by Andy Shevchenko - reading and learning from number of his reviews on the Linux mailing lists. Several formats do exists, however, after technical discussion PCI-based format has been selected as the recommended one. For Realtek devices, it is going to be 10ECxxxx where 10EC unambiguously identifies Realtek company whereas the following 4 hexes specify the PART_ID i.e.: the device. While at it, there shall be no comma after the terminator entry and initializing fields with 0 for statically defined structs is redundant.
-rw-r--r--sound/soc/codecs/rt1011.c6
-rw-r--r--sound/soc/codecs/rt1015.c6
-rw-r--r--sound/soc/codecs/rt1016.c6
-rw-r--r--sound/soc/codecs/rt1019.c6
-rw-r--r--sound/soc/codecs/rt1305.c8
-rw-r--r--sound/soc/codecs/rt1308.c6
-rw-r--r--sound/soc/codecs/rt1318.c6
-rw-r--r--sound/soc/codecs/rt274.c8
-rw-r--r--sound/soc/codecs/rt286.c5
-rw-r--r--sound/soc/codecs/rt298.c5
-rw-r--r--sound/soc/codecs/rt5514.c6
-rw-r--r--sound/soc/codecs/rt5640.c14
-rw-r--r--sound/soc/codecs/rt5645.c12
-rw-r--r--sound/soc/codecs/rt5651.c8
-rw-r--r--sound/soc/codecs/rt5659.c8
-rw-r--r--sound/soc/codecs/rt5660.c8
-rw-r--r--sound/soc/codecs/rt5663.c6
-rw-r--r--sound/soc/codecs/rt5665.c8
-rw-r--r--sound/soc/codecs/rt5668.c6
-rw-r--r--sound/soc/codecs/rt5670.c8
-rw-r--r--sound/soc/codecs/rt5677-spi.c3
-rw-r--r--sound/soc/codecs/rt5677.c1
-rw-r--r--sound/soc/codecs/rt5682-i2c.c6
23 files changed, 80 insertions, 76 deletions
diff --git a/sound/soc/codecs/rt1011.c b/sound/soc/codecs/rt1011.c
index 93ad078cdd25..b84dd18ddde9 100644
--- a/sound/soc/codecs/rt1011.c
+++ b/sound/soc/codecs/rt1011.c
@@ -2192,15 +2192,15 @@ static const struct regmap_config rt1011_regmap = {
#if defined(CONFIG_OF)
static const struct of_device_id rt1011_of_match[] = {
{ .compatible = "realtek,rt1011", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt1011_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt1011_acpi_match[] = {
- {"10EC1011", 0,},
- {},
+ { "10EC1011" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt1011_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt1015.c b/sound/soc/codecs/rt1015.c
index a85dd0bcf438..818b45226b72 100644
--- a/sound/soc/codecs/rt1015.c
+++ b/sound/soc/codecs/rt1015.c
@@ -1105,15 +1105,15 @@ MODULE_DEVICE_TABLE(i2c, rt1015_i2c_id);
#if defined(CONFIG_OF)
static const struct of_device_id rt1015_of_match[] = {
{ .compatible = "realtek,rt1015", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt1015_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt1015_acpi_match[] = {
- {"10EC1015", 0,},
- {},
+ { "10EC1015" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt1015_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt1016.c b/sound/soc/codecs/rt1016.c
index 2f38a35f0768..9f86f071fca8 100644
--- a/sound/soc/codecs/rt1016.c
+++ b/sound/soc/codecs/rt1016.c
@@ -616,15 +616,15 @@ MODULE_DEVICE_TABLE(i2c, rt1016_i2c_id);
#if defined(CONFIG_OF)
static const struct of_device_id rt1016_of_match[] = {
{ .compatible = "realtek,rt1016", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt1016_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt1016_acpi_match[] = {
- {"10EC1016", 0,},
- {},
+ { "10EC1016" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt1016_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt1019.c b/sound/soc/codecs/rt1019.c
index d989d06a2614..86539c6f6cc1 100644
--- a/sound/soc/codecs/rt1019.c
+++ b/sound/soc/codecs/rt1019.c
@@ -547,14 +547,14 @@ MODULE_DEVICE_TABLE(i2c, rt1019_i2c_id);
static const struct of_device_id rt1019_of_match[] __maybe_unused = {
{ .compatible = "realtek,rt1019", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt1019_of_match);
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt1019_acpi_match[] = {
- { "10EC1019", 0},
- { },
+ { "10EC1019" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt1019_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt1305.c b/sound/soc/codecs/rt1305.c
index 311a974654ff..26b7382f97ef 100644
--- a/sound/soc/codecs/rt1305.c
+++ b/sound/soc/codecs/rt1305.c
@@ -966,16 +966,16 @@ static const struct regmap_config rt1305_regmap = {
static const struct of_device_id rt1305_of_match[] = {
{ .compatible = "realtek,rt1305", },
{ .compatible = "realtek,rt1306", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt1305_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt1305_acpi_match[] = {
- {"10EC1305", 0,},
- {"10EC1306", 0,},
- {},
+ { "10EC1305" },
+ { "10EC1306" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt1305_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt1308.c b/sound/soc/codecs/rt1308.c
index 871391f8ffe1..df50b38c24b9 100644
--- a/sound/soc/codecs/rt1308.c
+++ b/sound/soc/codecs/rt1308.c
@@ -781,15 +781,15 @@ static const struct regmap_config rt1308_regmap = {
#ifdef CONFIG_OF
static const struct of_device_id rt1308_of_match[] = {
{ .compatible = "realtek,rt1308", },
- { },
+ { }
};
MODULE_DEVICE_TABLE(of, rt1308_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt1308_acpi_match[] = {
- { "10EC1308", 0, },
- { },
+ { "10EC1308" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt1308_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt1318.c b/sound/soc/codecs/rt1318.c
index e12b1e96a53a..ae01b2ce630b 100644
--- a/sound/soc/codecs/rt1318.c
+++ b/sound/soc/codecs/rt1318.c
@@ -1147,14 +1147,14 @@ MODULE_DEVICE_TABLE(i2c, rt1318_i2c_id);
static const struct of_device_id rt1318_of_match[] = {
{ .compatible = "realtek,rt1318", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt1318_of_match);
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt1318_acpi_match[] = {
- { "10EC1318", 0},
- { },
+ { "10EC1318" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt1318_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt274.c b/sound/soc/codecs/rt274.c
index 92ff78aa536b..2c055c45111f 100644
--- a/sound/soc/codecs/rt274.c
+++ b/sound/soc/codecs/rt274.c
@@ -1091,7 +1091,7 @@ static const struct regmap_config rt274_regmap = {
#ifdef CONFIG_OF
static const struct of_device_id rt274_of_match[] = {
{.compatible = "realtek,rt274"},
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt274_of_match);
#endif
@@ -1104,9 +1104,9 @@ MODULE_DEVICE_TABLE(i2c, rt274_i2c_id);
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt274_acpi_match[] = {
- { "10EC0274", 0 },
- { "INT34C2", 0 },
- {},
+ { "10EC0274" },
+ { "INT34C2" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt274_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt286.c b/sound/soc/codecs/rt286.c
index 8a4bd8d5ee39..fd8de8b49793 100644
--- a/sound/soc/codecs/rt286.c
+++ b/sound/soc/codecs/rt286.c
@@ -1083,8 +1083,9 @@ MODULE_DEVICE_TABLE(i2c, rt286_i2c_id);
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt286_acpi_match[] = {
- { "INT343A", 0 },
- {},
+ { "10EC0286" },
+ { "INT343A" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt286_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt298.c b/sound/soc/codecs/rt298.c
index b1fb8f365fc2..ee3d9291eea6 100644
--- a/sound/soc/codecs/rt298.c
+++ b/sound/soc/codecs/rt298.c
@@ -1144,8 +1144,9 @@ MODULE_DEVICE_TABLE(i2c, rt298_i2c_id);
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt298_acpi_match[] = {
- { "INT343A", 0 },
- {},
+ { "10EC0298" },
+ { "INT343A" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt298_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5514.c b/sound/soc/codecs/rt5514.c
index 9cb74962161a..a7f984b5d80f 100644
--- a/sound/soc/codecs/rt5514.c
+++ b/sound/soc/codecs/rt5514.c
@@ -1206,15 +1206,15 @@ MODULE_DEVICE_TABLE(i2c, rt5514_i2c_id);
#if defined(CONFIG_OF)
static const struct of_device_id rt5514_of_match[] = {
{ .compatible = "realtek,rt5514", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt5514_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5514_acpi_match[] = {
- { "10EC5514", 0},
- {},
+ { "10EC5514" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5514_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5640.c b/sound/soc/codecs/rt5640.c
index bf5dfcdd36d9..21a18012b4c0 100644
--- a/sound/soc/codecs/rt5640.c
+++ b/sound/soc/codecs/rt5640.c
@@ -2963,19 +2963,19 @@ MODULE_DEVICE_TABLE(i2c, rt5640_i2c_id);
static const struct of_device_id rt5640_of_match[] = {
{ .compatible = "realtek,rt5639", },
{ .compatible = "realtek,rt5640", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt5640_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5640_acpi_match[] = {
- { "INT33CA", 0 },
- { "10EC3276", 0 },
- { "10EC5640", 0 },
- { "10EC5642", 0 },
- { "INTCCFFD", 0 },
- { },
+ { "10EC3276" },
+ { "10EC5640" },
+ { "10EC5642" },
+ { "INT33CA" },
+ { "INTCCFFD" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5640_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5645.c b/sound/soc/codecs/rt5645.c
index 2d4ad416c186..2680bcce4c95 100644
--- a/sound/soc/codecs/rt5645.c
+++ b/sound/soc/codecs/rt5645.c
@@ -3660,12 +3660,12 @@ MODULE_DEVICE_TABLE(of, rt5645_of_match);
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5645_acpi_match[] = {
- { "10EC5645", 0 },
- { "10EC5648", 0 },
- { "10EC5650", 0 },
- { "10EC5640", 0 },
- { "10EC3270", 0 },
- {},
+ { "10EC3270" },
+ { "10EC5640" },
+ { "10EC5645" },
+ { "10EC5648" },
+ { "10EC5650" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5645_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5651.c b/sound/soc/codecs/rt5651.c
index 7be9f9f0f34f..9eeeba8cd6ff 100644
--- a/sound/soc/codecs/rt5651.c
+++ b/sound/soc/codecs/rt5651.c
@@ -2184,16 +2184,16 @@ static const struct regmap_config rt5651_regmap = {
#if defined(CONFIG_OF)
static const struct of_device_id rt5651_of_match[] = {
{ .compatible = "realtek,rt5651", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt5651_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5651_acpi_match[] = {
- { "10EC5651", 0 },
- { "10EC5640", 0 },
- { },
+ { "10EC5640" },
+ { "10EC5651" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5651_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5659.c b/sound/soc/codecs/rt5659.c
index 1083e7bffcfa..31b47db7b4f7 100644
--- a/sound/soc/codecs/rt5659.c
+++ b/sound/soc/codecs/rt5659.c
@@ -4315,16 +4315,16 @@ static void rt5659_i2c_shutdown(struct i2c_client *client)
static const struct of_device_id rt5659_of_match[] = {
{ .compatible = "realtek,rt5658", },
{ .compatible = "realtek,rt5659", },
- { },
+ { }
};
MODULE_DEVICE_TABLE(of, rt5659_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5659_acpi_match[] = {
- { "10EC5658", 0, },
- { "10EC5659", 0, },
- { },
+ { "10EC5658" },
+ { "10EC5659" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5659_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5660.c b/sound/soc/codecs/rt5660.c
index e335fec9fc56..82b92e83be4c 100644
--- a/sound/soc/codecs/rt5660.c
+++ b/sound/soc/codecs/rt5660.c
@@ -1232,16 +1232,16 @@ MODULE_DEVICE_TABLE(i2c, rt5660_i2c_id);
#ifdef CONFIG_OF
static const struct of_device_id rt5660_of_match[] = {
{ .compatible = "realtek,rt5660", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt5660_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5660_acpi_match[] = {
- { "10EC5660", 0 },
- { "10EC3277", 0 },
- { },
+ { "10EC3277" },
+ { "10EC5660" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5660_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5663.c b/sound/soc/codecs/rt5663.c
index b86bc0285266..45057562c0c8 100644
--- a/sound/soc/codecs/rt5663.c
+++ b/sound/soc/codecs/rt5663.c
@@ -3315,15 +3315,15 @@ MODULE_DEVICE_TABLE(i2c, rt5663_i2c_id);
#if defined(CONFIG_OF)
static const struct of_device_id rt5663_of_match[] = {
{ .compatible = "realtek,rt5663", },
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt5663_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5663_acpi_match[] = {
- { "10EC5663", 0},
- {},
+ { "10EC5663" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5663_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5665.c b/sound/soc/codecs/rt5665.c
index 7c5a03b0e918..e0d1991cffdb 100644
--- a/sound/soc/codecs/rt5665.c
+++ b/sound/soc/codecs/rt5665.c
@@ -4949,16 +4949,16 @@ static void rt5665_i2c_shutdown(struct i2c_client *client)
static const struct of_device_id rt5665_of_match[] = {
{.compatible = "realtek,rt5665"},
{.compatible = "realtek,rt5666"},
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt5665_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5665_acpi_match[] = {
- {"10EC5665", 0,},
- {"10EC5666", 0,},
- {},
+ { "10EC5665" },
+ { "10EC5666" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5665_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5668.c b/sound/soc/codecs/rt5668.c
index dbb5912e5e2c..f626453f332b 100644
--- a/sound/soc/codecs/rt5668.c
+++ b/sound/soc/codecs/rt5668.c
@@ -2598,15 +2598,15 @@ static void rt5668_i2c_shutdown(struct i2c_client *client)
#ifdef CONFIG_OF
static const struct of_device_id rt5668_of_match[] = {
{.compatible = "realtek,rt5668b"},
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt5668_of_match);
#endif
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5668_acpi_match[] = {
- {"10EC5668", 0,},
- {},
+ { "10EC5668" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5668_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5670.c b/sound/soc/codecs/rt5670.c
index 4129071f6b83..efd26082f19a 100644
--- a/sound/soc/codecs/rt5670.c
+++ b/sound/soc/codecs/rt5670.c
@@ -2880,10 +2880,10 @@ MODULE_DEVICE_TABLE(i2c, rt5670_i2c_id);
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5670_acpi_match[] = {
- { "10EC5670", 0},
- { "10EC5672", 0},
- { "10EC5640", 0}, /* quirk */
- { },
+ { "10EC5640" }, /* quirk */
+ { "10EC5670" },
+ { "10EC5672" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5670_acpi_match);
#endif
diff --git a/sound/soc/codecs/rt5677-spi.c b/sound/soc/codecs/rt5677-spi.c
index d91a2184f67c..abe0a5a95770 100644
--- a/sound/soc/codecs/rt5677-spi.c
+++ b/sound/soc/codecs/rt5677-spi.c
@@ -617,7 +617,8 @@ static int rt5677_spi_probe(struct spi_device *spi)
#ifdef CONFIG_ACPI
static const struct acpi_device_id rt5677_spi_acpi_id[] = {
- { "RT5677AA", 0 },
+ { "10EC5677" },
+ { "RT5677AA" },
{ }
};
MODULE_DEVICE_TABLE(acpi, rt5677_spi_acpi_id);
diff --git a/sound/soc/codecs/rt5677.c b/sound/soc/codecs/rt5677.c
index 753dc3c85630..6e4774148566 100644
--- a/sound/soc/codecs/rt5677.c
+++ b/sound/soc/codecs/rt5677.c
@@ -5201,6 +5201,7 @@ static const struct of_device_id rt5677_of_match[] = {
MODULE_DEVICE_TABLE(of, rt5677_of_match);
static const struct acpi_device_id rt5677_acpi_match[] = {
+ { "10EC5677", RT5677 },
{ "RT5677CE", RT5677 },
{ }
};
diff --git a/sound/soc/codecs/rt5682-i2c.c b/sound/soc/codecs/rt5682-i2c.c
index a8820435d1e0..bba987308e15 100644
--- a/sound/soc/codecs/rt5682-i2c.c
+++ b/sound/soc/codecs/rt5682-i2c.c
@@ -313,13 +313,13 @@ static void rt5682_i2c_remove(struct i2c_client *client)
static const struct of_device_id rt5682_of_match[] = {
{.compatible = "realtek,rt5682i"},
- {},
+ { }
};
MODULE_DEVICE_TABLE(of, rt5682_of_match);
static const struct acpi_device_id rt5682_acpi_match[] = {
- {"10EC5682", 0,},
- {},
+ { "10EC5682" },
+ { }
};
MODULE_DEVICE_TABLE(acpi, rt5682_acpi_match);