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

Commit 13c4954a authored by David Lin's avatar David Lin Committed by android-build-merger
Browse files

audio: do not check for mode_in_communication for voip flags

am: 6b00c231

Change-Id: I0563164199d286929476e18e0addb4f87ee21998
parents 20bd96e6 6b00c231
Loading
Loading
Loading
Loading
+2 −4
Original line number Diff line number Diff line
@@ -3687,9 +3687,8 @@ static int adev_open_output_stream(struct audio_hw_device *dev,
        out->usecase = USECASE_AUDIO_PLAYBACK_AFE_PROXY;
        out->config = pcm_config_afe_proxy_playback;
        adev->voice_tx_output = out;
    } else if ((out->dev->mode == AUDIO_MODE_IN_COMMUNICATION) &&
               (out->flags == (AUDIO_OUTPUT_FLAG_DIRECT |
                               AUDIO_OUTPUT_FLAG_VOIP_RX))) {
    } else if (out->flags == (AUDIO_OUTPUT_FLAG_DIRECT |
                              AUDIO_OUTPUT_FLAG_VOIP_RX)) {
        uint32_t buffer_size, frame_size;
        out->supported_channel_masks[0] = AUDIO_CHANNEL_OUT_MONO;
        out->channel_mask = AUDIO_CHANNEL_OUT_MONO;
@@ -4348,7 +4347,6 @@ static int adev_open_input_stream(struct audio_hw_device *dev,
            in->af_period_multiplier = 1;
            ALOGV("%s: USECASE_AUDIO_RECORD_MMAP", __func__);
        } else if (in->source == AUDIO_SOURCE_VOICE_COMMUNICATION &&
                   in->dev->mode == AUDIO_MODE_IN_COMMUNICATION &&
                   in->flags & AUDIO_INPUT_FLAG_VOIP_TX &&
                   (config->sample_rate == 8000 ||
                    config->sample_rate == 16000 ||