summaryrefslogtreecommitdiff
path: root/drivers/soundwire
diff options
context:
space:
mode:
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>2024-10-07 20:12:41 +0800
committerMark Brown <broonie@kernel.org>2024-10-11 12:06:57 +0100
commite0941775e6bdcf45e6e20b7ff3bb87dbb7d92fbb (patch)
treebc3e9ca2724cfbbf0c76aad7ebdd8765bf69a7aa /drivers/soundwire
parenteac79786c7397925149a1bfc4bb704777cd42a99 (diff)
downloadlwn-e0941775e6bdcf45e6e20b7ff3bb87dbb7d92fbb.tar.gz
lwn-e0941775e6bdcf45e6e20b7ff3bb87dbb7d92fbb.zip
ASoC/SoundWire: Intel: lnl: enable interrupts after first power-up/before last power-down
The HDaudio mlink support makes it more logical to couple interrupt enabling/disabling with power-up/down sequences. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Liam Girdwood <liam.r.girdwood@intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Acked-by: Vinod Koul <vkoul@kernel.org> Link: https://patch.msgid.link/20241007121241.30914-3-yung-chuan.liao@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/soundwire')
-rw-r--r--drivers/soundwire/intel_ace2x.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/soundwire/intel_ace2x.c b/drivers/soundwire/intel_ace2x.c
index fff312c6968d..3084f0ac7159 100644
--- a/drivers/soundwire/intel_ace2x.c
+++ b/drivers/soundwire/intel_ace2x.c
@@ -175,6 +175,9 @@ static int intel_link_power_up(struct sdw_intel *sdw)
__func__, ret);
goto out;
}
+
+ hdac_bus_eml_enable_interrupt_unlocked(sdw->link_res->hbus, true,
+ AZX_REG_ML_LEPTR_ID_SDW, true);
}
*shim_mask |= BIT(link_id);
@@ -201,6 +204,10 @@ static int intel_link_power_down(struct sdw_intel *sdw)
*shim_mask &= ~BIT(link_id);
+ if (!*shim_mask)
+ hdac_bus_eml_enable_interrupt_unlocked(sdw->link_res->hbus, true,
+ AZX_REG_ML_LEPTR_ID_SDW, false);
+
ret = hdac_bus_eml_sdw_power_down_unlocked(sdw->link_res->hbus, link_id);
if (ret < 0) {
dev_err(sdw->cdns.dev, "%s: hdac_bus_eml_sdw_power_down failed: %d\n",