From 18cb56a9c9f4788c17b103dc2c87caeafbe1105e Mon Sep 17 00:00:00 2001 From: Pierre-Louis Bossart Date: Mon, 17 Jun 2024 12:05:34 +0200 Subject: [PATCH] soundwire: cadence: initialize sticky bits for Device0 Follow recommended programming flows, only Device0 sticky interrupt bits can be enabled before changing the command accept mode and doing a bus hardware reset. Signed-off-by: Pierre-Louis Bossart --- drivers/soundwire/cadence_master.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/soundwire/cadence_master.c b/drivers/soundwire/cadence_master.c index 8b4472a16e9913..3b37b1abbf29b3 100644 --- a/drivers/soundwire/cadence_master.c +++ b/drivers/soundwire/cadence_master.c @@ -1384,6 +1384,10 @@ int sdw_cdns_init(struct sdw_cdns *cdns) sdw_cdns_check_self_clearing_bits(cdns, __func__, false, 0); + /* enable sticky bits for Device0 attachment only */ + cdns_writel(cdns, CDNS_MCP_SLAVE_INTMASK0, GENMASK(1, 0)); + cdns_writel(cdns, CDNS_MCP_SLAVE_INTMASK1, 0); + /* reset msg_count to default value of FIFOLEVEL */ cdns->msg_count = cdns_readl(cdns, CDNS_MCP_FIFOLEVEL);