[media] media-entity: protect object creation/removal using spin lock
authorMauro Carvalho Chehab <mchehab@osg.samsung.com>
Wed, 9 Dec 2015 21:47:35 +0000 (19:47 -0200)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Mon, 11 Jan 2016 14:18:55 +0000 (12:18 -0200)
commita08fad1ec80c69c79b3ffb6d84968b0952d32da1
tree40b6e812ae1cbb72b83ebc0a3950e3a5add3846a
parentd47109fa45ee2dc4e0b2710a8225e6c3ac7ea9fd
[media] media-entity: protect object creation/removal using spin lock

Some parts of the media controller are using mutexes while
others are using spin locks in order to protect creation
and removal of elements in the graph. That's wrong!

Also, the V4L2 core can remove graph elements on non-interactive
context:
BUG: sleeping function called from invalid context at include/linux/sched.h:2776

Fix it by always using spin locks for graph element addition/removal,
just like entity creation/removal is protected at media-device.c

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
drivers/media/media-entity.c
include/media/media-device.h
This page took 0.026155 seconds and 5 git commands to generate.