[EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
| 
| From: Sukadev Bhattiprolu <[EMAIL PROTECTED]>
| Subject: [RFC][PATCH 2/3] Move some init_dev() code to callers
| 
| init_dev() tries to find a tty and if it finds an existing tty, does
| a 'fast' open. If its not an existing tty, init_dev does a slower
| first time open requiring allocation and complex initialization.
| 
| All these seem to make the code more complex. When opening /dev/tty,
| the caller already has the tty so there is no need to find it. Further
| the fast and slow opens in init_dev() don't really share much code
| and could be in separate functions.
| 
| With only two callers, init_dev() does not really need to be that
| generalized and some of the pieces can be moved into the callers.

Alan, should I rebase this patch on the current ttydev tree -
(i.e move tty_driver_lookup() and tty_reopen() to callers) or do you
have other plans ?

ptmx_open() may not even need call tty_driver_lookup() or reopen()
since it just allocated a new index. I did quick touch test on it.

tty_open() can skip the lookup if opening /dev/tty.
_______________________________________________
Containers mailing list
[EMAIL PROTECTED]
https://lists.linux-foundation.org/mailman/listinfo/containers

_______________________________________________
Devel mailing list
[email protected]
https://openvz.org/mailman/listinfo/devel

Reply via email to