diff --git a/audio/aidl/default/Configuration.cpp b/audio/aidl/default/Configuration.cpp index 7b2deb7431..854c7f372c 100644 --- a/audio/aidl/default/Configuration.cpp +++ b/audio/aidl/default/Configuration.cpp @@ -76,6 +76,11 @@ static AudioPortExt createDeviceExt(AudioDeviceType devType, int32_t flags, std::string connection = "") { AudioPortDeviceExt deviceExt; deviceExt.device.type.type = devType; + if (devType == AudioDeviceType::IN_MICROPHONE && connection.empty()) { + deviceExt.device.address = "bottom"; + } else if (devType == AudioDeviceType::IN_MICROPHONE_BACK && connection.empty()) { + deviceExt.device.address = "back"; + } deviceExt.device.type.connection = std::move(connection); deviceExt.flags = flags; return AudioPortExt::make(deviceExt);