Skip to content

v4l2_codec2: decode: allow calling reset() from stop state

Right now, the reset() operation just calls stop().

When a client calls stop() followed by reset(), reset() returns a C2_BAD_STATE error. (since we are already STOPPED).

According to the framework documentation (C2Component.h), reset can only return C2_BAD_STATE when the component is in release state.

Test if we are already STOPPPED and if so, do a no-op by returning C2_OK.

Test: atest VtsHalMediaC2V1_0TargetComponentTest Change-Id: I4095c0a9db43a017d3476224d33534748e2251f5 Signed-off-by: Mattijs Korpershoek mkorpershoek@baylibre.com

Merge request reports