Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bbf251cd authored by Vineeta Srivastava's avatar Vineeta Srivastava Committed by Android Git Automerger
Browse files

am e06e66d9: Merge "audio: enable audio using tinyalsa on MSM8974" into jb-mr2-dev

* commit 'e06e66d9':
  audio: enable audio using tinyalsa on MSM8974
parents 42683cc2 e06e66d9
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -17,6 +17,10 @@ LOCAL_SHARED_LIBRARIES := \
	libaudioroute \
	libdl

ifeq ($(TARGET_BOARD_PLATFORM), msm8974)
LOCAL_CFLAGS += -DMSM8974
endif

LOCAL_C_INCLUDES += \
	external/tinyalsa/include \
	$(call include-path-for, audio-route)
+4 −0
Original line number Diff line number Diff line
@@ -70,7 +70,11 @@ static const char * const use_case_table[AUDIO_USECASE_MAX] = {

static const int pcm_device_table[AUDIO_USECASE_MAX][2] = {
    [USECASE_AUDIO_PLAYBACK_DEEP_BUFFER] = {0, 0},
#ifdef MSM8974
    [USECASE_AUDIO_PLAYBACK_LOW_LATENCY] = {15, 15},
#else
    [USECASE_AUDIO_PLAYBACK_LOW_LATENCY] = {14, 14},
#endif
    [USECASE_AUDIO_PLAYBACK_MULTI_CH] = {1, 1},
    [USECASE_AUDIO_RECORD] = {0, 0},
    [USECASE_AUDIO_RECORD_LOW_LATENCY] = {14, 14},
+8 −0
Original line number Diff line number Diff line
@@ -129,10 +129,18 @@ typedef enum {
 * We should take care of returning proper size when AudioFlinger queries for
 * the buffer size of an input/output stream
 */
#ifdef MSM8974
#define DEEP_BUFFER_OUTPUT_PERIOD_SIZE 1024
#else
#define DEEP_BUFFER_OUTPUT_PERIOD_SIZE 960
#endif
#define DEEP_BUFFER_OUTPUT_PERIOD_COUNT 8

#ifdef MSM8974
#define LOW_LATENCY_OUTPUT_PERIOD_SIZE 256
#else
#define LOW_LATENCY_OUTPUT_PERIOD_SIZE 240
#endif
#define LOW_LATENCY_OUTPUT_PERIOD_COUNT 2

#define HDMI_MULTI_PERIOD_SIZE  336