summaryrefslogtreecommitdiffstats
path: root/sys/dev/acpica/acpi_thermal.c
Commit message (Collapse)AuthorAgeFilesLines
* Catch up to changes in acpivar.h to add support for using ACPI onjhb2002-10-161-2/+9
| | | | | | 4-stable systems. Sponsored by: The Weather Channel
* Some kernel threads try to do significant work, and the default KSTACK_PAGESscottl2002-10-021-1/+1
| | | | | | | | | | | | | doesn't give them enough stack to do much before blowing away the pcb. This adds MI and MD code to allow the allocation of an alternate kstack who's size can be speficied when calling kthread_create. Passing the value 0 prevents the alternate kstack from being created. Note that the ia64 MD code is missing for now, and PowerPC was only partially written due to the pmap.c being incomplete there. Though this patch does not modify anything to make use of the alternate kstack, acpi and usb are good candidates. Reviewed by: jake, peter, jhb
* Fix a bug about the cooling system controlling in acpi_thermal driver.iwasaki2002-08-271-0/+16
| | | | | | | Recent version of ACPI CA returns the package object which contains object reference elements if the elements are named objects. We need to be careful when you use acpi_ForeachPackageObject() in new code...
* Fixed printf format errors which apparently crept in while -Wformat wasbde2002-05-251-1/+1
| | | | disabled for gcc-3.
* Brutally deal with __func__ being 'const char *' on gcc-3.1.peter2002-05-191-9/+9
|
* Add generalized power profile code.iwasaki2002-03-041-6/+14
| | | | | | | | | | | | | 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
* The thermal thread needs to take Giant before it does anything with themsmith2002-02-251-0/+6
| | | | | | interpreter. Submitted by: Magnus B{ckstr|m <b@etek.chalmers.se>
* Match namespace cleanup changes in ACPI CA 20020217 update.msmith2002-02-231-46/+72
| | | | | | | | Use ACPI_SUCCESS/ACPI_FAILURE consistently. The AcpiGetInto* interfaces are obsoleted by ACPI_ALLOCATE_BUFFER. Convert to using a kthread rather than timeout() to avoid problems with the interpreter sleeping.
* Staticise devclasses and some unnecessarily global variables.msmith2002-01-081-1/+1
|
* Add OS layer ACPI mutex and threading support.iwasaki2001-12-221-5/+31
| | | | | | | | | | | | | | | | | | - Temporary fix a bug of Intel ACPI CA core code. - Add OS layer ACPI mutex support. This can be disabled by specifying option ACPI_NO_SEMAPHORES. - Add ACPI threading support. Now that we have a dedicate taskqueue for ACPI tasks and more ACPI task threads can be created by specifying option ACPI_MAX_THREADS. - Change acpi_EvaluateIntoBuffer() behavior slightly to reuse given caller's buffer unless AE_BUFFER_OVERFLOW occurs. Also CM battery's evaluations were changed to use acpi_EvaluateIntoBuffer(). - Add new utility function acpi_ConvertBufferToInteger(). - Add simple locking for CM battery and temperature updating. - Fix a minor problem on EC locking. - Make the thermal zone polling rate to be changeable. - Change minor things on AcpiOsSignal(); in ACPI_SIGNAL_FATAL case, entering Debugger is easier to investigate the problem rather than panic.
* Cleanups of verbose printing. All the messages for the debugging isiwasaki2001-11-181-19/+20
| | | | | | | 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.
* Two minor changes.iwasaki2001-11-151-9/+8
| | | | | | | - Change _ACx sysctl oid from ten of _AC[0-9] to one _ACx. - Better error printing on _TMP evaluation. Reviewed by: msmith
* Some small improvements of ACPI thermal driver.iwasaki2001-10-291-4/+47
| | | | | | | | | | - Give a guaranteed minimum cooling run time to avoid too frequent cooling system On/Off switching. The minimum cooling run time can be specified by hw.acpi.thermal.min_runtime in sec. - Refine message printing (_AC-1 -> NONE). - Add verbose mode enable/disable capability by hw.acpi.verbose in bool. Reviewed by: acpi-jp@ folks
* Just print a message in acpi_tz_monitor() only when new active stateiwasaki2001-09-041-2/+5
| | | | | | | | is different from the previous active state. This reduce tons of 'acpi_tz0: _AC0: temperature 64.0 >= setpoint 64.0' messages. Reviewed by: msmith
* Updates to match the ACPI CA 20010816 import:msmith2001-08-261-9/+9
| | | | | - New debug macro (ACPI_DEBUG_PRINT), reducing debug-case code size. - New debug level/subsystem codes.
* Remove noisy printfs from the notify handler; having these go offmsmith2001-08-211-2/+0
| | | | every couple of seconds is not useful.
* Convert from acpi_strerror() to AcpiFormatException()msmith2001-07-211-2/+2
| | | | Fix dangling include of the dear departed acpi_ecreg.h
* Quiet the complaint about the _SCP method if it doesn't exist; it'smsmith2001-07-071-2/+3
| | | | not mandatory.
* Add support for user-requested override of cooling levels.msmith2001-07-071-80/+189
| | | | | | | | Monitor the system power profile, and use _SCP to adjust thermal zones accordingly. Simplify the behaviour of the timeout routine, and add some temporary debugging.
* Fix a couple of misunderstandings in the monitor code. Passive coolingmsmith2001-07-051-50/+131
| | | | | | | | | | is a parallel adjunct to active cooling, not a lesser evil. The _ACx levels sort from 0 being hottest, not coolest. Sanity check the returned temperature values, since we are having trouble reading them on some systems. Rearrange sysctl nodes a bit; this is probably close to the final layout.
* Add ACPI lock support.msmith2001-06-291-13/+52
| | | | | | | Pass the softc, not the device_t to the Notify handler. Don't invoke the Interpreter from callout context, as it may sleep. Use AcpiOsQueueForExecution, which is called from taskqueue_swi.
* Sync to my work in progress:msmith2001-06-281-36/+342
| | | | | | | | | | | | - Reorder the acpi_* functions in a sensible fashion - Add acpi_ForeachPackageObject and acpi_GetHandleInScope - Use the new debugging layer/level names - Implement most of the guts of the acpi_thermal module; passive cooling isn't there yet, but active cooling should work. - Implement power resource handling (acpi_powerres.c) This compiles and mostly works, but my test coverage is small, so feedback is welcome.
* Add sysctl interface (Read-only) for temprature, AC-line and Battery.iwasaki2001-06-231-7/+14
| | | | Patches for acpi_cmbat.c submitted by Munehiro Matsuda.
* - Updates for new constant naming in the ACPI CA 20010518 update.msmith2001-05-291-5/+5
| | | | | | | | | | | - 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).
* Tidy up.msmith2001-01-311-48/+47
| | | | | | Don't print temperatures at attach time - they're usually wrong. Use acpi_EvaluateInteger instead of doing things the hard way.
* Axe unused local variable.jhb2001-01-231-1/+0
|
* Add ACPI AC adaptor and ACPI Control Method Battery.takawata2000-12-221-3/+43
| | | | And install notify handler for thermal zone .
* - Convert a lot of homebrew debugging output to use the ACPI CA debuggingmsmith2000-12-081-6/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | infrastructure. It's not perfect, but it's a lot better than what we've been using so far. The following rules apply to this: o BSD component names should be capitalised o Layer names should be taken from the non-CA set for now. We may elect to add some new BSD-specific layers later. - Make it possible to turn off selective debugging flags or layers by listing them in debug.acpi.layer or debug.acpi.level prefixed with !. - Fully implement support for avoiding nodes in the ACPI namespace. Nodes may be listed in the debug.acpi.avoid environment variable; these nodes and all their children will be ignored (although still scanned over) by ACPI functions which scan the namespace. Multiple nodes can be specified, separated by whitespace. - Implement support for selectively disabling ACPI subsystem components via the debug.acpi.disable environment variable. The following components can be disabled: o bus creation/scanning of the ACPI 'bus' o children attachment of children to the ACPI 'bus' o button the acpi_button control-method button driver o ec the acpi_ec embedded-controller driver o isa acpi replacement of PnP BIOS for ISA device discovery o lid the control-method lid switch driver o pci pci root-bus discovery o processor CPU power/speed management o thermal system temperature detection and control o timer ACPI timecounter Multiple components may be disabled by specifying their name(s) separated by whitespace. - Add support for ioctl registration. ACPI subsystem components may register ioctl handlers with the /dev/acpi generic ioctl handler, allowing us to avoid the need for a multitude of /dev/acpi* control devices, etc.
* Initial FreeBSD OSPM (operating system power management) modules formsmith2000-10-281-0/+102
ACPICA. Most of these are still works in progress. Support exists for: - Fixed feature and control method power, lid and sleep buttons. - Detection of ISA PnP devices using ACPI namespace. - Detection of PCI root busses using ACPI namespace. - CPU throttling and sleep states (incomplete) - Thermal monitoring and cooling control (incomplete) - Interface to platform embedded controllers (mostly complete) - ACPI timer (incomplete) - Simple userland control of sleep states. - Shutdown and poweroff.
OpenPOWER on IntegriCloud