ASoC: Intel: Skylake: add support for tplg manifest load

Topology manifest gives information about the libraries to be
loaded. Implement the topology manifest load callback to get
this.

Signed-off-by: Kranthi G <gudishax.kranthikumar@intel.com>
Signed-off-by: Senthilnathan Veppur <senthilnathanx.veppur@intel.com>
Signed-off-by: Ramesh Babu <ramesh.babu@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Kranthi G
2016-07-26 18:06:43 +05:30
committed by Mark Brown
부모 78cdbbdac0
커밋 15ecaba914
3개의 변경된 파일37개의 추가작업 그리고 0개의 파일을 삭제

파일 보기

@@ -1789,11 +1789,33 @@ static int skl_tplg_control_load(struct snd_soc_component *cmpnt,
return 0;
}
static int skl_manifest_load(struct snd_soc_component *cmpnt,
struct snd_soc_tplg_manifest *manifest)
{
struct skl_dfw_manifest *minfo;
struct hdac_ext_bus *ebus = snd_soc_component_get_drvdata(cmpnt);
struct hdac_bus *bus = ebus_to_hbus(ebus);
struct skl *skl = ebus_to_skl(ebus);
int ret = 0;
minfo = &skl->skl_sst->manifest;
memcpy(minfo, manifest->priv.data, sizeof(struct skl_dfw_manifest));
if (minfo->lib_count > HDA_MAX_LIB) {
dev_err(bus->dev, "Exceeding max Library count. Got:%d\n",
minfo->lib_count);
ret = -EINVAL;
}
return ret;
}
static struct snd_soc_tplg_ops skl_tplg_ops = {
.widget_load = skl_tplg_widget_load,
.control_load = skl_tplg_control_load,
.bytes_ext_ops = skl_tlv_ops,
.bytes_ext_ops_count = ARRAY_SIZE(skl_tlv_ops),
.manifest = skl_manifest_load,
};
/*