lkml.org 
[lkml]   [2013]   [May]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] TTY:vt: convert remain take_over_console's users to do_take_over_console
On Wed, May 22, 2013 at 12:18:49AM +0800, Wang YanQing wrote:
> > Except now you're spreading the brokenness that is console_lock()
> > over many more source files than the single-use case of
> > do_take_over_console().
>
> > The actual interface is take_over_console(); the _workaround_ is
> > exposing do_take_over_console() for fbcon to wrap.
>
> This _workaround_ willn't work, take_over_console will hold console_lock internal,
> but do_take_over_console need caller hold console_lock, then we can't rewrite
> do_take_over_console as a wrap base on take_over_console.
>
> But the reverse is ok. So if we have to do it, then the actual interface
> is do_take_over_console, and the "_workaround_" is exposing take_over_console
> as a wrap base on do_take_over_console.

But if we do this, then we have two version functions do the same thing except
caller/callee hold lock, I can't see much sense to have them at the same time.

Thanks.


\
 
 \ /
  Last update: 2013-05-21 19:41    [W:0.047 / U:0.024 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site