diff options
author | Zhou Song <zhous@codeaurora.org> | 2016-04-20 13:00:14 +0800 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2016-04-21 04:14:43 -0700 |
commit | 67ab751bb4dda78445be17b44176aa48a91e72a0 (patch) | |
tree | 74db47975f08b2b7b95d5dd5d9df7e6bd0d743dc | |
parent | 90f2a4c5412d1735a53c7f5341c7386c40a32aba (diff) | |
download | android_hardware_qcom_audio-67ab751bb4dda78445be17b44176aa48a91e72a0.tar.gz android_hardware_qcom_audio-67ab751bb4dda78445be17b44176aa48a91e72a0.tar.bz2 android_hardware_qcom_audio-67ab751bb4dda78445be17b44176aa48a91e72a0.zip |
hal: return with error code to avoid tearing down existing recording
When an active recording use case started by a new session, the new
session will be rejected and enter standby, but the standby status
changed to false. Due to they share the same use case, the existing
recording can be teared down during standby of the new seesion.
Return with error code when new seesion is rejected and keep it in
standby state, then standby of the new seesion won't affect the
existing one.
Change-Id: Ib3ae6a2534474247ed70589c43cb258d297c4440
CRs-Fixed: 1004601
-rwxr-xr-x | hal/audio_hw.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hal/audio_hw.c b/hal/audio_hw.c index d7a3169c..31fd7a1c 100755 --- a/hal/audio_hw.c +++ b/hal/audio_hw.c @@ -1192,7 +1192,7 @@ int start_input_stream(struct stream_in *in) if (get_usecase_from_list(adev, in->usecase) != NULL) { ALOGE("%s: use case assigned already in use, stream(%p)usecase(%d: %s)", __func__, &in->stream, in->usecase, use_case_table[in->usecase]); - goto error_config; + return -EINVAL; } in->pcm_device_id = platform_get_pcm_device_id(in->usecase, PCM_CAPTURE); |