audio: Allow onError callback in any state

In practice, the AoC can crash while the stream is in
any state, thus this should be allowed for correct
handling of error conditions in the framework.

The list of states when `IStreamCallback.onError` can
be received is not enforced in VTS tests, thus no
test regressions are expected.

Bug: 339400414
Test: repro steps for simulating AoC crash in b/339400414
Change-Id: I9a52779f773307882109e159d715072de5af2ece
This commit is contained in:
Mikhail Naganov 2024-05-21 14:23:13 -07:00
parent f12a076304
commit ab222c63bc

View file

@ -51,9 +51,7 @@ digraph stream_out_async_state_machine {
DRAIN_PAUSED -> DRAINING [label="start"]; // consumer -> active
DRAIN_PAUSED -> TRANSFER_PAUSED [label="burst"]; // producer -> active
DRAIN_PAUSED -> IDLE [label="flush"]; // buffer is cleared
IDLE -> ERROR [label="←IStreamCallback.onError"];
DRAINING -> ERROR [label="←IStreamCallback.onError"];
TRANSFERRING -> ERROR [label="←IStreamCallback.onError"];
ANY_STATE -> ERROR [label="←IStreamCallback.onError"];
ANY_STATE -> CLOSED [label="→IStream*.close"];
CLOSED -> F;
}