summaryrefslogtreecommitdiffstats
path: root/drivers/soundwire
diff options
context:
space:
mode:
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>2019-08-06 02:55:21 +0200
committerVinod Koul <vkoul@kernel.org>2019-08-21 11:06:18 +0200
commit04592dced55a3c55eb29bd49f4fcd3e1b2ce96d6 (patch)
tree12e7be1048ffdb2af963f590d59a7db835f7b8d3 /drivers/soundwire
parentsoundwire: intel_init: add kernel module parameter to filter out links (diff)
downloadlinux-04592dced55a3c55eb29bd49f4fcd3e1b2ce96d6.tar.xz
linux-04592dced55a3c55eb29bd49f4fcd3e1b2ce96d6.zip
soundwire: cadence_master: add kernel parameter to override interrupt mask
The code has a set of defaults which may not be relevant in all cases, add kernel parameter as a helper - mostly for early board bring-up. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20190806005522.22642-17-pierre-louis.bossart@linux.intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/soundwire')
-rw-r--r--drivers/soundwire/cadence_master.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/soundwire/cadence_master.c b/drivers/soundwire/cadence_master.c
index 92d1387c6d2b..65f27fcd4f14 100644
--- a/drivers/soundwire/cadence_master.c
+++ b/drivers/soundwire/cadence_master.c
@@ -19,6 +19,10 @@
#include "bus.h"
#include "cadence_master.h"
+static int interrupt_mask;
+module_param_named(cnds_mcp_int_mask, interrupt_mask, int, 0444);
+MODULE_PARM_DESC(cdns_mcp_int_mask, "Cadence MCP IntMask");
+
#define CDNS_MCP_CONFIG 0x0
#define CDNS_MCP_CONFIG_MCMD_RETRY GENMASK(27, 24)
@@ -668,6 +672,9 @@ static int _cdns_enable_interrupt(struct sdw_cdns *cdns)
*/
mask |= CDNS_MCP_INT_IRQ;
+ if (interrupt_mask) /* parameter override */
+ mask = interrupt_mask;
+
cdns_writel(cdns, CDNS_MCP_INTMASK, mask);
return 0;