Red Hat Bugzilla – Bug 101467
Polling /proc/acpi/*/state chews up 10-15% of the processor
Last modified: 2007-04-18 12:56:30 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5a) Gecko/20030730
Description of problem:
Hardware: Dell Latitude C400
I have noticed that battstat-applet-2 consumes 10-15% of the
processor. It appears that it is the polling of the /proc interface that
I have tested this:
$ watch "cat /proc/acpi/ac_adapter/AC/state ; cat /proc/acpi/battery/BAT0/state"
I then watched the cpu usage every second, and it would fluctuate from around
1%-2% when /proc/acpi entries were not being accessed to 10%-15% when they were.
I used top and gnome-system-monitor, if there is a better way to watch this, or
other information is needed, let me know.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Monitor ACPI on the laptop, using battstat-applet-2
Actual Results: CPU usage goes way up while the ACPI state is polled. The
machine can stall if it is under heavy load when ACPI is polled. xmms may skip,
xscreensaver may become jerky and compiles may pause a moment.
Expected Results: Less CPU usage.
please attach dmesg and output of acpidmp.
Created attachment 93937 [details]
dmesg from the system
Created attachment 93939 [details]
acpidmp from the system
can you try this, the change is in routine 'acpi_pci_link_add':
diff -ur a/drivers/acpi/pci_link.c b/drivers/acpi/pci_
--- a/drivers/acpi/pci_link.c 2003-08-29 08:53:24.000000000 +0
+++ b/drivers/acpi/pci_link.c 2003-09-03 11:37:27.000000000 +0
@@ -576,7 +576,11 @@
else if (!found)
- printk(", enabled at IRQ %d", link->irq.active);
+ link->irq.active = 0;
+ acpi_ut_evaluate_object (link->handle, "_DIS", 0, NULL);
+ printk(", disabled");
/* TBD: Acquire/release lock */
This test runs for me in under 1% CPU use on FC2-test1
closing -- please re-open if you still see this issue.