hal: Allow hal to open Telephony RX as attached device
- Incall recording and USB voice call does not work as
Telephony RX is not available device. It is default
attached device and policy should be able to open input
stream with this device.
- Change is to allow opening Telephony RX even if its
not in call to serve as default attached device.
Change-Id: I239cede58141dfe3faf7f06a495cc2824f201a58
diff --git a/hal/audio_hw.c b/hal/audio_hw.c
index c99b449..61159ae 100644
--- a/hal/audio_hw.c
+++ b/hal/audio_hw.c
@@ -7362,13 +7362,6 @@
in->bit_width = 16;
in->af_period_multiplier = 1;
- /* Update config params with the requested sample rate and channels */
- if ((in->device == AUDIO_DEVICE_IN_TELEPHONY_RX) &&
- (adev->mode != AUDIO_MODE_IN_CALL)) {
- ret = -EINVAL;
- goto err_open;
- }
-
if (is_usb_dev && may_use_hifi_record) {
/* HiFi record selects an appropriate format, channel, rate combo
depending on sink capabilities*/