From: Alexey Starikovskiy <aystarik@gmail.com>
To: Sitsofe Wheeler <sitsofe@yahoo.com>
Cc: linux-acpi@vger.kernel.org
Subject: Re: Reading EeePC900 battery info causes stalls
Date: Thu, 25 Sep 2008 13:54:54 +0400 [thread overview]
Message-ID: <48DB5FEE.4000404@gmail.com> (raw)
In-Reply-To: <48DB5B90.9060607@yahoo.com>
[-- Attachment #1: Type: text/plain, Size: 792 bytes --]
Sitsofe Wheeler wrote:
> Hi Alexey,
>
> Alexey Starikovskiy wrote:
>> I think the least troubling place to add cond_resched() is then
>> ACPICA is exiting interpreter.
>> Please check if the attached patch helps with latencies.
>
> There was no real change (latency was still bad). If you look at the
> trace (before your patch) on
> http://sucs.org/~sits/test/eeepc-debug/20080923/latency_trace.gz
> (700kbyte compressed, 15Mbytes uncompressed) you can see that
> acpi_ex_exit_interpreter is only called once near the end of the trace:
>
> cat-5901 0.N.. 270496us : acpi_ex_exit_interpreter
> (acpi_ev_address_space_dispatch)
>
> By then the time had already been racked up...
>
Ok, let's add it to the end of acpi_ps_complete_op() then... They appear
every 100usec or so...
[-- Attachment #2: add_cond_resched_to_ACPI.patch --]
[-- Type: text/x-diff, Size: 652 bytes --]
diff --git a/drivers/acpi/parser/psloop.c b/drivers/acpi/parser/psloop.c
index c06238e..33cd061 100644
--- a/drivers/acpi/parser/psloop.c
+++ b/drivers/acpi/parser/psloop.c
@@ -564,6 +564,8 @@ acpi_ps_get_arguments(struct acpi_walk_state *walk_state,
*
******************************************************************************/
+#include <linux/sched.h>
+
static acpi_status
acpi_ps_complete_op(struct acpi_walk_state *walk_state,
union acpi_parse_object **op, acpi_status status)
@@ -719,6 +721,8 @@ acpi_ps_complete_op(struct acpi_walk_state *walk_state,
*op = NULL;
}
+ cond_resched();
+
return_ACPI_STATUS(AE_OK);
}
next prev parent reply other threads:[~2008-09-25 9:54 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-24 17:52 Reading EeePC900 battery info causes stalls Sitsofe Wheeler
2008-09-25 8:47 ` Alexey Starikovskiy
2008-09-25 9:35 ` Sitsofe Wheeler
2008-09-25 9:36 ` Sitsofe Wheeler
2008-09-25 9:54 ` Alexey Starikovskiy [this message]
2008-09-25 11:07 ` Alexey Starikovskiy
2008-09-25 11:56 ` Sitsofe Wheeler
2008-09-25 12:01 ` Alexey Starikovskiy
2008-09-25 14:57 ` Alexey Starikovskiy
2008-09-25 17:30 ` Sitsofe Wheeler
2008-09-25 11:17 ` Sitsofe Wheeler
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=48DB5FEE.4000404@gmail.com \
--to=aystarik@gmail.com \
--cc=linux-acpi@vger.kernel.org \
--cc=sitsofe@yahoo.com \
/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;
as well as URLs for NNTP newsgroup(s).