ASoC: amd: vg: update acp init and deinit sequence

As part of ACP programming sequence, ACP_CONTROL and ACP_CLKMUX_SEL
registers should be updated during acp init and de-init sequence.
This patch updates register sequence during ACP init and
deinit.

Signed-off-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com>
Link: https://lore.kernel.org/r/20220223071959.13539-6-Vijendar.Mukunda@amd.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Vijendar Mukunda 2022-02-23 12:49:35 +05:30 committed by Mark Brown
parent 0c38cc1dd1
commit a9230ccc0c
No known key found for this signature in database
GPG Key ID: 24D68B725D5487D0

View File

@ -92,12 +92,14 @@ static int acp5x_init(void __iomem *acp5x_base)
pr_err("ACP5x power on failed\n");
return ret;
}
acp_writel(0x01, acp5x_base + ACP_CONTROL);
/* Reset */
ret = acp5x_reset(acp5x_base);
if (ret) {
pr_err("ACP5x reset failed\n");
return ret;
}
acp_writel(0x03, acp5x_base + ACP_CLKMUX_SEL);
acp5x_enable_interrupts(acp5x_base);
return 0;
}
@ -113,6 +115,8 @@ static int acp5x_deinit(void __iomem *acp5x_base)
pr_err("ACP5x reset failed\n");
return ret;
}
acp_writel(0x00, acp5x_base + ACP_CLKMUX_SEL);
acp_writel(0x00, acp5x_base + ACP_CONTROL);
return 0;
}