public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: benh@kernel.crashing.org
Cc: linux-pm <linux-pm@lists.linux-foundation.org>,
	Jamey Hicks <jamey@crl.dec.com>,
	Ralf Baechle <ralf@linux-mips.org>
Subject: Re: [RFC] apm-emulation: implement notify/ack for /sys/power/state events
Date: Sun, 16 Dec 2007 21:09:08 +0100	[thread overview]
Message-ID: <1197835748.6769.23.camel@johannes.berg> (raw)
In-Reply-To: <1197835380.21886.0.camel@pasglop>


[-- Attachment #1.1: Type: text/plain, Size: 1000 bytes --]


On Mon, 2007-12-17 at 07:03 +1100, Benjamin Herrenschmidt wrote:
> On Sun, 2007-12-16 at 20:15 +0100, Rafael J. Wysocki wrote:
> > > +              *
> > > +              * Unfortunately we cannot do a timeout because then we'd
> > > +              * suspend again right away if the process that had apm_bios
> > > +              * open and that we timed out waiting for "acknowledges" the
> > > +              * event after we have resumed. If suspend doesn't work because
> > > +              * of a rogue process, just kill that process.
> > > +              *
> > > +              * FIXME: is the suspends_pending == 1 test racy?
> 
> I think we can do the timeout thing easily... Just mark the fd's that
> haven't ack'ed with a flag that makes us ignore the next ack...

Yeah, except, is it really worth it? I should reword the comment into
"I'm too lazy to do it" I guess, but you need CAP_SYS_ADMIN and you can
always kill -9 the program that is making it wait.

johannes

[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



      reply	other threads:[~2007-12-16 20:09 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-16 17:58 [RFC] apm-emulation: implement notify/ack for /sys/power/state events Johannes Berg
2007-12-16 19:15 ` Rafael J. Wysocki
2007-12-16 18:59   ` Johannes Berg
2007-12-16 19:34     ` Johannes Berg
2007-12-16 20:56       ` Rafael J. Wysocki
2007-12-16 20:49         ` Johannes Berg
2007-12-16 21:03           ` Johannes Berg
2007-12-16 20:03   ` Benjamin Herrenschmidt
2007-12-16 20:09     ` Johannes Berg [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=1197835748.6769.23.camel@johannes.berg \
    --to=johannes@sipsolutions.net \
    --cc=benh@kernel.crashing.org \
    --cc=jamey@crl.dec.com \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=ralf@linux-mips.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox