]> git.baikalelectronics.ru Git - kernel.git/commit
[media] exynos4-is: Add locking at fimc(-lite) subdev unregistered handler
authorSylwester Nawrocki <s.nawrocki@samsung.com>
Fri, 31 May 2013 14:37:25 +0000 (11:37 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Thu, 13 Jun 2013 01:01:53 +0000 (22:01 -0300)
commit3d1a2138b089ac77b99f3afc9ed8209a3ab3143b
tree99d4e314b909af97a335f9419a5b2a51dbdd4f0f
parent5143ed54ab4ccadd75d82caca342f0c774e1e7a5
[media] exynos4-is: Add locking at fimc(-lite) subdev unregistered handler

Protect the fimc/fimc-lite video nodes unregistration with their video
lock. This prevents a kernel crash when e.g. udev opens a video node
right after the driver registers it and then the driver tries to
unregister it and defers its probing. Using video_is_unregistered()
together with the video mutex allows safe unregistration of the video
nodes at any time.

Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/platform/exynos4-is/fimc-capture.c
drivers/media/platform/exynos4-is/fimc-lite.c