On Thu, Jan 26, 2012 at 12:11:57PM +0000, Chris Wilson wrote:
On Thu, 26 Jan 2012 12:27:25 +0100, Laurent Pinchart laurent.pinchart@ideasonboard.com wrote:
Some fields can be set without mutex protection. Initialize them before locking the mutex.
struct mutex lock is described as
/* mutex to serialize list manipulation and other ops */
maybe now is a good time to be a little more descriptive in what that mutex is meant to protect and sprinkle enforcement throughout the code as a means of documentation.
As, sore spot there. I think the current locking scheme is rather much still in flux. I think we need to pull out callbacks to the exporter out from the dma_buf mutex because otherwise we won't be able to avoid deadlocks.
I think we'll need to wait for 1-2 exporters to show up in upstream until we can clarify this. But it is very much on my list. -Daniel