History log of /freebsd-10.0-release/sys/dev/acpica/acpi_acad.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 259065 07-Dec-2013 gjb

- Copy stable/10 (r259064) to releng/10.0 as part of the
10.0-RELEASE cycle.
- Update __FreeBSD_version [1]
- Set branch name to -RC1

[1] 10.0-CURRENT __FreeBSD_version value ended at '55', so
start releng/10.0 at '100' so the branch is started with
a value ending in zero.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 256281 10-Oct-2013 gjb

Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


# 246128 30-Jan-2013 sbz

Use DEVMETHOD_END macro defined in sys/bus.h instead of {0, 0} sentinel on device_method_t arrays

Reviewed by: cognet
Approved by: cognet


# 197649 30-Sep-2009 jhb

Do not hold the ACPI A/C adapter lock when changing the power profile.

MFC after: 2 weeks


# 193530 05-Jun-2009 jkim

Import ACPICA 20090521.


# 167814 22-Mar-2007 jkim

Catch up with ACPI-CA 20070320 import.


# 151627 24-Oct-2005 njl

Invert the check logic. No functional change, but I prefer this version.


# 151610 24-Oct-2005 njl

If no AC line devices are found, go ahead and notify devd that the system
is on AC power (i.e. not a laptop). This allows power_profile to run once
for desktop systems as well, for instance, to set C3 or CPU frequency.

MFC after: 2 weeks


# 150003 11-Sep-2005 obrien

Canonize the include of acpi.h.


# 148318 22-Jul-2005 njl

Standardize __FBSDID identifiers.

MFC after: 2 days


# 146373 19-May-2005 takawata

Use General definition for general notify.


# 138300 01-Dec-2004 marks

Catch up with AcpiOsSleep() interface change.
Catch up with some #define's renaming.
Implement AcpiOsGetTimer() as per ACPI 3.0.

Approved by: njl
MFC after: 1 week


# 133661 13-Aug-2004 njl

Record the new status after checking if it has changed, not before. This
fixes lost AC line transition events.

Bug report: Kevin Oberman


# 133613 13-Aug-2004 njl

MPSAFE locking

* Serialize notification of acline changes in acpi_acad_get_status().
* Remove the initializing flag. With the locking, we don't need to
push off requests for the acline before initialization is done.
* Don't check device_get_softc(), it can't return NULL.


# 132261 16-Jul-2004 njl

Use ACPI_ALL_NOTIFY instead of registering handlers separately.


# 131282 29-Jun-2004 njl

Use the acpi_id_probe() method instead of acpi_MatchHid(), which is now
static.


# 130439 13-Jun-2004 njl

Add support to ACPI to manage its own resources. Previously, resource
allocation was passed up to nexus. Now, we probe sysresource objects and
manage the resources they describe in a local rman pool. This helps
devices which attach/detach varying resources (like the _CST object) and
module loads/unloads. The allocation/release routines now check to see if
the resource is described in a child sysresource object and if so,
allocate from the local rman. Sysresource objects add their resources to
the pool and reserve them upon boot. This means sysresources need to be
probed before other ACPI devices.

Changes include:
* Add ordering to the child device probe. The current order is: system
resource objects, embedded controllers, then everything else.
* Make acpi_MatchHid take a handle instead of a device_t arg.
* Replace acpi_{get,set}_resource with the generic equivalents.


# 129879 30-May-2004 phk

Add missing <sys/module.h> includes


# 129692 25-May-2004 njl

Changes to implement 20040514:

* Add calls to AcpiSetGpeType. We use wake/run as the type for lid and
button switches since wake-only causes Thinkpads to immediately wake on
the second suspend. Note that with wake/run, some systems return both
wake and device-specific notifies so we don't register for system notifies
for lid and button switches.
* Remove the hw.acpi.osi_method tunable since it is not needed.
* Always print unknown notifies for all types.
* Add more cleanup for the EC if it fails to attach.
* Use the GPE handle now that we parse it. This allows GPEs to be defined
in AML GPE blocks.
* Always use ACPI_NOT_ISR since it's ok to acquire a mutex in our thread
which processes queued requests.


# 128990 06-May-2004 njl

Make unnecessary globals static and remove unused includes.

Pointed out by: cscout


# 128468 20-Apr-2004 njl

Allow the AC adapter device to be disabled with debug.acpi.disable="acad".
Even though documented, this option was never enabled even in rev 1.1.

Submitted by: sos


# 128071 09-Apr-2004 njl

Add MODULE_DEPEND entries so some of these drivers can eventually be
loaded separately from ACPI (i.e., embedded use).


# 126560 03-Mar-2004 njl

Change to acpi_{Get,Set}Integer to provide both methods. Convert all
callers to the new API.

Submitted by: Mark Santcroos <marks@ripe.net>


# 121493 25-Oct-2003 njl

Add devctl(4) notify support to ACPI. Various subsystems now notify
userland whenever events occur. See the example in devd.conf below
to see how to use it.


