All of lore.kernel.org
 help / color / mirror / Atom feed
From: hpa@zytor.com (H. Peter Anvin)
To: linux-kernel@vger.kernel.org
Subject: Re: persistent ptys
Date: Thu, 16 Sep 2004 22:30:40 +0000 (UTC)	[thread overview]
Message-ID: <cid46g$t0e$1@terminus.zytor.com> (raw)
In-Reply-To: 4139F3FA.1070107@coppice.org

Followup to:  <4139F3FA.1070107@coppice.org>
By author:	Steve Underwood <steveu@coppice.org>
In newsgroup: linux.dev.kernel
>
> Hi,
> 
> It seems BSD style ptys are on the way out, and most systems will soon 
> have just Unix98 style ptys. This makes me want to move something to 
> Unix98 ptys, but I'm not sure of the appropriate way. The issue is that 
> things like HylaFAX expect to work with well known, persistent, names 
> for modem ports. A 100% soft modem in user space can easily provide that 
> with BSD ptys. With Unix98 ptys it is not so obvious what to do. Most 
> commercial soft modems don't have this issue, as they are part kernel 
> space/part user space designs. Obviously creating a link to a 
> dynamically generated pty with a well known name, and various other 
> things could be done. However, I assume other people have had to do 
> similar persistent pty things, and there is a well defined common 
> practice for it. Can anyone tell me what it is? :-\
> 

Two options: either continue to use BSD ptys (the kinds of stuff you
describe above is actually the one case where BSD ptys is a better
choice than Unix98 ptys) *or* create symlinks -- or if that doesn't
work for you, device nodes -- dynamically.

I.e. have a program which opens /dev/ptmx, gets a slave pty with a
specific ptsname(), then does a symlink() into a suitable directory.
The symlink is your persistent name.

	-hpa


      parent reply	other threads:[~2004-09-16 22:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-04 16:57 persistent ptys Steve Underwood
2004-09-09 12:27 ` Pavel Machek
2004-09-16 22:30 ` H. Peter Anvin [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='cid46g$t0e$1@terminus.zytor.com' \
    --to=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.