Send plymouth mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
http://lists.freedesktop.org/mailman/listinfo/plymouth
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of plymouth digest..."
Today's Topics:
1. Re: Keyboard input / init + questions (Ray Strode)
2. Re: Keyboard input / init + questions (Ray Strode)
3. Re: Keyboard input / init + questions (Jerome Martin)
4. Re: Keyboard input / init + questions (Jerome Martin)
5. Re: Keyboard input / init + questions (Jerome Martin)
----------------------------------------------------------------------
Message: 1
Date: Sun, 26 Sep 2010 17:25:42 -0400
From: Ray Strode <[email protected]>
Subject: Re: Keyboard input / init + questions
To: Jerome Martin <[email protected]>
Cc: [email protected]
Message-ID:
<[email protected]>
Content-Type: text/plain; charset=UTF-8
Hi,
On Sun, Sep 26, 2010 at 4:36 PM, Jerome Martin <[email protected]> wrote:
> Mmmhh. But against which makefile ? You need to generate it first don't you
> ?
> So the release from git tree would be ./autogen.sh; ./configure OPTIONS and
> then your make distcheck ?
Yup, exactly.
--Ray
------------------------------
Message: 2
Date: Sun, 26 Sep 2010 17:26:57 -0400
From: Ray Strode <[email protected]>
Subject: Re: Keyboard input / init + questions
To: Jerome Martin <[email protected]>
Cc: [email protected]
Message-ID:
<[email protected]>
Content-Type: text/plain; charset=UTF-8
Hi,
> Is the debug logged saved somewhere ? Because with my setup copying it from
> the console is going to be tedious...
Yes, should be in /var/log/plymouth-debug.log
alternatively you can just cat /dev/vcs1
--Ray
------------------------------
Message: 3
Date: Sun, 26 Sep 2010 23:29:16 +0200
From: Jerome Martin <[email protected]>
Subject: Re: Keyboard input / init + questions
To: Ray Strode <[email protected]>
Cc: [email protected]
Message-ID:
<[email protected]>
Content-Type: text/plain; charset="iso-8859-1"
ok, will do.
But meanwhile I have checked sysvinit sources, and since the very first
release this code is in, so I assumed you have a workaround for this, but I
find it strange that it works, because not only init steal the tty when
starting, but it does so in a separate process every time it spawns a child
too....
if ((f = console_open(O_RDWR|O_NOCTTY)) >= 0) {
/* Take over controlling tty by force */
(void)ioctl(f, TIOCSCTTY, 1);
dup(f);
dup(f);
}
SETSIG(sa, SIGCHLD, SIG_DFL, SA_RESTART);
if ((pid = fork()) < 0) {
initlog(L_VB, "cannot fork: %s",
strerror(errno));
exit(1);
}
if (pid > 0) {
/*
* Ignore keyboard signals etc.
* Then wait for child to exit.
*/
SETSIG(sa, SIGINT, SIG_IGN, SA_RESTART);
SETSIG(sa, SIGTSTP, SIG_IGN, SA_RESTART);
SETSIG(sa, SIGQUIT, SIG_IGN, SA_RESTART);
while ((rc = waitpid(pid, &st, 0)) != pid)
if (rc < 0 && errno == ECHILD)
break;
/*
* Small optimization. See if stealing
* controlling tty back is needed.
*/
pgrp = tcgetpgrp(f);
if (pgrp != getpid())
exit(0);
/*
* Steal controlling tty away. We do
* this with a temporary process.
*/
if ((pid = fork()) < 0) {
initlog(L_VB, "cannot fork: %s",
strerror(errno));
exit(1);
}
if (pid == 0) {
setsid();
(void)ioctl(f, TIOCSCTTY, 1);
exit(0);
}
On Sun, Sep 26, 2010 at 11:26 PM, Ray Strode <[email protected]> wrote:
> Hi,
>
> > Is the debug logged saved somewhere ? Because with my setup copying it
> from
> > the console is going to be tedious...
> Yes, should be in /var/log/plymouth-debug.log
>
> alternatively you can just cat /dev/vcs1
>
> --Ray
>
--
J?r?me Martin
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.freedesktop.org/archives/plymouth/attachments/20100926/ffc759f6/attachment.htm>
------------------------------
Message: 4
Date: Sun, 26 Sep 2010 23:35:10 +0200
From: Jerome Martin <[email protected]>
Subject: Re: Keyboard input / init + questions
To: Ray Strode <[email protected]>
Cc: [email protected]
Message-ID:
<[email protected]>
Content-Type: text/plain; charset="iso-8859-1"
FYI, just finished that test, commenting out the two TIOCSCTTY force-steals
in init code solves the issue.
I wonder what kind of init you normally use ? This is plain old sysvinit ...
On Sun, Sep 26, 2010 at 11:29 PM, Jerome Martin <[email protected]>wrote:
> ok, will do.
> But meanwhile I have checked sysvinit sources, and since the very first
> release this code is in, so I assumed you have a workaround for this, but I
> find it strange that it works, because not only init steal the tty when
> starting, but it does so in a separate process every time it spawns a child
> too....
>
> if ((f = console_open(O_RDWR|O_NOCTTY)) >= 0) {
> /* Take over controlling tty by force */
> (void)ioctl(f, TIOCSCTTY, 1);
> dup(f);
> dup(f);
> }
> SETSIG(sa, SIGCHLD, SIG_DFL, SA_RESTART);
> if ((pid = fork()) < 0) {
> initlog(L_VB, "cannot fork: %s",
> strerror(errno));
> exit(1);
> }
> if (pid > 0) {
> /*
> * Ignore keyboard signals etc.
> * Then wait for child to exit.
> */
> SETSIG(sa, SIGINT, SIG_IGN, SA_RESTART);
> SETSIG(sa, SIGTSTP, SIG_IGN, SA_RESTART);
> SETSIG(sa, SIGQUIT, SIG_IGN, SA_RESTART);
>
> while ((rc = waitpid(pid, &st, 0)) != pid)
> if (rc < 0 && errno == ECHILD)
> break;
>
> /*
> * Small optimization. See if stealing
> * controlling tty back is needed.
> */
> pgrp = tcgetpgrp(f);
> if (pgrp != getpid())
> exit(0);
>
> /*
> * Steal controlling tty away. We do
> * this with a temporary process.
> */
> if ((pid = fork()) < 0) {
> initlog(L_VB, "cannot fork: %s",
> strerror(errno));
> exit(1);
> }
> if (pid == 0) {
> setsid();
> (void)ioctl(f, TIOCSCTTY, 1);
> exit(0);
> }
>
>
> On Sun, Sep 26, 2010 at 11:26 PM, Ray Strode <[email protected]> wrote:
>
>> Hi,
>>
>> > Is the debug logged saved somewhere ? Because with my setup copying it
>> from
>> > the console is going to be tedious...
>> Yes, should be in /var/log/plymouth-debug.log
>>
>> alternatively you can just cat /dev/vcs1
>>
>> --Ray
>>
>
>
>
> --
> J?r?me Martin
>
--
J?r?me Martin
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.freedesktop.org/archives/plymouth/attachments/20100926/91eb7e90/attachment-0001.htm>
------------------------------
Message: 5
Date: Sun, 26 Sep 2010 23:42:52 +0200
From: Jerome Martin <[email protected]>
Subject: Re: Keyboard input / init + questions
To: Ray Strode <[email protected]>
Cc: [email protected]
Message-ID:
<[email protected]>
Content-Type: text/plain; charset="iso-8859-1"
Weird, I found some refs to TIOCSCTTY-based tty stealing, and it seems that
at least at some point in the past, this does not trigger a clean hangup on
the previous controlled session side. Is this still the case or do you have
any means of detecting the situation ? Can I force plymouth splash to use
any tty I want it to, or am I locked into tty1 ?
On Sun, Sep 26, 2010 at 11:35 PM, Jerome Martin <[email protected]>wrote:
> FYI, just finished that test, commenting out the two TIOCSCTTY force-steals
> in init code solves the issue.
> I wonder what kind of init you normally use ? This is plain old sysvinit
> ...
>
> On Sun, Sep 26, 2010 at 11:29 PM, Jerome Martin
> <[email protected]>wrote:
>
>> ok, will do.
>> But meanwhile I have checked sysvinit sources, and since the very first
>> release this code is in, so I assumed you have a workaround for this, but I
>> find it strange that it works, because not only init steal the tty when
>> starting, but it does so in a separate process every time it spawns a child
>> too....
>>
>> if ((f = console_open(O_RDWR|O_NOCTTY)) >= 0) {
>> /* Take over controlling tty by force */
>> (void)ioctl(f, TIOCSCTTY, 1);
>> dup(f);
>> dup(f);
>> }
>> SETSIG(sa, SIGCHLD, SIG_DFL, SA_RESTART);
>> if ((pid = fork()) < 0) {
>> initlog(L_VB, "cannot fork: %s",
>> strerror(errno));
>> exit(1);
>> }
>> if (pid > 0) {
>> /*
>> * Ignore keyboard signals etc.
>> * Then wait for child to exit.
>> */
>> SETSIG(sa, SIGINT, SIG_IGN, SA_RESTART);
>> SETSIG(sa, SIGTSTP, SIG_IGN, SA_RESTART);
>> SETSIG(sa, SIGQUIT, SIG_IGN, SA_RESTART);
>>
>> while ((rc = waitpid(pid, &st, 0)) != pid)
>> if (rc < 0 && errno == ECHILD)
>> break;
>>
>> /*
>> * Small optimization. See if stealing
>> * controlling tty back is needed.
>> */
>> pgrp = tcgetpgrp(f);
>> if (pgrp != getpid())
>> exit(0);
>>
>> /*
>> * Steal controlling tty away. We do
>> * this with a temporary process.
>> */
>> if ((pid = fork()) < 0) {
>> initlog(L_VB, "cannot fork: %s",
>> strerror(errno));
>> exit(1);
>> }
>> if (pid == 0) {
>> setsid();
>> (void)ioctl(f, TIOCSCTTY, 1);
>> exit(0);
>> }
>>
>>
>> On Sun, Sep 26, 2010 at 11:26 PM, Ray Strode <[email protected]> wrote:
>>
>>> Hi,
>>>
>>> > Is the debug logged saved somewhere ? Because with my setup copying it
>>> from
>>> > the console is going to be tedious...
>>> Yes, should be in /var/log/plymouth-debug.log
>>>
>>> alternatively you can just cat /dev/vcs1
>>>
>>> --Ray
>>>
>>
>>
>>
>> --
>> J?r?me Martin
>>
>
>
>
> --
> J?r?me Martin
>
--
J?r?me Martin
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.freedesktop.org/archives/plymouth/attachments/20100926/c35ecb98/attachment.htm>
------------------------------
_______________________________________________
plymouth mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/plymouth
End of plymouth Digest, Vol 23, Issue 7
***************************************