From: Jon Smirl <jonsmirl@gmail.com>
To: Vladimir Dergachev <volodya@mindspring.com>
Cc: Keith Packard <keithp@keithp.com>,
Mike Mestnik <cheako911@yahoo.com>,
dri-devel <dri-devel@lists.sourceforge.net>,
lkml <linux-kernel@vger.kernel.org>
Subject: Re: Design for setting video modes, ownership of sysfs attributes
Date: Sat, 18 Sep 2004 22:16:26 -0400 [thread overview]
Message-ID: <9e4733910409181916446719b8@mail.gmail.com> (raw)
In-Reply-To: <Pine.LNX.4.61.0409182156160.3498@node2.an-vo.com>
You did that from an xterm, right? Which console device is the xterm running on?
X starts up a process that knows which device it is running and it can
remember that device since X stays running.
Maybe the answer is that this is something for the VC layer since the
VC layer stays running and knows what device it was started on. An
escape sequence could query the device from the VC terminal emulator.
Is there some way to figure this out from the environment?
On Sat, 18 Sep 2004 21:57:32 -0400 (EDT), Vladimir Dergachev
<volodya@mindspring.com> wrote:
> On Sat, 18 Sep 2004, Jon Smirl wrote:
> > Isn't there an enviroment variable that tells what device is the
> > console for the session? How do you tell what serial port you're on
> > when multiple people are logged in on serial lines?
>
> From any program you can do this:
>
> volodya@silver:~$ ls -l /proc/self/fd/0
> lrwx------ 1 volodya users 64 Sep 18 21:56 /proc/self/fd/0 -> /dev/pts/1
>
> So you get the pointer to the actual device stdin is associated to.
--
Jon Smirl
jonsmirl@gmail.com
next prev parent reply other threads:[~2004-09-19 2:16 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-09-18 18:43 Design for setting video modes, ownership of sysfs attributes Jon Smirl
2004-09-18 19:58 ` Mike Mestnik
2004-09-18 22:12 ` Jon Smirl
2004-09-18 22:37 ` Mike Mestnik
2004-09-18 23:33 ` Keith Packard
2004-09-19 0:54 ` Jon Smirl
2004-09-19 1:57 ` Vladimir Dergachev
2004-09-19 2:16 ` Jon Smirl [this message]
2004-09-19 2:32 ` Vladimir Dergachev
2004-09-19 10:11 ` Mike Mestnik
2004-09-19 9:55 ` Mike Mestnik
2004-09-19 4:48 ` Benjamin Herrenschmidt
2004-09-19 16:12 ` Jon Smirl
2004-09-20 0:07 ` Benjamin Herrenschmidt
2004-09-20 1:06 ` Jon Smirl
2004-09-19 4:45 ` Benjamin Herrenschmidt
2004-09-19 16:46 ` Jon Smirl
2004-09-19 17:19 ` Mike Mestnik
2004-09-19 20:40 ` Keith Packard
2004-09-20 13:02 ` Alan Cox
2004-09-19 20:44 ` Felix Kühling
2004-09-20 1:25 ` Mike Mestnik
2004-09-20 0:10 ` Benjamin Herrenschmidt
2004-09-21 12:45 ` Pavel Machek
2004-09-21 15:56 ` Jon Smirl
2004-09-21 15:42 ` Alan Cox
[not found] <2FYdH-10h-5@gated-at.bofh.it>
[not found] ` <2G6Et-6D7-31@gated-at.bofh.it>
2004-09-19 14:18 ` Pascal Schmidt
2004-09-19 15:00 ` P. Benie
2004-09-19 19:08 ` Pascal Schmidt
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=9e4733910409181916446719b8@mail.gmail.com \
--to=jonsmirl@gmail.com \
--cc=cheako911@yahoo.com \
--cc=dri-devel@lists.sourceforge.net \
--cc=keithp@keithp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=volodya@mindspring.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox