[Devel] Re: [RFC][PATCH 1/3] Move parts of init_dev() into new functions

Alan Cox alan at lxorguk.ukuu.org.uk
Mon Aug 25 13:11:46 PDT 2008


On Mon, 25 Aug 2008 13:11:10 -0700
sukadev at us.ibm.com wrote:

> 
> init_dev() is doing too many things all in one function, making it
> harder to understand/extend. This and following two patches attempt
> to simplify/cleanup the interface a bit.
> 
> Only touch tested at this point. Appreciate any comments :-)

Well this code is very much in flux so I really don't want to get further
changes mixed up into the plan at the wrong moment. That said:

> +/*
> + * 	find_tty() - find an existing tty, if any
> + * 	@driver: the driver for the tty
> + * 	@idx:	 the minor number

This fits very well with where I want to end up - which is


	tty = driver->ops->something(driver, idx);

and thus punts all the pty crap from the tty lookup into the pty driver.

So I think this is looking good as a direction, and once the pty crap is
in the pty code it is much easier to localise all the devpts magic.

Alan
_______________________________________________
Containers mailing list
Containers at lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers




More information about the Devel mailing list