Re: [Linaro-mm-sig] [PATCH 4/4] dma-buf: Move code out of mutex-protected section in dma_buf_attach()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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@xxxxxxxxxxxxxxxx> 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
-- 
Daniel Vetter
Mail: daniel@xxxxxxxx
Mobile: +41 (0)79 365 57 48

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]