diff options
Diffstat (limited to 'sound/soc/tegra/tegra210_amx.c')
-rw-r--r-- | sound/soc/tegra/tegra210_amx.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/sound/soc/tegra/tegra210_amx.c b/sound/soc/tegra/tegra210_amx.c index 179876949b30..91e405909e0f 100644 --- a/sound/soc/tegra/tegra210_amx.c +++ b/sound/soc/tegra/tegra210_amx.c @@ -7,9 +7,8 @@ #include <linux/clk.h> #include <linux/device.h> #include <linux/io.h> +#include <linux/mod_devicetable.h> #include <linux/module.h> -#include <linux/of.h> -#include <linux/of_device.h> #include <linux/platform_device.h> #include <linux/pm_runtime.h> #include <linux/regmap.h> @@ -536,18 +535,12 @@ static int tegra210_amx_platform_probe(struct platform_device *pdev) struct tegra210_amx *amx; void __iomem *regs; int err; - const struct of_device_id *match; - struct tegra210_amx_soc_data *soc_data; - - match = of_match_device(tegra210_amx_of_match, dev); - - soc_data = (struct tegra210_amx_soc_data *)match->data; amx = devm_kzalloc(dev, sizeof(*amx), GFP_KERNEL); if (!amx) return -ENOMEM; - amx->soc_data = soc_data; + amx->soc_data = device_get_match_data(dev); dev_set_drvdata(dev, amx); @@ -556,7 +549,7 @@ static int tegra210_amx_platform_probe(struct platform_device *pdev) return PTR_ERR(regs); amx->regmap = devm_regmap_init_mmio(dev, regs, - soc_data->regmap_conf); + amx->soc_data->regmap_conf); if (IS_ERR(amx->regmap)) { dev_err(dev, "regmap init failed\n"); return PTR_ERR(amx->regmap); |