mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-22 21:25:25 -04:00
ASoC: rockchip: spdif: Move DT compatible table
Move rk_spdif_match DT compatible table to the usual place before the platform-driver struct definition and drop the useless of_match_ptr(), since it is fine to reference the DT id table even when OF support is disabled (which makes the driver useless anyways). Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com> Link: https://patch.msgid.link/20260203-rockchip-spdif-cleanup-and-bsp-sync-v2-2-4412016cf577@collabora.com Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
committed by
Mark Brown
parent
27b5096ef0
commit
45df1f66b9
@@ -40,29 +40,6 @@ struct rk_spdif_dev {
|
||||
struct regmap *regmap;
|
||||
};
|
||||
|
||||
static const struct of_device_id rk_spdif_match[] __maybe_unused = {
|
||||
{ .compatible = "rockchip,rk3066-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3066 },
|
||||
{ .compatible = "rockchip,rk3188-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3188 },
|
||||
{ .compatible = "rockchip,rk3228-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3288-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3288 },
|
||||
{ .compatible = "rockchip,rk3328-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3366-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3368-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3399-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3568-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{},
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, rk_spdif_match);
|
||||
|
||||
static int rk_spdif_runtime_suspend(struct device *dev)
|
||||
{
|
||||
struct rk_spdif_dev *spdif = dev_get_drvdata(dev);
|
||||
@@ -377,12 +354,35 @@ static const struct dev_pm_ops rk_spdif_pm_ops = {
|
||||
RUNTIME_PM_OPS(rk_spdif_runtime_suspend, rk_spdif_runtime_resume, NULL)
|
||||
};
|
||||
|
||||
static const struct of_device_id rk_spdif_match[] = {
|
||||
{ .compatible = "rockchip,rk3066-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3066 },
|
||||
{ .compatible = "rockchip,rk3188-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3188 },
|
||||
{ .compatible = "rockchip,rk3228-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3288-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3288 },
|
||||
{ .compatible = "rockchip,rk3328-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3366-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3368-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3399-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{ .compatible = "rockchip,rk3568-spdif",
|
||||
.data = (void *)RK_SPDIF_RK3366 },
|
||||
{},
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, rk_spdif_match);
|
||||
|
||||
static struct platform_driver rk_spdif_driver = {
|
||||
.probe = rk_spdif_probe,
|
||||
.remove = rk_spdif_remove,
|
||||
.driver = {
|
||||
.name = "rockchip-spdif",
|
||||
.of_match_table = of_match_ptr(rk_spdif_match),
|
||||
.of_match_table = rk_spdif_match,
|
||||
.pm = pm_ptr(&rk_spdif_pm_ops),
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user