From: Pavel Machek <pavel@ucw.cz>
To: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: suspend-devel@lists.sourceforge.net,
pm list <linux-pm@lists.osdl.org>,
Nigel Cunningham <ncunningham@linuxmail.org>,
Stephen Hemminger <shemminger@osdl.org>
Subject: Re: [PATCH -mm 1/2]: PM: Fix handling of stopped tasks
Date: Fri, 8 Dec 2006 11:21:23 +0000 [thread overview]
Message-ID: <20061208112123.GA4957@ucw.cz> (raw)
In-Reply-To: <200612070013.23230.rjw@sisk.pl>
Hi!
> > > > > ...after resume.
> > > >
> > > > This is because of how signal_wake_up() works, I think..
> > > >
> > > > > But I think it is right approach.
> > >
> > > Okay, with the appended patch applied everything seems to work and I don't
> > > see any undesirable side-effects.
> >
> > I promise to try it... tommorow. Looks very good to me.
>
> Unfortunately there's one problem with it.
Well, IIRC it still had the 'bash reports vi stopped twice' problem.
> To reproduce it I run "gdb /bin/cat", execute "run" in gdb and press ^Z twice
> to stop both processes. Next I suspend and resume and run "fg" to get the gdb
> back.and press "Enter" to get the prompt. Then, it turns out that the
> terminal echo doesn't work and "Enter" doesn't make it go to the next line.
> I can recover from this state by typing "fg+Enter" (with no echo) so that
> /bin/cat gets the continuation signal and it restores the terminal settings,
> apparently.
I wonder if we should start a test suite ;-).
> This means, however, that with this patch the behavior of a process (gdb)
> after the resume may be different to its normal behavior, which is wrong.
Yep.
> With my original [1/2] this problem doesn't appear (ie. after the resume gdb
> behaves normally). Thus I think that, although this patch is much more
> elegant, my original [1/2] is a safer solution, because we can say exactly
> what it does.
Original 1/2 indeed is 'safer'... but it is also too ugly to live.
Getting this to work should not be that hard, and I'd prefer not to
add more tricky code to already-tricky process.c.
In the meantime, perhaps we want 2/2 merged? That one was
safe&obvious.
Pavel
--
Thanks for all the (sleeping) penguins.
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
next prev parent reply other threads:[~2006-12-08 11:21 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-03 22:18 [PATCH -mm 0/2]: SMP-safe freezer Rafael J. Wysocki
2006-12-03 22:50 ` [PATCH -mm 1/2]: PM: Fix handling of stopped tasks Rafael J. Wysocki
2006-12-05 10:25 ` Pavel Machek
2006-12-05 10:34 ` Pavel Machek
2006-12-05 11:06 ` Rafael J. Wysocki
2006-12-05 14:13 ` Pavel Machek
2006-12-05 14:22 ` Rafael J. Wysocki
2006-12-05 11:24 ` Pavel Machek
2006-12-05 11:38 ` Rafael J. Wysocki
2006-12-05 14:12 ` Pavel Machek
2006-12-05 14:26 ` Rafael J. Wysocki
2006-12-05 14:33 ` Rafael J. Wysocki
2006-12-05 15:27 ` Pavel Machek
2006-12-05 17:22 ` Rafael J. Wysocki
2006-12-05 21:03 ` Rafael J. Wysocki
2006-12-05 21:26 ` Rafael J. Wysocki
2006-12-05 21:42 ` [Suspend-devel] " Rafael J. Wysocki
2006-12-05 22:19 ` Pavel Machek
2006-12-05 22:18 ` Rafael J. Wysocki
2006-12-06 0:07 ` [linux-pm] " Nigel Cunningham
2006-12-05 22:36 ` Pavel Machek
2006-12-05 22:45 ` Rafael J. Wysocki
2006-12-05 23:08 ` Rafael J. Wysocki
2006-12-05 23:45 ` Pavel Machek
2006-12-06 0:02 ` [Suspend-devel] " Nigel Cunningham
2006-12-06 23:13 ` Rafael J. Wysocki
2006-12-08 11:21 ` Pavel Machek [this message]
2006-12-08 11:49 ` Rafael J. Wysocki
2006-12-08 13:05 ` Rafael J. Wysocki
2006-12-08 22:07 ` Rafael J. Wysocki
2006-12-08 23:36 ` Pavel Machek
2006-12-09 15:35 ` Rafael J. Wysocki
2006-12-10 0:27 ` Rafael J. Wysocki
2006-12-10 10:45 ` Rafael J. Wysocki
2006-12-10 20:00 ` Pavel Machek
2006-12-10 11:26 ` Rafael J. Wysocki
2006-12-03 23:10 ` [PATCH -mm 2/2]: PM: SMP-safe freezer Rafael J. Wysocki
2006-12-04 10:30 ` Pavel Machek
2006-12-04 14:03 ` Rafael J. Wysocki
2006-12-04 19:44 ` Pavel Machek
2006-12-04 19:56 ` Rafael J. Wysocki
2006-12-05 5:43 ` [linux-pm] " David Brownell
2006-12-05 11:14 ` [Suspend-devel] " Rafael J. Wysocki
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=20061208112123.GA4957@ucw.cz \
--to=pavel@ucw.cz \
--cc=linux-pm@lists.osdl.org \
--cc=ncunningham@linuxmail.org \
--cc=rjw@sisk.pl \
--cc=shemminger@osdl.org \
--cc=suspend-devel@lists.sourceforge.net \
/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