# 120453 26-Sep-2003 njl

Consistently print attach messages.


# 120061 14-Sep-2003 njl

Print notify values as hex.


# 118937 15-Aug-2003 njl

Revert part of rev. 1.16 -- reinstate system notify handler. It turns out
at least the Casio FIVA requires this.

Requested by: takawata


# 118925 15-Aug-2003 njl

Don't install a system notify handler. Move the device notify handler
installation to just before we're ready to handle events. Make a loop
more readable (no functional change).


# 118783 11-Aug-2003 njl

Style cleanups to match the rest of this directory. For acpi_battery.c,
remove unused includes.


# 110894 14-Feb-2003 takawata

Allow non-privilaged user to retrive battery or AC line information.

Reviewed by: rwatson


# 106377 03-Nov-2002 iwasaki

Add status initialization code for acpi_cmbat and acpi_acad,
acpi_cmbat_init_battery() and acpi_cmbat_init_acline() respectively.
Call acpi_cmbat_init_battery() from acpi_cmbat_resume() too just in
case.
This is a workaround for embedded controller operations which is
unstable for about a minute (typically 30 or 40 sec.) at boot time.


# 91640 04-Mar-2002 iwasaki

Add generalized power profile code.
This makes other power-management system (APM for now) to be able to
generate power profile change events (ie. AC-line status changes), and
other kernel components, not only the ACPI components, can be notified
the events.

- move subroutines in acpi_powerprofile.c (removed) to kern/subr_power.c
- call power_profile_set_state() also from APM driver when AC-line
status changes
- add call-back function for Crusoe LongRun controlling on power
profile changes for a example


# 91123 23-Feb-2002 msmith

Match namespace cleanup changes in ACPI CA 20020217 update.
Use ACPI_SUCCESS/ACPI_FAILURE consistently.


# 86552 18-Nov-2001 iwasaki

Cleanups of verbose printing. All the messages for the debugging is
disabled unless verbose flag is set. Also fix some messages in terms
of English.
The critical messages and error messages in probe/attach routine are
unchanged by this commit.


# 85556 26-Oct-2001 iwasaki

Add APM compatibility feature to ACPI.
This emulates APM device node interface APIs (mainly ioctl) and
provides APM services for the applications. The goal is to support
most of APM applications without any changes.
Implemented ioctls in this commit are:
- APMIO_SUSPEND (mapped ACPI S3 as default but changable by sysctl)
- APMIO_STANDBY (mapped ACPI S1 as default but changable by sysctl)
- APMIO_GETINFO and APMIO_GETINFO_OLD
- APMIO_GETPWSTATUS

With above, many APM applications which get batteries, ac-line
info. and transition the system into suspend/standby mode (such as
wmapm, xbatt) should work with ACPI enabled kernel (if ACPI works well :-)

Reviewed by: arch@, audit@ and some guys


# 83173 06-Sep-2001 msmith

Initialise the adapter status to an invalid state, so that the initial check
of the adapter object will always result in a change event.

This fixes the problem where a laptop booted without an AC adapter ran
at 100% CPU speed by default.

Submitted by: "Christopher N . Harrell" <cnh@netvmg.com>


# 80334 25-Jul-2001 iwasaki

Some minor fixes.
- Set system power profile only when AC-line status has canged.
- Get initial AC-line status after whole system is up.

Reviewed by: msmith


# 79374 06-Jul-2001 msmith

Add support for system power profiles; select "performance" when AC power
is available and "economy" when it is not.


# 78662 23-Jun-2001 iwasaki

Add sysctl interface (Read-only) for temprature, AC-line and Battery.
Patches for acpi_cmbat.c submitted by Munehiro Matsuda.


# 77432 29-May-2001 msmith

- Updates for new constant naming in the ACPI CA 20010518 update.
- Use __func__ instead of __FUNCTION.
- Support power-off to S3 or S5 (takawata)
- Enable ACPI debugging earlier (with a sysinit)
- Fix a deadlock in the EC code (takawata)
- Improve arithmetic and reduce the risk of spurious wakeup in
AcpiOsSleep.
- Add AcpiOsGetThreadId.
- Simplify mutex code (still disabled).


# 71872 31-Jan-2001 msmith

ACPI_NUMBER becomes ACPI_INTEGER. acpi_EvaluateNumber becomes
acpi_EvaluateInteger.

Use acpi_EvaluateInteger instead of doing things the hard way where
possible.

AcpiSetSystemSleepState (unofficial) becomes AcpiEnterSleepState.

Use the AcpiGbl_FADT pointer rather than searching for the FADT.


# 70340 24-Dec-2000 iwasaki

Add ioctls to acpi_cmbat and acpi_acad. These use mike's acpi_register_ioctl().
Fix wrong AML method calling in acpi_cmbat.


# 70271 22-Dec-2000 takawata

Add ACPI AC adaptor and ACPI Control Method Battery.
And install notify handler for thermal zone .