Re: [PATCH 1/1] Char: tty_io, fix closecount counting

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Jiri Slaby <jirislaby@...>
Cc: <linux-kernel@...>, Paul Fulghum <paulkf@...>
Date: Saturday, May 31, 2008 - 9:43 am

> It is ever vcs1, which is /dev/console and it is the only treated separately 

Its a complete and total mess is the obvious answer. In fact its far
worse than it first looks and I don't believe it can be fixed without
reworking the whole printk/console stuff.

I spent several days this week mapping out how the tty open/close/hangup
logic works and to be honest what I've learned is

- It doesn't
- It can't be easily fixed to
- There are numerous races
- The whole "tty/console" abstraction for printk type stuff is totally
broken by design and replicated in several places for good measure.

At this point I have to say I can't even see a way to get from the
existing tty open/close/hangup logic to a working one which does not
involve changes to every driver with a 'flag day' type switch between the
two implementations.

For the existing codebase I think the best we can do in this area is label
it "condemned" and not touch it, because any change will be unpredictable
in its effect and not a real fix.

I'd love to be proved wrong. Doing a grand reimplementation of large
chunks of the tty layer isn't what I want to do, I just see no
alternative at this point.

Alan
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH 1/1] Char: tty_io, fix closecount counting, Jiri Slaby, (Mon May 26, 10:08 am)
Re: [PATCH 1/1] Char: tty_io, fix closecount counting, Alan Cox, (Sat May 31, 9:43 am)
Re: [PATCH 1/1] Char: tty_io, fix closecount counting, Jiri Slaby, (Mon May 26, 11:22 am)