Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Dec 2000 07:21:46 GMT
From:      Cliff S. <csbsd@raggedclown.net>
To:        Andy Farkas <andyf@speednet.com.au>, Jimmy Thomson <glitch@execpc.com>, freebsd-questions@FreeBSD.ORG
Subject:   Re: pty's?
Message-ID:  <E149MWQ-000EAN-00@post.mail.nl.demon.net>

next in thread | raw e-mail | index | archive | help
> 
> On Thu, 21 Dec 2000, Jimmy Thomson wrote:
> 
> > On Fri, 22 Dec 2000, Andy Farkas wrote:
> > > It looks to me like /dev/MAKEDEV can make a maximum of 256 pty's by saying
> > >
> > >   # cd /dev
> > >   # /bin/sh MAKEDEV pty7
> > >
> > > (yes, the '7' seems a bit confusing to me too...)
> > >
> > 
> > MAKEDEV pty7???
> > 
> > Anyone have any clue what the heck that does?
> 
> As I said, it makes 256 ptys.  Sheesh.

Well, I for one could think of a slightly better engineered
interface. It could hardly be called intuitive that a parameter
of pty7 makes 256 ptys. Maybe pty256 would be cuter :). Then again...

My Xmas 2 cents (dutch) worth..

Cliff
> 
> /dev/MAKEDEV has this in it:
> 
> pty*)
>         class=`expr $i : 'pty\(.*\)'`
>         case $class in
>         0) offset=0 name=p;;
>         1) offset=32 name=q;;
>         2) offset=64 name=r;;
>         3) offset=96 name=s;;
> # Note that xterm (at least) only look at p-s.
>         4) offset=128 name=P;;
>         5) offset=160 name=Q;;
>         6) offset=192 name=R;;
>         7) offset=224 name=S;;
> 
> Which means that:
> 
>   # /bin/sh MAKEDEV pty0   - will make 32 ptys
>   # /bin/sh MAKEDEV pty1   - will make 64 ptys
>   # /bin/sh MAKEDEV pty2   - will make 96 ptys
>   # /bin/sh MAKEDEV pty3   - will make 128 ptys
>   # /bin/sh MAKEDEV pty4   - will make 160 ptys
>   # /bin/sh MAKEDEV pty5   - will make 192 ptys
>   # /bin/sh MAKEDEV pty6   - will make 224 ptys
>   # /bin/sh MAKEDEV pty7   - will make 256 ptys
> 
> Hope this helps.
> 
> --
>  
>  :{ andyf@speednet.com.au
>   
>         Andy Farkas
>     System Administrator
>    Speednet Communications
>  http://www.speednet.com.au/
>   
> 
> 
> 
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-questions" in the body of the message




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E149MWQ-000EAN-00>