aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/platform/vimc/vimc-sensor.c
diff options
context:
space:
mode:
authorAndrĂ© Almeida <[email protected]>2019-05-30 13:19:56 +0000
committerMauro Carvalho Chehab <[email protected]>2019-06-05 16:47:08 +0000
commit3c1b9ac753e99005d7ee0a883d6e5b577ba32aa9 (patch)
treeab4def1e4d61ac9de2b8c0b8571f69298de9a799 /drivers/media/platform/vimc/vimc-sensor.c
parentmedia: media/doc: Allow sizeimage to be set by v4l clients (diff)
downloadkernel-3c1b9ac753e99005d7ee0a883d6e5b577ba32aa9.tar.gz
kernel-3c1b9ac753e99005d7ee0a883d6e5b577ba32aa9.zip
media: vimc: Remove or modify stream checks
Change the way subdevices check if the stream is running. Verify the stream pointer instead of src_frame. This makes easier to get rid of the void* and u8* that points to frames in the subdevices structs. Remove checks that s_stream does on subdevices. They are redundant since the Media Controller Framework doesn't allow two streaming on the same media pipeline at the same time. Signed-off-by: AndrĂ© Almeida <[email protected]> Acked-by: Helen Koike <[email protected]> Signed-off-by: Hans Verkuil <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Diffstat (limited to 'drivers/media/platform/vimc/vimc-sensor.c')
-rw-r--r--drivers/media/platform/vimc/vimc-sensor.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/media/platform/vimc/vimc-sensor.c b/drivers/media/platform/vimc/vimc-sensor.c
index baca9ca67ce0..d70f1a1408f1 100644
--- a/drivers/media/platform/vimc/vimc-sensor.c
+++ b/drivers/media/platform/vimc/vimc-sensor.c
@@ -141,7 +141,7 @@ static int vimc_sen_set_fmt(struct v4l2_subdev *sd,
if (fmt->which == V4L2_SUBDEV_FORMAT_ACTIVE) {
/* Do not change the format while stream is on */
- if (vsen->frame)
+ if (vsen->ved.stream)
return -EBUSY;
mf = &vsen->mbus_format;
@@ -197,10 +197,6 @@ static int vimc_sen_s_stream(struct v4l2_subdev *sd, int enable)
const struct v4l2_format_info *pix_info;
unsigned int frame_size;
- if (vsen->kthread_sen)
- /* tpg is already executing */
- return 0;
-
/* Calculate the frame size */
pix_info = v4l2_format_info(pixelformat);
frame_size = vsen->mbus_format.width * pix_info->bpp[0] *