summaryrefslogtreecommitdiff
path: root/sound/soc/sof/intel/byt.c
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2022-07-05 19:11:02 +0300
committerMark Brown <broonie@kernel.org>2022-07-05 21:54:03 +0300
commit65b6851d243ff54cbd4adfb887a8af9d04b7f286 (patch)
tree154676198238c6484a4da45ca81afa99292db064 /sound/soc/sof/intel/byt.c
parent0d356c186ffd6d4c3e10abb283379d09a93d2515 (diff)
downloadlinux-65b6851d243ff54cbd4adfb887a8af9d04b7f286.tar.xz
ASoC: SOF: Intel: byt: remove duplicating driver data retrieval
device_get_match_data() in ACPI case calls similar to acpi_match_device(). Hence there is no need to duplicate the call. Just assign what is in the id->driver_data. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220705161102.76250-2-andriy.shevchenko@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sof/intel/byt.c')
-rw-r--r--sound/soc/sof/intel/byt.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/sound/soc/sof/intel/byt.c b/sound/soc/sof/intel/byt.c
index 4ed8381eceda..e6dc4ff531c3 100644
--- a/sound/soc/sof/intel/byt.c
+++ b/sound/soc/sof/intel/byt.c
@@ -465,10 +465,7 @@ static int sof_baytrail_probe(struct platform_device *pdev)
return -ENODEV;
}
- desc = device_get_match_data(&pdev->dev);
- if (!desc)
- return -ENODEV;
-
+ desc = (const struct sof_dev_desc *)id->driver_data;
if (desc == &sof_acpi_baytrail_desc && soc_intel_is_byt_cr(pdev))
desc = &sof_acpi_baytrailcr_desc;