[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100527225637.57a336ad@lxorguk.ukuu.org.uk>
Date: Thu, 27 May 2010 22:56:37 +0100
From: Alan Cox <alan@...rguk.ukuu.org.uk>
To: Matthew Garrett <mjg59@...f.ucam.org>
Cc: Peter Zijlstra <peterz@...radead.org>,
Thomas Gleixner <tglx@...utronix.de>,
Arve Hjønnevåg <arve@...roid.com>,
Florian Mickler <florian@...kler.org>,
Vitaly Wool <vitalywool@...il.com>,
LKML <linux-kernel@...r.kernel.org>,
Paul@...p1.linux-foundation.org, felipe.balbi@...ia.com,
Linux OMAP Mailing List <linux-omap@...r.kernel.org>,
Linux PM <linux-pm@...ts.linux-foundation.org>
Subject: Re: [linux-pm] [PATCH 0/8] Suspend block api (version 8)
On Thu, 27 May 2010 22:36:35 +0100
Matthew Garrett <mjg59@...f.ucam.org> wrote:
> On Thu, May 27, 2010 at 10:37:51PM +0100, Alan Cox wrote:
> > On Thu, 27 May 2010 18:25:10 +0100
> > Matthew Garrett <mjg59@...f.ucam.org> wrote:
> > > How (and why) does the WoL (which may be *any* packet, not just a magic
> > > one) turn the screen back on?
> >
> > Well on my laptop today it works like this
> >
> > A WoL packet arrives
> > The CPU resumes
> > Depp process, chipset and laptop BIOS magic happens
> > The kernel gets called
> > The kernel lets interested people know a resume occurred
>
> No it doesn't. The kernel continues executing anything that was on the
Would you like to come and watch my laptop resume ? With printk's if you
want. You appear at this point to be arguing that bumble bees can't
fly, while watching one.
> runqueue before the scheduler stopped. If you're using idle-based
> suspend then there's nothing on the runqueue - the application that
> should be scheduled because of the event is blocked on writing to the
> screen.
IFF its your bogus example
IFF you don't have any task waiting for resume notifications (ie its not
X)
So take the PC desktop case and for simplicity sake lets assume the X
application in question has either filled the socket (unlikely) or is mid
query request so blocked on the socket.
The important line then is
'The kernel lets interested people know a resume occurred'
Interesting people includes X
X therefore ends up on the runqueue
X gets the display back in order
X completes processing the outstanding X request and replies
The application continues
If I was blocked on say serial output then the resume is going to wake
the serial driver, which will transmit the queue, which will wake the app.
Alan
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists