This is a little patch to allow more than 64 ptys in the standard kernel.

The devices are allocated in blocks of 256 ptys, with two different major 
number for the master and slave device.

You can configure more than one pty driver (if you need more than 256 ptys),
simply change the constant NR_PTY_DRIVERS in /usr/src/linux/drivers/char/pty.c

The mkptys script creates the necessary device files. Invoke it with the number of pty drivers (the value of NR_PTY_DRIVERS)

To access more than 176 ptys ( ttyzf/ptyzf) I have changed the naming scheme
of the device files; the new names are /dev/ptypNNN for the master device and
/dev/ttypNNN for the slave devices (example, ttyp0/ptyp0, ttyp123/ptyp123)

To maintain compatibility with all the current utilities you can run the
mkptys script with -link (it will symlink the standard names to the new devices)

(NOTE: to open more than 256 ptys you will have also to increase the number
of open files in the kernel, I'm working on it, stay tuned)

See the comments in /usr/src/linux/drivers/char/pty.c for more informations.

To apply the patch :
 	
	cd /usr/src
	patch -p0 < ptys.patch

This is ALPHA software, use at your own risk!

Send comments/criticism/beer to   Daniele Paoni
				  mc5171@mclink.it
