diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2013-10-09 18:52:45 +0400 |
---|---|---|
committer | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2013-12-11 15:03:51 +0400 |
commit | f3632ba850c70bf24a80295621857166e0c0b14c (patch) | |
tree | 7bbd6654d9fa6ade3ac246b148b9c9e146a79915 /drivers/staging/media/omap4iss/iss.h | |
parent | af15d025ecdf35ad1eb438595727d80155d8d28e (diff) | |
download | linux-f3632ba850c70bf24a80295621857166e0c0b14c.tar.xz |
[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>
Diffstat (limited to 'drivers/staging/media/omap4iss/iss.h')
-rw-r--r-- | drivers/staging/media/omap4iss/iss.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/staging/media/omap4iss/iss.h b/drivers/staging/media/omap4iss/iss.h index f63caaf90f33..3c1e92024513 100644 --- a/drivers/staging/media/omap4iss/iss.h +++ b/drivers/staging/media/omap4iss/iss.h @@ -77,6 +77,10 @@ struct iss_reg { u32 val; }; +/* + * struct iss_device - ISS device structure. + * @crashed: Bitmask of crashed entities (indexed by entity ID) + */ struct iss_device { struct v4l2_device v4l2_dev; struct media_device media_dev; @@ -93,6 +97,7 @@ struct iss_device { u64 raw_dmamask; struct mutex iss_mutex; /* For handling ref_count field */ + bool crashed; int has_context; int ref_count; |