Skip to content

Commit e714c92

Browse files
Hans Verkuilmchehab
authored andcommitted
media: vivid: drop v4l2_ctrl_request_complete() from start_streaming
If start_streaming() fails and all queued buffers are returned to vb2, then do not call v4l2_ctrl_request_complete(). Nothing happened to the request and the state should remain as it was before start_streaming was called. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
1 parent dde6bdc commit e714c92

File tree

5 files changed

+0
-10
lines changed

5 files changed

+0
-10
lines changed

drivers/media/platform/vivid/vivid-sdr-cap.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -276,8 +276,6 @@ static int sdr_cap_start_streaming(struct vb2_queue *vq, unsigned count)
276276

277277
list_for_each_entry_safe(buf, tmp, &dev->sdr_cap_active, list) {
278278
list_del(&buf->list);
279-
v4l2_ctrl_request_complete(buf->vb.vb2_buf.req_obj.req,
280-
&dev->ctrl_hdl_sdr_cap);
281279
vb2_buffer_done(&buf->vb.vb2_buf,
282280
VB2_BUF_STATE_QUEUED);
283281
}

drivers/media/platform/vivid/vivid-vbi-cap.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,8 +204,6 @@ static int vbi_cap_start_streaming(struct vb2_queue *vq, unsigned count)
204204

205205
list_for_each_entry_safe(buf, tmp, &dev->vbi_cap_active, list) {
206206
list_del(&buf->list);
207-
v4l2_ctrl_request_complete(buf->vb.vb2_buf.req_obj.req,
208-
&dev->ctrl_hdl_vbi_cap);
209207
vb2_buffer_done(&buf->vb.vb2_buf,
210208
VB2_BUF_STATE_QUEUED);
211209
}

drivers/media/platform/vivid/vivid-vbi-out.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,8 +96,6 @@ static int vbi_out_start_streaming(struct vb2_queue *vq, unsigned count)
9696

9797
list_for_each_entry_safe(buf, tmp, &dev->vbi_out_active, list) {
9898
list_del(&buf->list);
99-
v4l2_ctrl_request_complete(buf->vb.vb2_buf.req_obj.req,
100-
&dev->ctrl_hdl_vbi_out);
10199
vb2_buffer_done(&buf->vb.vb2_buf,
102100
VB2_BUF_STATE_QUEUED);
103101
}

drivers/media/platform/vivid/vivid-vid-cap.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -243,8 +243,6 @@ static int vid_cap_start_streaming(struct vb2_queue *vq, unsigned count)
243243

244244
list_for_each_entry_safe(buf, tmp, &dev->vid_cap_active, list) {
245245
list_del(&buf->list);
246-
v4l2_ctrl_request_complete(buf->vb.vb2_buf.req_obj.req,
247-
&dev->ctrl_hdl_vid_cap);
248246
vb2_buffer_done(&buf->vb.vb2_buf,
249247
VB2_BUF_STATE_QUEUED);
250248
}

drivers/media/platform/vivid/vivid-vid-out.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,6 @@ static int vid_out_start_streaming(struct vb2_queue *vq, unsigned count)
162162

163163
list_for_each_entry_safe(buf, tmp, &dev->vid_out_active, list) {
164164
list_del(&buf->list);
165-
v4l2_ctrl_request_complete(buf->vb.vb2_buf.req_obj.req,
166-
&dev->ctrl_hdl_vid_out);
167165
vb2_buffer_done(&buf->vb.vb2_buf,
168166
VB2_BUF_STATE_QUEUED);
169167
}

0 commit comments

Comments
 (0)