Diff between 671f4005d8084e04d8c59c5722a1a3da07e88db5 and f9949413d646ac6259a149c3f144cc43925b9d22
Changed Files
| File | Additions | Deletions | Status |
| android/hal-sco.c | +4 | -1 | modified |
Full Patch
diff --git a/android/hal-sco.c b/android/hal-sco.c
index 3b8920a..97cab84 100644
--- a/android/hal-sco.c
+++ b/android/hal-sco.c
@@ -661,6 +661,9 @@ static int sco_open_output_stream(struct audio_hw_device *dev,
return -ENOMEM;
}
+ if (out->cfg.rate == AUDIO_STREAM_SCO_RATE)
+ goto skip_resampler;
+
/* Channel numbers for resampler */
chan_num = 1;
@@ -693,7 +696,7 @@ static int sco_open_output_stream(struct audio_hw_device *dev,
DBG("Resampler: input %d output %d chan %d frames %u size %zd",
out->cfg.rate, AUDIO_STREAM_SCO_RATE, chan_num,
out->resample_frame_num, resample_size);
-
+skip_resampler:
*stream_out = &out->stream;
adev->out = out;