mirror of
https://github.com/Evolution-X/hardware_interfaces
synced 2026-02-01 16:23:37 +00:00
audio: Fix AudioRecordTest#testTimestamp CTS on CF
After experimenting, it seems that the input poll is more stable after the PCM input on CF has just been opened. Since calling 'flush' on an input stream puts it into the 'STANDBY' state, explicitly call 'StreamAlsa::standby' after 'flush' in the primary input stream implementation. Bug: 340899868 Bug: 362852052 Bug: 372951987 Test: atest CtsMediaAudioTestCases Test: atest VtsHalAudioCoreTargetTest Change-Id: Ic1df6835ce00323ca3f0905ea46d3bc151e05fc4
This commit is contained in:
@@ -56,7 +56,9 @@ StreamPrimary::StreamPrimary(StreamContext* context, const Metadata& metadata)
|
||||
}
|
||||
|
||||
::android::status_t StreamPrimary::flush() {
|
||||
return isStubStreamOnWorker() ? mStubDriver.flush() : StreamAlsa::flush();
|
||||
RETURN_STATUS_IF_ERROR(isStubStreamOnWorker() ? mStubDriver.flush() : StreamAlsa::flush());
|
||||
// TODO(b/372951987): consider if this needs to be done from 'StreamInWorkerLogic::cycle'.
|
||||
return mIsInput ? standby() : ::android::OK;
|
||||
}
|
||||
|
||||
::android::status_t StreamPrimary::pause() {
|
||||
|
||||
Reference in New Issue
Block a user