From 28f1f38474f969107c95edefc2f3b2dfdbdccc83 Mon Sep 17 00:00:00 2001 From: Banajit Goswami Date: Mon, 21 Nov 2016 19:26:58 -0800 Subject: [PATCH 1/2] ASoC: msm: add support for different compressed formats Add support for below compressed formats and features * DTS playback * PCM capture in Compressed driver * MP2 decoder * DTS_LBR Passthrough Support * Transcode from MP3, WMA to DTS compressed * Update compress audio params. Change-Id: I595e638da78cced02142f4ee430afb7357eb336c Signed-off-by: Srikanth Uyyala Signed-off-by: Banajit Goswami Signed-off-by: Meng Wang --- include/uapi/sound/compress_params.h | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/include/uapi/sound/compress_params.h b/include/uapi/sound/compress_params.h index 69e5326fa301..733a4a2402ab 100644 --- a/include/uapi/sound/compress_params.h +++ b/include/uapi/sound/compress_params.h @@ -88,7 +88,17 @@ #define SND_AUDIOCODEC_DSD ((__u32) 0x00000012) #define SND_AUDIOCODEC_APTX ((__u32) 0x00000013) #define SND_AUDIOCODEC_TRUEHD ((__u32) 0x00000014) -#define SND_AUDIOCODEC_MAX SND_AUDIOCODEC_TRUEHD +#define SND_AUDIOCODEC_DTS_PASS_THROUGH ((__u32) 0x00000015) +#define SND_AUDIOCODEC_DTS_LBR ((__u32) 0x00000016) +#define SND_AUDIOCODEC_DTS_TRANSCODE_LOOPBACK ((__u32) 0x00000017) +#define SND_AUDIOCODEC_PASS_THROUGH ((__u32) 0x00000018) +#define SND_AUDIOCODEC_MP2 ((__u32) 0x00000019) +#define SND_AUDIOCODEC_DTS_LBR_PASS_THROUGH ((__u32) 0x0000001A) +#define SND_AUDIOCODEC_AC3 ((__u32) 0x0000001B) +#define SND_AUDIOCODEC_AC3_PASS_THROUGH ((__u32) 0x0000001C) +#define SND_AUDIOCODEC_DTS ((__u32) 0x0000001D) +#define SND_AUDIOCODEC_EAC3 ((__u32) 0x0000001F) +#define SND_AUDIOCODEC_MAX SND_AUDIOCODEC_EAC3 /* * Profile and modes are listed with bit masks. This allows for a From bc889dcc8782a44706751cfdd4f0099627a1f847 Mon Sep 17 00:00:00 2001 From: Surendar Karka Date: Mon, 20 Aug 2018 18:59:58 +0530 Subject: [PATCH 2/2] uapi: sound: latency mode support for transcode loopback Add metadata to configure latency mode for DSP transcode loopback to set legacy or low latency path. Userspace API introduced to configure the same. Change-Id: I914c68a9e9d8647530b72c42548e571b7508c423 Signed-off-by: Siddartha Shaik Signed-off-by: Surendar Karka --- include/uapi/sound/compress_offload.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/uapi/sound/compress_offload.h b/include/uapi/sound/compress_offload.h index 053b6d5cd3ba..1d11056e8b70 100644 --- a/include/uapi/sound/compress_offload.h +++ b/include/uapi/sound/compress_offload.h @@ -145,6 +145,11 @@ struct snd_compr_audio_info { #define SNDRV_COMPRESS_CLK_REC_MODE_NONE 0 #define SNDRV_COMPRESS_CLK_REC_MODE_AUTO 1 +enum sndrv_compress_latency_mode { + SNDRV_COMPRESS_LEGACY_LATENCY_MODE = 0, + SNDRV_COMPRESS_LOW_LATENCY_MODE = 1, +}; + #endif /** * enum sndrv_compress_encoder @@ -171,6 +176,7 @@ enum sndrv_compress_encoder { SNDRV_COMPRESS_START_DELAY = 7, SNDRV_COMPRESS_ENABLE_ADJUST_SESSION_CLOCK = 8, SNDRV_COMPRESS_ADJUST_SESSION_CLOCK = 9, + SNDRV_COMPRESS_LATENCY_MODE = 10, #endif }; @@ -183,6 +189,7 @@ enum sndrv_compress_encoder { #define SNDRV_COMPRESS_ENABLE_ADJUST_SESSION_CLOCK \ SNDRV_COMPRESS_ENABLE_ADJUST_SESSION_CLOCK #define SNDRV_COMPRESS_ADJUST_SESSION_CLOCK SNDRV_COMPRESS_ADJUST_SESSION_CLOCK +#define SNDRV_COMPRESS_LATENCY_MODE SNDRV_COMPRESS_LATENCY_MODE #endif /**