summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSyed Saba Kareem <Syed.SabaKareem@amd.com>2023-06-22 20:53:41 +0530
committerMark Brown <broonie@kernel.org>2023-06-22 23:31:27 +0100
commit3eb96217c16cb7be0fe6e1d416ff4fe47f686bea (patch)
tree48b979ac709f1ffe67c3f3f3612c0c722c1404d1
parentad60672394bd1f95c58d3d9336902f47e05126fc (diff)
ASoC: amd: acp: remove acp poweroff function
BIOS invokes ACP Power off sequence based on ACP device state. Remove redundant code from ACP PCI driver for ACP Power off sequence. Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com> Link: https://lore.kernel.org/r/Message-Id: <20230622152406.3709231-4-Syed.SabaKareem@amd.com> Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--sound/soc/amd/acp/acp-rembrandt.c25
-rw-r--r--sound/soc/amd/acp/acp-renoir.c17
2 files changed, 0 insertions, 42 deletions
diff --git a/sound/soc/amd/acp/acp-rembrandt.c b/sound/soc/amd/acp/acp-rembrandt.c
index 5c455cc04113..1b997837c7d8 100644
--- a/sound/soc/amd/acp/acp-rembrandt.c
+++ b/sound/soc/amd/acp/acp-rembrandt.c
@@ -204,23 +204,6 @@ static int acp6x_power_on(void __iomem *base)
return -ETIMEDOUT;
}
-static int acp6x_power_off(void __iomem *base)
-{
- u32 val;
- int timeout;
-
- writel(ACP_PGFSM_CNTL_POWER_OFF_MASK,
- base + ACP6X_PGFSM_CONTROL);
- timeout = 0;
- while (++timeout < 500) {
- val = readl(base + ACP6X_PGFSM_STATUS);
- if ((val & ACP_PGFSM_STATUS_MASK) == ACP_POWERED_OFF)
- return 0;
- udelay(1);
- }
- return -ETIMEDOUT;
-}
-
static int acp6x_reset(void __iomem *base)
{
u32 val;
@@ -299,14 +282,6 @@ static int rmb_acp_deinit(void __iomem *base)
}
writel(0x00, base + ACP_CONTROL);
-
- /* power off */
- ret = acp6x_power_off(base);
- if (ret) {
- pr_err("ACP power off failed\n");
- return ret;
- }
-
return 0;
}
diff --git a/sound/soc/amd/acp/acp-renoir.c b/sound/soc/amd/acp/acp-renoir.c
index b3cbc7f19ec5..f188365fe214 100644
--- a/sound/soc/amd/acp/acp-renoir.c
+++ b/sound/soc/amd/acp/acp-renoir.c
@@ -169,17 +169,6 @@ static int acp3x_power_on(void __iomem *base)
return readl_poll_timeout(base + ACP_PGFSM_STATUS, val, !val, DELAY_US, ACP_TIMEOUT);
}
-static int acp3x_power_off(void __iomem *base)
-{
- u32 val;
-
- writel(ACP_PWR_OFF_MASK, base + ACP_PGFSM_CONTROL);
-
- return readl_poll_timeout(base + ACP_PGFSM_STATUS, val,
- (val & ACP_PGFSM_STAT_MASK) == ACP_POWERED_OFF,
- DELAY_US, ACP_TIMEOUT);
-}
-
static int acp3x_reset(void __iomem *base)
{
u32 val;
@@ -246,12 +235,6 @@ static int rn_acp_deinit(void __iomem *base)
return ret;
writel(0x00, base + ACP_CONTROL);
-
- /* power off */
- ret = acp3x_power_off(base);
- if (ret)
- return ret;
-
return 0;
}
static int renoir_audio_probe(struct platform_device *pdev)