From: Krzysztof Halasa <khc@pm.waw.pl>
To: <linux-kernel@vger.kernel.org>
Cc: andrew.grover@intel.com
Subject: 2.4.23-pre2 BUG() - ACPI + sysrq power_off
Date: 12 Sep 2003 11:47:05 +0200 [thread overview]
Message-ID: <m33cf2z6cm.fsf@defiant.pm.waw.pl> (raw)
Hi,
With 2.4.23-pre2 (and with some older kernels as well) I get BUG()
after pressing sysrq+Off (power off) with ACPI.
kernel/pm.c (line 159):
int pm_send(struct pm_dev *dev, pm_request_t rqst, void *data)
{
int status = 0;
int prev_state, next_state;
if (in_interrupt())
BUG(); <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
switch (rqst) {
case PM_SUSPEND:
case PM_RESUME:
prev_state = dev->state;
next_state = (unsigned long) data;
if (prev_state != next_state) {
if (dev->callback)
status = (*dev->callback)(dev, rqst, data);
if (!status) {
dev->state = next_state;
dev->prev_state = prev_state;
}
}
else {
dev->prev_state = prev_state;
}
break;
default:
if (dev->callback)
status = (*dev->callback)(dev, rqst, data);
break;
}
return status;
}
It seems sysrq-O routine (acpi_sysrq_power_off() -> acpi_power_off() ->
acpi_suspend(ACPI_STATE_S5)) calls pm_send() from keyboard interrupt,
which isn't exactly what pm_send() like.
Details available on request, if needed.
Not checked with 2.6test yet.
Another thing: on my notebook, /sbin/poweroff doesn't power the machine
off with 2.4 (it worked with older 2.4 kernels). echo 5 > /proc/acpi/sleep
does the job. Any ideas?
--
Krzysztof Halasa, B*FH
next reply other threads:[~2003-09-12 9:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-09-12 9:47 Krzysztof Halasa [this message]
2003-09-12 10:34 ` Gerardo Exequiel Pozzi
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=m33cf2z6cm.fsf@defiant.pm.waw.pl \
--to=khc@pm.waw.pl \
--cc=andrew.grover@intel.com \
--cc=linux-kernel@vger.kernel.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
all inboxes | Powered by JetHome®