From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Pavel Machek <pavel@ucw.cz>
Cc: Michael Schmitz <schmitz@opal.biophys.uni-duesseldorf.de>,
Hugang <hugang@soulinfo.com>,
Patrick Mochel <mochel@digitalimplant.org>,
Nigel Cunningham <ncunningham@users.sourceforge.net>,
ncunningham@clear.net.nz,
linuxppc-dev list <linuxppc-dev@lists.linuxppc.org>
Subject: Re: pmdisk working on ppc (WAS: Help port swsusp to ppc)
Date: Tue, 27 Jan 2004 21:56:04 +1100 [thread overview]
Message-ID: <1075200963.17953.198.camel@gaston> (raw)
In-Reply-To: <20040127104701.GB18666@elf.ucw.cz>
> What is "PMU locking"? Is there some part of powermac harware that
> kills machine if you sleep too long with interrupts disabled?
The PMU is the "Power Management Unit". It's a microcontroller
that does a bunch of things, some PM related, but also the ADB
emulation for the keyboard & trackpad on laptops, the real time
clock, battery management, etc...
We communicate with it via an SPI, it's asynchronous (interrupt
driven) protocol (banging things to a shit register basically).
The kernel is continuously talking to the PMU. If for some reason
communication stops in the middle of a message exchange, the PMU
can time out and shuts the box down.
"PMU suspend" is a hook I added to the driver that completes
pending requests and stops answering to "event" interrupts (those
interrupts are sent by the PMU when we need to read it's incoming
event messages, like keystrokes, environement events, etc...).
When we get such an interrupt, we send a command to read the
event and get the data in the reply. The PMU can timeout in the
middle of that exchange, but won't timeout if we don't ask for
the data at all...
On suspend-to-RAM, since the PMU driver drives the whole suspend
process, there is no real problem, it does things the right way.
But with suspend-to-disk, it's just yet-another device, and so we
need to make sure we properly stop pending communication. The quick
hack I did (added a sysdev with suspend/resume hooks for it) may not
be perfect yet :)
Ben.
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
next prev parent reply other threads:[~2004-01-27 10:56 UTC|newest]
Thread overview: 80+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-01-19 2:52 Help port swsusp to ppc Hugang
2004-01-19 3:04 ` Nigel Cunningham
2004-01-19 3:35 ` Benjamin Herrenschmidt
2004-01-19 5:20 ` Nigel Cunningham
2004-01-19 11:39 ` Benjamin Herrenschmidt
2004-01-19 17:56 ` Nigel Cunningham
2004-01-19 22:03 ` Benjamin Herrenschmidt
2004-01-20 20:44 ` Pavel Machek
2004-01-20 21:54 ` Benjamin Herrenschmidt
2004-01-20 22:07 ` Nigel Cunningham
2004-01-20 22:42 ` Pavel Machek
2004-01-22 13:17 ` Hugang
2004-01-22 17:53 ` Nigel Cunningham
2004-01-23 0:15 ` Hugang
2004-01-23 7:12 ` Benjamin Herrenschmidt
2004-01-23 10:30 ` Hugang
2004-01-24 2:54 ` pmdisk working on ppc (WAS: Help port swsusp to ppc) Benjamin Herrenschmidt
2004-01-24 5:40 ` Hugang
2004-01-24 16:28 ` Colin Leroy
2004-01-24 23:46 ` Benjamin Herrenschmidt
2004-01-25 18:08 ` Colin Leroy
2004-01-26 0:08 ` Benjamin Herrenschmidt
2004-01-26 18:21 ` Colin Leroy
2004-01-26 21:58 ` Benjamin Herrenschmidt
2004-01-26 14:29 ` Guido Guenther
[not found] ` <20040126181004.GB315@elf.ucw.cz>
2004-01-26 22:00 ` Benjamin Herrenschmidt
2004-01-26 22:31 ` Nigel Cunningham
2004-01-28 12:22 ` Hugang
2004-01-28 13:23 ` pmdisk working on ppc (WAS: Help port swsusp to ppc), swsusp2 works Hugang
[not found] ` <20040129012720.1385c41a@localhost>
2004-01-28 19:05 ` Nigel Cunningham
2004-01-28 19:10 ` Hugang
2004-01-29 0:34 ` pmdisk working on ppc (WAS: Help port swsusp to ppc) Benjamin Herrenschmidt
2004-01-29 2:05 ` Hugang
2004-01-29 4:23 ` Benjamin Herrenschmidt
[not found] ` <20040129165119.553403f1@localhost>
2004-01-29 10:29 ` Pavel Machek
2004-01-29 10:50 ` Hugang
2004-01-29 12:12 ` Benjamin Herrenschmidt
2004-01-26 23:21 ` Pavel Machek
2004-01-27 0:12 ` Nigel Cunningham
2004-01-27 7:53 ` Pavel Machek
2004-01-27 10:34 ` Michael Schmitz
2004-01-27 10:37 ` Benjamin Herrenschmidt
2004-01-27 14:32 ` Michael Schmitz
2004-01-27 21:40 ` Benjamin Herrenschmidt
2004-01-28 16:09 ` Michael Schmitz
2004-01-28 17:02 ` Hugang
2004-01-28 17:03 ` Colin Leroy
2004-01-29 9:17 ` Michael Schmitz
2004-01-28 18:00 ` Michael Schmitz
2004-01-28 21:56 ` Benjamin Herrenschmidt
2004-01-28 21:55 ` Benjamin Herrenschmidt
2004-01-29 9:30 ` Michael Schmitz
2004-01-29 12:10 ` Benjamin Herrenschmidt
2004-01-28 21:55 ` Benjamin Herrenschmidt
2004-01-28 23:35 ` Pavel Machek
2004-01-29 8:11 ` Michael Schmitz
2004-01-27 10:47 ` Pavel Machek
2004-01-27 10:56 ` Benjamin Herrenschmidt [this message]
2004-01-24 4:39 ` Benjamin Herrenschmidt
2004-01-24 7:20 ` Pavel Machek
2004-01-24 9:59 ` pmdisk working on ppc Måns Rullgård
2004-01-19 20:45 ` Help port swsusp to ppc Pavel Machek
2004-01-19 23:38 ` Benjamin Herrenschmidt
2004-01-20 0:04 ` Pavel Machek
2004-01-20 1:06 ` Benjamin Herrenschmidt
2004-01-20 10:02 ` Pavel Machek
2004-01-20 11:25 ` Benjamin Herrenschmidt
2004-01-20 11:44 ` Pavel Machek
2004-01-20 9:53 ` Geert Uytterhoeven
2004-01-20 10:04 ` Pavel Machek
2004-01-20 11:26 ` Benjamin Herrenschmidt
2004-01-20 11:36 ` Pavel Machek
2004-01-20 11:44 ` Benjamin Herrenschmidt
2004-01-20 11:57 ` Pavel Machek
2004-01-20 18:30 ` Nigel Cunningham
2004-01-20 21:43 ` Benjamin Herrenschmidt
2004-01-20 11:22 ` Benjamin Herrenschmidt
2004-01-19 20:40 ` Pavel Machek
2004-01-19 23:40 ` Benjamin Herrenschmidt
2004-01-19 23:59 ` Pavel Machek
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=1075200963.17953.198.camel@gaston \
--to=benh@kernel.crashing.org \
--cc=hugang@soulinfo.com \
--cc=linuxppc-dev@lists.linuxppc.org \
--cc=mochel@digitalimplant.org \
--cc=ncunningham@clear.net.nz \
--cc=ncunningham@users.sourceforge.net \
--cc=pavel@ucw.cz \
--cc=schmitz@opal.biophys.uni-duesseldorf.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.