diff options
author | Srinivas Kandagatla <srinivas.kandagatla@linaro.org> | 2019-11-15 13:27:04 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2019-11-18 16:02:34 +0300 |
commit | 51d2584a98942a6b4a0dfa183f4a9afcb8a04073 (patch) | |
tree | 0f1dcc1c425af06a1e79e6be8c73896d09f00521 /sound/soc/qcom/qdsp6/q6asm.h | |
parent | d2522335c92c090bf58531a2b696d7fe80ab2a7a (diff) | |
download | linux-51d2584a98942a6b4a0dfa183f4a9afcb8a04073.tar.xz |
ASoC: qcom: q6asm: add support to flac config
Qualcomm DSPs expect flac config to be set for flac decoders, so add the
API to program the flac config to the DSP
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Link: https://lore.kernel.org/r/20191115102705.649976-3-vkoul@kernel.org
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/qcom/qdsp6/q6asm.h')
-rw-r--r-- | sound/soc/qcom/qdsp6/q6asm.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/sound/soc/qcom/qdsp6/q6asm.h b/sound/soc/qcom/qdsp6/q6asm.h index 9f5fb573e4a0..6764f55f7078 100644 --- a/sound/soc/qcom/qdsp6/q6asm.h +++ b/sound/soc/qcom/qdsp6/q6asm.h @@ -32,6 +32,19 @@ enum { #define NO_TIMESTAMP 0xFF00 #define FORMAT_LINEAR_PCM 0x0000 +struct q6asm_flac_cfg { + u32 sample_rate; + u32 ext_sample_rate; + u32 min_frame_size; + u32 max_frame_size; + u16 stream_info_present; + u16 min_blk_size; + u16 max_blk_size; + u16 ch_cfg; + u16 sample_size; + u16 md5_sum; +}; + typedef void (*q6asm_cb) (uint32_t opcode, uint32_t token, void *payload, void *priv); struct audio_client; @@ -54,6 +67,8 @@ int q6asm_media_format_block_multi_ch_pcm(struct audio_client *ac, uint32_t rate, uint32_t channels, u8 channel_map[PCM_MAX_NUM_CHANNEL], uint16_t bits_per_sample); +int q6asm_stream_media_format_block_flac(struct audio_client *ac, + struct q6asm_flac_cfg *cfg); int q6asm_run(struct audio_client *ac, uint32_t flags, uint32_t msw_ts, uint32_t lsw_ts); int q6asm_run_nowait(struct audio_client *ac, uint32_t flags, uint32_t msw_ts, |