Skip to content

Commit

Permalink
ASoC: qcom: add dma channel control offset to variant data
Browse files Browse the repository at this point in the history
This patch adds ability to pass dma channel control bits start offset,
which differ in differnet qcom SOCs. On apq8016 dma channel control bits
start after an offset of 1.

Tested-by: Kenneth Westfield <kwestfie@codeaurora.org>
Acked-by: Kenneth Westfield <kwestfie@codeaurora.org>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Srinivas Kandagatla authored and Mark Brown committed May 22, 2015
1 parent 3e53ac8 commit 0054055
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion sound/soc/qcom/lpass-platform.c
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ static int lpass_platform_pcmops_hw_params(struct snd_pcm_substream *substream,
unsigned int channels = params_channels(params);
unsigned int regval;
int bitwidth;
int ret, rdma_port = pcm_data->i2s_port;
int ret, rdma_port = pcm_data->i2s_port + v->rdmactl_audif_start;

bitwidth = snd_pcm_format_width(format);
if (bitwidth < 0) {
Expand Down
5 changes: 5 additions & 0 deletions sound/soc/qcom/lpass.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ struct lpass_variant {
u32 rdma_reg_stride;
u32 rdma_channels;

/**
* on SOCs like APQ8016 the channel control bits start
* at different offset to ipq806x
**/
u32 rdmactl_audif_start;
/* SOC specific intialization like clocks */
int (*init)(struct platform_device *pdev);
int (*exit)(struct platform_device *pdev);
Expand Down

0 comments on commit 0054055

Please sign in to comment.