summaryrefslogtreecommitdiffstats
path: root/drivers/media/platform/exynos-gsc/gsc-core.c
diff options
context:
space:
mode:
authorLaurent Pinchart2014-11-01 14:32:28 +0100
committerMauro Carvalho Chehab2014-12-04 15:41:51 +0100
commit69c0e9c547817fef14871bc5c4645fad683f242e (patch)
tree1111885af6e5602910bdc1e144cd424948869cb8 /drivers/media/platform/exynos-gsc/gsc-core.c
parent[media] v4l: vb2: Fix race condition in vb2_fop_poll (diff)
downloadkernel-qcow2-linux-69c0e9c547817fef14871bc5c4645fad683f242e.tar.gz
kernel-qcow2-linux-69c0e9c547817fef14871bc5c4645fad683f242e.tar.xz
kernel-qcow2-linux-69c0e9c547817fef14871bc5c4645fad683f242e.zip
[media] v4l: vb2: Fix race condition in _vb2_fop_release
The function releases the queue if the file being released is the queue owner. The check reads the queue->owner field without taking the queue lock, creating a race condition with functions that set the queue owner, such as vb2_ioctl_reqbufs() for instance. Fix this by moving the queue->owner check within the mutex protected section. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/platform/exynos-gsc/gsc-core.c')
0 files changed, 0 insertions, 0 deletions