Commit c15ad605 authored by Vinod Koul's avatar Vinod Koul Committed by Mark Brown

ASoC: Intel: Skylake: check manifest size

For some platforms manifest data may not be defined, thus the private
data would not be defined as well.

So check the size of private data and proceed only if it is valid.
Signed-off-by: default avatarVinod Koul <vinod.koul@intel.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 541070ce
...@@ -2401,6 +2401,10 @@ static int skl_manifest_load(struct snd_soc_component *cmpnt, ...@@ -2401,6 +2401,10 @@ static int skl_manifest_load(struct snd_soc_component *cmpnt,
struct skl *skl = ebus_to_skl(ebus); struct skl *skl = ebus_to_skl(ebus);
int ret = 0; int ret = 0;
/* proceed only if we have private data defined */
if (manifest->priv.size == 0)
return 0;
minfo = &skl->skl_sst->manifest; minfo = &skl->skl_sst->manifest;
skl_tplg_get_manifest_data(manifest, bus->dev, minfo); skl_tplg_get_manifest_data(manifest, bus->dev, minfo);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment