diff --git a/drivers/media/video/videobuf2-core.c b/drivers/media/video/videobuf2-core.c index 26cfbf5c9f8c..2e8f1df775b6 100644 --- a/drivers/media/video/videobuf2-core.c +++ b/drivers/media/video/videobuf2-core.c @@ -1096,7 +1096,7 @@ int vb2_qbuf(struct vb2_queue *q, struct v4l2_buffer *b) * beggining of qbuf processing. This way the queue status is * consistent after getting driver's lock back. */ - if (b->type == V4L2_MEMORY_USERPTR) { + if (q->memory == V4L2_MEMORY_USERPTR) { mmap_sem = ¤t->mm->mmap_sem; call_qop(q, wait_prepare, q); down_read(mmap_sem);