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

Commit a1d008ef authored by vivek mehta's avatar vivek mehta Committed by Steve Kondik
Browse files

hal: add support to send compress offload fragment size

In case of compress offload, add support to set offload fragment size.

Change-Id: Ie23803c8d1d26b40a6a61c0d4e7d61e3aba5c86f
parent 8c2602ac
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -2228,6 +2228,14 @@ uint32_t platform_get_compress_offload_buffer_size(audio_offload_info_t* info)
        fragment_size =  atoi(value) * 1024;
    }

    /* Use incoming offload buffer size if default buffer size is less */
    if ((info != NULL) && (fragment_size < info->offload_buffer_size)) {
        ALOGI("%s:: Overwriting offload buffer size default:%d new:%d", __func__,
              fragment_size,
              info->offload_buffer_size);
        fragment_size = info->offload_buffer_size;
    }

    // For FLAC use max size since it is loss less, and has sampling rates
    // upto 192kHZ
    if (info != NULL && !info->has_video &&