diff options
author | Sudheer Papothi <spapothi@codeaurora.org> | 2019-08-29 12:11:21 +0530 |
---|---|---|
committer | Sudheer Papothi <spapothi@codeaurora.org> | 2019-09-02 11:11:50 +0530 |
commit | 96c842a2611f9002ccec911f2d42f2535b06d761 (patch) | |
tree | fb8437833d90f72221553598416b9ba2f0910cbe /soc/swr-mstr-ctrl.h | |
parent | 47673f2f83599ce8d871a8692eb395c07a1dba28 (diff) | |
download | msm-extra-96c842a2611f9002ccec911f2d42f2535b06d761.tar.gz |
SoC: soundwire: Update debug soundwire master read/write functions
Replace debug read/write register functions with
swr_master_read/swr_master_write to support different interfaces to
access soundwire registers.
Change-Id: I377bb927ee769a18c0179045953a521d0a83057f
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Diffstat (limited to 'soc/swr-mstr-ctrl.h')
-rw-r--r-- | soc/swr-mstr-ctrl.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/soc/swr-mstr-ctrl.h b/soc/swr-mstr-ctrl.h index e05ede25..ba220784 100644 --- a/soc/swr-mstr-ctrl.h +++ b/soc/swr-mstr-ctrl.h @@ -11,6 +11,18 @@ #include <soc/qcom/pm.h> #include <soc/swr-common.h> +#ifdef CONFIG_DEBUG_FS +#include <linux/debugfs.h> +#include <linux/uaccess.h> + +#define SWR_MSTR_MAX_REG_ADDR 0x1740 +#define SWR_MSTR_START_REG_ADDR 0x00 +#define SWR_MSTR_MAX_BUF_LEN 32 +#define BYTES_PER_LINE 12 +#define SWR_MSTR_RD_BUF_LEN 8 +#define SWR_MSTR_WR_BUF_LEN 32 +#endif + #define SWR_ROW_48 0 #define SWR_ROW_50 1 #define SWR_ROW_64 2 @@ -160,6 +172,13 @@ struct swr_mstr_ctrl { u32 swr_irq_wakeup_capable; int hw_core_clk_en; int aud_core_clk_en; +#ifdef CONFIG_DEBUG_FS + struct dentry *debugfs_swrm_dent; + struct dentry *debugfs_peek; + struct dentry *debugfs_poke; + struct dentry *debugfs_reg_dump; + unsigned int read_data; +#endif }; #endif /* _SWR_WCD_CTRL_H */ |