hal: Specific Clip playing mute on 24bit USB-Headset and Display port.
- Specific Clip playing mute on 24bit USB-Headset and Display port.
- The Root Cause is that the copp is getting configured at stream
sample rate which is not supported by ADM.
- Convert stream sample rate to ADM supported sample rate for
USB-Headset and Display port.
Change-Id: I32e8b7b6f5bdbe625ca17d0e4a6cd1895f2e7f9f
diff --git a/hal/msm8974/platform.c b/hal/msm8974/platform.c
index bf66355..53dfa43 100644
--- a/hal/msm8974/platform.c
+++ b/hal/msm8974/platform.c
@@ -6816,8 +6816,9 @@
} else
*sample_rate = stream_sr;
- if (snd_device == SND_DEVICE_OUT_HDMI)
- *sample_rate = platform_get_supported_sampling_rate_on_hdmi(stream_sr);
+ if ((snd_device == SND_DEVICE_OUT_HDMI) || (snd_device == SND_DEVICE_OUT_DISPLAY_PORT) ||
+ (snd_device == SND_DEVICE_OUT_USB_HEADSET))
+ *sample_rate = platform_get_supported_copp_sampling_rate(stream_sr);
ALOGI("sn_device %d device sr %d stream sr %d copp sr %d", snd_device, device_sr, stream_sr, *sample_rate);
@@ -7627,7 +7628,7 @@
return MAX_CODEC_BACKENDS;
}
-int platform_get_supported_sampling_rate_on_hdmi(uint32_t stream_sr)
+int platform_get_supported_copp_sampling_rate(uint32_t stream_sr)
{
int sample_rate;
switch (stream_sr){