lkml.org 
[lkml]   [2016]   [Jun]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: initialize a mutex into locked state?
On Wed, Jun 15, 2016 at 02:23:35PM -0400, Oleg Drokin wrote:
> Hello!
>
> To my surprise I found out that it's not possible to initialise a mutex into
> a locked state.
> I discussed it with Arjan and apparently there's no fundamental reason
> not to allow this.

There is. A mutex _must_ have an owner. If you can initialize it in
locked state, you could do so statically, ie. outside of the context of
a task.


\
 
 \ /
  Last update: 2016-06-17 11:01    [W:2.213 / U:0.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site