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

Commit 7f24504d authored by Eric Laurent's avatar Eric Laurent
Browse files

audio: fix output flag test in open_output_stream

If flag AUDIO_OUTPUT_FLAG_DIRECT is set, we should only
try to open a multi channel HDMI PCM output if flag
AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD is not set.

Bug: 8174410.
Change-Id: I63fe6cabca590e70c077dea13c86c6948700e606
parent a6c11c11
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1772,6 +1772,7 @@ static int adev_open_output_stream(struct audio_hw_device *dev,

    /* Init use case and pcm_config */
    if (out->flags & AUDIO_OUTPUT_FLAG_DIRECT &&
            !(out->flags & AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD) &&
        out->devices & AUDIO_DEVICE_OUT_AUX_DIGITAL) {
        pthread_mutex_lock(&adev->lock);
        ret = read_hdmi_channel_masks(out);