diff options
author | Srinivasa Rao Mandadapu <quic_srivasam@quicinc.com> | 2022-02-24 21:03:43 +0530 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2022-02-24 20:21:42 +0000 |
commit | dc8d9766bc03efee4d1b6dd912659858fdf981de (patch) | |
tree | 92c63cd23b83b122eca2b87c895c014debb88605 /sound/soc/qcom/lpass.h | |
parent | 16413d5c5a2ed81d8fece1c5fe0b85752ecdbdf2 (diff) | |
download | linux-stable-dc8d9766bc03efee4d1b6dd912659858fdf981de.tar.gz linux-stable-dc8d9766bc03efee4d1b6dd912659858fdf981de.tar.bz2 linux-stable-dc8d9766bc03efee4d1b6dd912659858fdf981de.zip |
ASoC: qcom: Add register definition for codec rddma and wrdma
Add register definitions for codec read dma and write dma
lpass interface.
Signed-off-by: Srinivasa Rao Mandadapu <quic_srivasam@quicinc.com>
Co-developed-by: Venkata Prasad Potturu <quic_potturu@quicinc.com>
Signed-off-by: Venkata Prasad Potturu <quic_potturu@quicinc.com>
Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Link: https://lore.kernel.org/r/1645716828-15305-5-git-send-email-quic_srivasam@quicinc.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/qcom/lpass.h')
-rw-r--r-- | sound/soc/qcom/lpass.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/sound/soc/qcom/lpass.h b/sound/soc/qcom/lpass.h index d69a06b35157..fdcf99256ea8 100644 --- a/sound/soc/qcom/lpass.h +++ b/sound/soc/qcom/lpass.h @@ -38,6 +38,27 @@ return -EINVAL; \ } while (0) +static inline bool is_cdc_dma_port(int dai_id) +{ + switch (dai_id) { + case LPASS_CDC_DMA_RX0 ... LPASS_CDC_DMA_RX9: + case LPASS_CDC_DMA_TX0 ... LPASS_CDC_DMA_TX8: + case LPASS_CDC_DMA_VA_TX0 ... LPASS_CDC_DMA_VA_TX8: + return true; + } + return false; +} + +static inline bool is_rxtx_cdc_dma_port(int dai_id) +{ + switch (dai_id) { + case LPASS_CDC_DMA_RX0 ... LPASS_CDC_DMA_RX9: + case LPASS_CDC_DMA_TX0 ... LPASS_CDC_DMA_TX8: + return true; + } + return false; +} + struct lpaif_i2sctl { struct regmap_field *loopback; struct regmap_field *spken; |