summaryrefslogtreecommitdiff
path: root/drivers/soundwire/cadence_master.h
diff options
context:
space:
mode:
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>2021-07-14 11:22:08 +0800
committerVinod Koul <vkoul@kernel.org>2021-08-02 11:08:22 +0530
commit8fba8acd399b70aeb262983d32baa9cbbf7dc981 (patch)
tree3f667b3add0c78e26510f59acac3cb2f337bacca /drivers/soundwire/cadence_master.h
parent24f08b3aa5a5e42977c5a1d711d5cb7d9adbd94d (diff)
soundwire: cadence: add debugfs interface for PDI loopbacks
For debug, it's interesting to create a loopback stream for each link and use debugfs to set a source and target PDI. The target PDI would need to be an RX port and use the same register configurations as the source PDI. This capability allows e.g. for the headphone playback stream to be snooped on the headset capture stream, or alternatively for the addition of a dedicated loopback stream, in addition of regular capture for that link. This patch only adds the debugfs part, the port/PDI handling will be handled in the next patches. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://lore.kernel.org/r/20210714032209.11284-10-yung-chuan.liao@linux.intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/soundwire/cadence_master.h')
-rw-r--r--drivers/soundwire/cadence_master.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/soundwire/cadence_master.h b/drivers/soundwire/cadence_master.h
index b54c161a837f..e587aede63bf 100644
--- a/drivers/soundwire/cadence_master.h
+++ b/drivers/soundwire/cadence_master.h
@@ -129,6 +129,9 @@ struct sdw_cdns {
struct sdw_cdns_streams pcm;
struct sdw_cdns_streams pdm;
+ int pdi_loopback_source;
+ int pdi_loopback_target;
+
void __iomem *registers;
bool link_up;