]> git.baikalelectronics.ru Git - kernel.git/commit
[media] media: exynos4-is: fix deadlock on driver probe
authorMarek Szyprowski <m.szyprowski@samsung.com>
Thu, 28 Apr 2016 10:25:03 +0000 (07:25 -0300)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Mon, 2 May 2016 13:39:26 +0000 (10:39 -0300)
commit9fabf569d4eed5784bd7b23d4aa0fe9159cdffe9
treea2dfe53bf2e5ff7f04fb28a023245d4f7fd0c094
parent64faa794a4d3f71c01dc02b127f1e54969b639b1
[media] media: exynos4-is: fix deadlock on driver probe

Commit b5cba842fe225c3f8aaa916bbac0e52d0fc312f2 ("[media] media: Always
keep a graph walk large enough around") changed
media_device_register_entity() function to take mdev->graph_mutex. This
causes deadlock in driver probe, which calls (indirectly) this function
with ->graph_mutex taken. This patch removes taking ->graph_mutex in
driver probe to avoid deadlock. Other drivers don't take ->graph_mutex
for entity registration, so this change should be safe.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Tested-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
drivers/media/platform/exynos4-is/media-dev.c