From: Len Brown <lenb-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: Bjorn Helgaas <bjorn.helgaas-VXdhtT5mjnY@public.gmane.org>
Cc: "Moore,
Robert" <robert.moore-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>,
Arjan van de Ven <arjan-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>,
Alan Jenkins
<alan-jenkins-cCz0Lq7MMjm9FHfhHBbuYA@public.gmane.org>,
"linux-acpi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<linux-acpi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
linux-kernel
<linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
Kernel Testers List
<kernel-testers-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"Pallipadi,
Venkatesh"
<venkatesh.pallipadi-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
Subject: Re: [BISECTED] EEE PC hangs when booting off battery
Date: Wed, 15 Apr 2009 11:38:32 -0400 (EDT) [thread overview]
Message-ID: <alpine.LFD.2.00.0904151056390.5664@localhost.localdomain> (raw)
In-Reply-To: <200904141056.14159.bjorn.helgaas-VXdhtT5mjnY@public.gmane.org>
> > In fact, ACPI methods can execute concurrently -- constrained by the ACPI specification itself. The "big lock" is released before anything that will block for a significant amount of time, allowing other methods to run.
>
> We had a discussion about this a couple years ago:
> http://www.mail-archive.com/linux-acpi%40vger.kernel.org/msg06976.html
>
> Here's my understanding (please correct me if I'm wrong):
>
> - The ACPI CA holds a mutex while executing an AML method (see
> acpi_ex_enter_interpreter()).
>
> - When an AML method blocks, the ACPI CA releases the mutex, which
> allows another AML method to run while the first is blocked.
>
> - Because of the mutex, at most one AML method can be executing at
> any given time. Others may have started, but they are blocked
> until the current method completes or blocks itself.
>
> - The undocumented "acpi_serialize" option makes the ACPI CA hold
> the mutex for the entire duration of a method, even while a method
> is blocked.
>
> Based on that, my guess about the battery init being slow because of
> a long-running AML method might be incorrect, although I suppose
> it's still possible to write AML busy-loops that never block.
>
> I'd really like to understand what's making it slow. The only
> thing that looks at all unusual in acpi_battery_add() is
> acpi_battery_update(), and that evaluates _STA and _BIF and
> not much else.
>
> Arjan, do you have any more information? Is the battery driver
> slow on all laptops? If not, where did you see the problem? Do
> you have a DSDT for them?
Before I added Arjan's async battery patch, I booted a couple of laptops
with async disabled and enabled. I saw about 40 usec battery init (T61,
nx6325).
Obviously, this was too fast for async battery to have any measurable
benefit on these machines (though async disk probing, by comparison,
was a big win).
But Arjan saw O(300) usec serial battery init on an EEE PC,
which is why he optimized it.
Indeed, this thread was started b/c a failure was seen on an EEEPC,
probably because of its unusually slow timing.
-Len
next prev parent reply other threads:[~2009-04-15 15:38 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-11 9:41 Regression: EEE PC hangs when booting off battery Alan Jenkins
[not found] ` <49E065CF.6040408-cCz0Lq7MMjm9FHfhHBbuYA@public.gmane.org>
2009-04-11 18:07 ` Tzy-Jye Daniel Lin
[not found] ` <66dc75180904111107q645fbb77i3cf927ffab7a7ef0-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-04-12 9:00 ` Alan Jenkins
[not found] ` <49E1ADAE.2030103-cCz0Lq7MMjm9FHfhHBbuYA@public.gmane.org>
2009-04-12 13:11 ` [BISECTED] " Alan Jenkins
[not found] ` <49E1E89D.7040502-cCz0Lq7MMjm9FHfhHBbuYA@public.gmane.org>
2009-04-13 19:15 ` Bjorn Helgaas
[not found] ` <200904131315.55519.bjorn.helgaas-VXdhtT5mjnY@public.gmane.org>
2009-04-13 19:57 ` Alan Jenkins
2009-04-13 22:28 ` Bjorn Helgaas
2009-04-14 8:06 ` Alan Jenkins
2009-04-14 9:26 ` Alan Jenkins
2009-04-14 14:59 ` Bjorn Helgaas
2009-04-14 15:17 ` Arjan van de Ven
2009-04-14 15:37 ` Alan Jenkins
[not found] ` <20090414081728.10de978a-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>
2009-04-14 15:48 ` Bjorn Helgaas
[not found] ` <200904140948.37633.bjorn.helgaas-VXdhtT5mjnY@public.gmane.org>
2009-04-14 15:55 ` Moore, Robert
[not found] ` <4911F71203A09E4D9981D27F9D8308581D3722EB-osO9UTpF0URQxe9IK+vIArfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2009-04-14 16:56 ` Bjorn Helgaas
2009-04-14 17:22 ` Moore, Robert
[not found] ` <4911F71203A09E4D9981D27F9D8308581D372489-osO9UTpF0URQxe9IK+vIArfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2009-04-14 17:28 ` Alan Jenkins
[not found] ` <200904141056.14159.bjorn.helgaas-VXdhtT5mjnY@public.gmane.org>
2009-04-15 15:38 ` Len Brown [this message]
2009-04-15 14:32 ` [FIXED] " Alan Jenkins
2009-04-22 12:17 ` Alan Jenkins
2009-04-26 11:34 ` Alan Jenkins
[not found] ` <49F446AE.6070607-cCz0Lq7MMjm9FHfhHBbuYA@public.gmane.org>
2009-04-28 9:19 ` [PATCH] [RFC] " Alan Jenkins
[not found] ` <49F6CA0E.5040101-cCz0Lq7MMjm9FHfhHBbuYA@public.gmane.org>
2009-04-28 9:58 ` Johannes Berg
[not found] ` <1240912688.28835.10.camel-YfaajirXv2244ywRPIzf9A@public.gmane.org>
2009-04-28 10:27 ` Alan Jenkins
[not found] ` <49F6DA14.7030608-cCz0Lq7MMjm9FHfhHBbuYA@public.gmane.org>
2009-04-28 10:35 ` Johannes Berg
2009-04-29 11:14 ` Alan Jenkins
[not found] ` <49F83699.3000307-cCz0Lq7MMjm9FHfhHBbuYA@public.gmane.org>
2009-04-29 11:20 ` Johannes Berg
2009-05-15 21:48 ` Rafael J. Wysocki
[not found] ` <200905152348.56449.rjw-KKrjLPT3xs0@public.gmane.org>
2009-05-16 8:39 ` Alan Jenkins
2009-04-11 19:40 ` Regression: " Kristoffer Ericson
[not found] ` <20090411214045.7bdd497f.kristoffer.ericson-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2009-04-12 9:22 ` Alan Jenkins
2009-04-15 15:49 ` archlinux 2.6.28 ac oops (was Re: Regression: EEE PC hangs when booting off battery) Len Brown
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=alpine.LFD.2.00.0904151056390.5664@localhost.localdomain \
--to=lenb-dgejt+ai2ygdnm+yrofe0a@public.gmane.org \
--cc=alan-jenkins-cCz0Lq7MMjm9FHfhHBbuYA@public.gmane.org \
--cc=arjan-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org \
--cc=bjorn.helgaas-VXdhtT5mjnY@public.gmane.org \
--cc=kernel-testers-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-acpi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=robert.moore-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
--cc=venkatesh.pallipadi-ral2JQCrhuEAvxtiuMwx3w@public.gmane.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