am 4c1b10d3: hal: MBDRC: send MBDRC step level only for speaker device
* commit '4c1b10d3b67414b7931ffcbdbd6de2776d251ef2':
hal: MBDRC: send MBDRC step level only for speaker device
diff --git a/post_proc/volume_listener.c b/post_proc/volume_listener.c
index e0193dd..2759bea 100644
--- a/post_proc/volume_listener.c
+++ b/post_proc/volume_listener.c
@@ -420,7 +420,7 @@
// After changing the state and if device is speaker
// recalculate gain dep cal level
- if (context->dev_id & AUDIO_DEVICE_OUT_SPEAKER) {
+ if (context->dev_id == AUDIO_DEVICE_OUT_SPEAKER) {
check_and_set_gain_dep_cal();
}
@@ -447,7 +447,7 @@
// After changing the state and if device is speaker
// recalculate gain dep cal level
- if (context->dev_id & AUDIO_DEVICE_OUT_SPEAKER) {
+ if (context->dev_id == AUDIO_DEVICE_OUT_SPEAKER) {
check_and_set_gain_dep_cal();
}
@@ -478,8 +478,8 @@
__func__, context->dev_id, new_device);
// check if old or new device is speaker
- if ((context->dev_id & AUDIO_DEVICE_OUT_SPEAKER) ||
- (new_device & AUDIO_DEVICE_OUT_SPEAKER)) {
+ if ((context->dev_id == AUDIO_DEVICE_OUT_SPEAKER) ||
+ (new_device == AUDIO_DEVICE_OUT_SPEAKER)) {
recompute_gain_dep_cal_Level = true;
}
@@ -504,7 +504,7 @@
goto exit;
}
- if (context->dev_id & AUDIO_DEVICE_OUT_SPEAKER) {
+ if (context->dev_id == AUDIO_DEVICE_OUT_SPEAKER) {
recompute_gain_dep_cal_Level = true;
}
@@ -682,7 +682,7 @@
ALOGV("--- Found something to remove ---");
list_remove(&context->effect_list_node);
PRINT_STREAM_TYPE(context->stream_type);
- if (context->dev_id && AUDIO_DEVICE_OUT_SPEAKER) {
+ if (context->dev_id == AUDIO_DEVICE_OUT_SPEAKER) {
recompute_flag = true;
}
free(context);