Port-i386 archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

New ACPI power resource code for testing



Hi.

I have (re)written the ACPI power resource code.

This tries to overcome some bugs and limitations in the old code. To name
few issues, the old code lacks locking, never removes references to power
resources, does not support retrieving the power state, does not support
some newer control methods, contains some small bugs, among other thing. 
(This is not to say that the old code is bad, and Michael Smith's name still
appears in the copyright.) The new code also tries to act more as a
small-scale "framework".

Currently ACPI power resources are used only by acpitz(4). But as power
resources hopefully some day play a part in the overall x86 power management
scheme(s), now would be a good time to consider the issue.

Please test if you have time. How?

        1. Drop the code ("acpi_power.c") to "src/sys/dev/acpi".[1]
        2. Apply a patch ("acpi_power.diff").[2]
        3. Add "acpipower* at acpinodebus?" to your kernel configuration file.

On some laptops acpitz(4) uses these resources to make a switch to "active
cooling", so possible regressions should be visible there (fan does not turn
on/off, etc.). Otherwise the code should just, well, sit and idle.

Comments are welcome too, of course.

- Jukka.

PS. Thanks to Paul Goyette for early review.

[1] ftp://ftp.NetBSD.org/pub/NetBSD/misc/jruoho/acpi_power.c
[2] ftp://ftp.NetBSD.org/pub/NetBSD/misc/jruoho/acpi_power.diff



Home | Main Index | Thread Index | Old Index