summaryrefslogtreecommitdiffstats
path: root/sys/dev/acpica/acpivar.h
diff options
context:
space:
mode:
authormsmith <msmith@FreeBSD.org>2001-07-07 01:46:40 +0000
committermsmith <msmith@FreeBSD.org>2001-07-07 01:46:40 +0000
commit99fb474bb87196a69d346c1dedaadca6cb238c01 (patch)
treeaccd62209041d7fb33895db6d89915506f76554a /sys/dev/acpica/acpivar.h
parente772f1b60ee96b030468f7c2b75d2173d54c09e0 (diff)
downloadFreeBSD-src-99fb474bb87196a69d346c1dedaadca6cb238c01.zip
FreeBSD-src-99fb474bb87196a69d346c1dedaadca6cb238c01.tar.gz
Add support for system power profiles; select "performance" when AC power
is available and "economy" when it is not.
Diffstat (limited to 'sys/dev/acpica/acpivar.h')
-rw-r--r--sys/dev/acpica/acpivar.h17
1 files changed, 15 insertions, 2 deletions
diff --git a/sys/dev/acpica/acpivar.h b/sys/dev/acpica/acpivar.h
index f529a4c..c2bf1af 100644
--- a/sys/dev/acpica/acpivar.h
+++ b/sys/dev/acpica/acpivar.h
@@ -267,11 +267,24 @@ extern int acpi_avoid(ACPI_HANDLE handle);
extern int acpi_disabled(char *subsys);
/*
- * Battery Abstruction and Generalized Power Management interface.
+ * Battery Abstruction.
*/
struct acpi_battinfo;
extern int acpi_battery_register(int, int);
-extern int acpi_acad_get_acline(void);
extern int acpi_cmbat_get_battinfo(int, struct acpi_battinfo *);
+/*
+ * System power API.
+ *
+ * XXX should this be further generalised?
+ *
+ */
+#define POWERPROFILE_PERFORMANCE 0
+#define POWERPROFILE_ECONOMY 1
+
+extern int powerprofile_get_state(void);
+extern void powerprofile_set_state(int state);
+
+typedef void (*powerprofile_change_hook)(void *);
+EVENTHANDLER_DECLARE(powerprofile_change, powerprofile_change_hook);
OpenPOWER on IntegriCloud