upstream: [media] v4l: omap4iss: Reset the ISS when the pipeline can't be stopped
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Wed, 9 Oct 2013 14:52:45 +0000 (11:52 -0300)
committerChanho Park <chanho61.park@samsung.com>
Tue, 18 Nov 2014 02:52:33 +0000 (11:52 +0900)
commitbccb43f7828f77b77c25f7dacc8a21bac906c31d
tree7ebc3612e4a59610d1aa1a7da4dce213d1805117
parentf94074677d4281a8ee4d628b31b879759b80987f
upstream: [media] v4l: omap4iss: Reset the ISS when the pipeline can't be stopped

When a failure to stop a module in the pipeline is detected, the only
way to recover is to reset the ISS. However, as other users can be using
a different pipeline with other modules, the ISS can't be reset
synchronously with the error detection.
Keep track of modules that have failed to stop, and reset the ISS
accordingly when the last user releases the last reference to the ISS.
Refuse to start streaming on a pipeline that contains a crashed module,
as the hardware wouldn't work anyway.
Modify the omap4iss_pipeline_set_stream() function to record the new ISS
pipeline state only when no error occurs, except when stopping the
pipeline in which case the pipeline is still marked as stopped.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
drivers/staging/media/omap4iss/iss.c
drivers/staging/media/omap4iss/iss.h
drivers/staging/media/omap4iss/iss_video.c
drivers/staging/media/omap4iss/iss_video.h