ASoC: Intel: Skylake: Add num of cores in dsp ops

Number of dsp cores may differ for different platforms hence
adding it in dsp ops.

Signed-off-by: Dharageswari R <dharageswari.r@intel.com>
Signed-off-by: Guneshwor Singh <guneshwor.o.singh@intel.com>
Acked-By: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Dharageswari R 2017-08-02 21:51:12 +05:30 committed by Mark Brown
parent 0b06122fc8
commit 363d45385f
4 changed files with 7 additions and 3 deletions

View File

@ -584,7 +584,6 @@ int bxt_sst_dsp_init(struct device *dev, void __iomem *mmio_base, int irq,
/* set the D0i3 check */
skl->ipc.ops.check_dsp_lp_on = skl_ipc_check_D0i0;
skl->cores.count = 2;
skl->boot_complete = false;
init_waitqueue_head(&skl->boot_wait);
INIT_DELAYED_WORK(&skl->d0i3.work, bxt_set_dsp_D0i3);

View File

@ -201,6 +201,7 @@ static struct skl_dsp_loader_ops bxt_get_loader_ops(void)
static const struct skl_dsp_ops dsp_ops[] = {
{
.id = 0x9d70,
.num_cores = 2,
.loader_ops = skl_get_loader_ops,
.init = skl_sst_dsp_init,
.init_fw = skl_sst_init_fw,
@ -208,6 +209,7 @@ static const struct skl_dsp_ops dsp_ops[] = {
},
{
.id = 0x9d71,
.num_cores = 2,
.loader_ops = skl_get_loader_ops,
.init = kbl_sst_dsp_init,
.init_fw = skl_sst_init_fw,
@ -215,6 +217,7 @@ static const struct skl_dsp_ops dsp_ops[] = {
},
{
.id = 0x5a98,
.num_cores = 2,
.loader_ops = bxt_get_loader_ops,
.init = bxt_sst_dsp_init,
.init_fw = bxt_sst_init_fw,
@ -222,6 +225,7 @@ static const struct skl_dsp_ops dsp_ops[] = {
},
{
.id = 0x3198,
.num_cores = 2,
.loader_ops = bxt_get_loader_ops,
.init = bxt_sst_dsp_init,
.init_fw = bxt_sst_init_fw,
@ -275,6 +279,8 @@ int skl_init_dsp(struct skl *skl)
return ret;
skl->skl_sst->dsp_ops = ops;
skl->skl_sst->cores.count = ops->num_cores;
dev_dbg(bus->dev, "dsp registration status=%d\n", ret);
return ret;

View File

@ -563,8 +563,6 @@ int skl_sst_dsp_init(struct device *dev, void __iomem *mmio_base, int irq,
sst->fw_ops = skl_fw_ops;
skl->cores.count = 2;
return 0;
}
EXPORT_SYMBOL_GPL(skl_sst_dsp_init);

View File

@ -90,6 +90,7 @@ struct skl_machine_pdata {
struct skl_dsp_ops {
int id;
unsigned int num_cores;
struct skl_dsp_loader_ops (*loader_ops)(void);
int (*init)(struct device *dev, void __iomem *mmio_base,
int irq, const char *fw_name,