lkml.org 
[lkml]   [2006]   [Nov]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: TTY layer locking design
On Sat, Nov 18, 2006 at 12:11:38AM +0200, Blaisorblade wrote:
> *) who is maintaining this aspect of code ? The only name found in MAINTAINERS
> and CREDITS is the one of James Simmons.

There is no one maintainer. I did some of the documentation and buffering
abstraction. Paul Fulghum wrote the SMP aware and clever locking bits
for the buffer handling. Since then other people have worked on the
reference locking and the current->tty races and fixed those

> *) is the current design reputed solid? I'm not only talking about the big
> kernel lock, but also about whether drivers need to reinvent (incorrectly)
> the wheel for their locking. UML drivers are very bad on this, but I've found
> difficulty both at reading the code and at finding documentation.

As of 2.6.19-rc I think the majority of the big issues are sorted

> *) there is no generic way to handle tty's which are also consoles, except
> drivers/char/vt.c - that code is written as if it were the only case where
> that applies. Instead, UML drivers are an exception to this - UML cannot use
> virtual terminals.

Untrue - many serial drivers support being consoles

> I'm trying to establish whether it is possible, for instance, for ->close to
> be called in parallel to ->write and such; in other driver layer this is

Close/Write cannot occur in parallel. The VFS guarantees this

> Also, since write must use a spinlock because it must protect from interrupt
> races, and open cannot, must we use both a mutex and a spinlock in ->write
> and similar methods? This can be avoided in other drivers.

See the existing drivers. Open can use spinlocks

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-11-18 00:19    [W:0.031 / U:7.224 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site