Commit Graph

153 Commits

Author SHA1 Message Date
jkim
4c85155383 Merge ACPICA 20100428. 2010-04-28 22:25:27 +00:00
jkim
a2ef6b3007 Merge ACPICA 20100304. 2010-03-05 21:39:16 +00:00
jkim
fa5d03cca6 Merge ACPICA 20100121. 2010-01-21 21:14:28 +00:00
ed
073cafdd42 The last big commit: let usr.sbin/ use WARNS=6 by default. 2010-01-02 11:07:44 +00:00
jkim
e91f3d64cb Merge ACPICA 20091112. 2009-11-16 21:47:12 +00:00
jkim
fca91fda32 Merge ACPICA 20091013. 2009-10-19 16:12:58 +00:00
jkim
d4863f72e7 Catch up with ACPICA 20090903. 2009-09-11 22:50:15 +00:00
jhb
cd97215dd6 - Use the headers from ACPI-CA to define various constants and structures
for table layouts, etc. rather than homerolling our own structures and
  constants in acpidump.h.
- Verify the extended checksum on the RSDP.
- Handle new ACPI 3.0 fields in MADT including X2APIC entries and
  UIDs for local SAPICs.
- Add handling for new ACPI 3.0 flags in the FADT.

Reviewed by:	jkim
MFC after:	1 month
2009-08-25 20:35:57 +00:00
jhb
0991e073e6 Parse the System Resource Affinity Table ('SRAT') used to describe affinity
relationships between CPUs and memory.

Reviewed by:	jkim
Approved by:	re (kib)
MFC after:	1 week
2009-07-29 19:07:24 +00:00
jkim
d0e44fd577 Import ACPICA 20090521. 2009-06-05 18:50:45 +00:00
rpaulo
0c5e80cf38 Update to reflect reality:
* iasl(8) supports ACPI 3.0b.
	* Add new options.

MFC after:	1 week
2008-05-20 12:07:02 +00:00
jb
5582e69034 These are the things that the tinderbox has problems with because it
doesn't use the default CFLAGS which contain -fno-strict-aliasing.

Until the code is cleaned up, just add -fno-strict-aliasing to the
CFLAGS of these for the tinderboxes' sake, allowing the rest of the
tree to have -Werror enabled again.
2007-11-20 02:07:30 +00:00
jb
93e35cf0e3 Use an explicit pointer cast since NULL isn't guaranteed to be defined
as a pointer type.

Submitted by: Christoph Mallon - christoph mallon at gmx de
2007-11-18 09:13:08 +00:00
jb
aea6b64171 Use a NULL instead of a zero to avoid a compiler warning about a missing sentinel. 2007-11-18 03:45:55 +00:00
marcel
45cc42799b Fix acpidump(8) on ia64. Revision 1.13 introduced an uninitialized
variable bug that's hidden by the precense of the hint_acpi_0_rsdp
hint on 386 and amd64. There's never a need for such hint on ia64.

Approved by: re (kensmith)
2007-07-28 17:46:04 +00:00
njl
79d6390885 Update the suspend/resume user API while maintaining backwards compat.
Improvements:
* /etc/rc.suspend,rc.resume are always run, no matter the source of the
  suspend request (user or kernel, apm or acpi)
* suspend now requires positive user acknowledgement.  If a user program
  wants to cancel the suspend, they can.  If one of the user programs
  hangs or doesn't respond within 10 seconds, the system suspends anyway.
* /dev/apm is clonable, allowing multiple listeners for suspend events.
  In the future, xorg-server can use this to be informed about suspend
  even if there are other listeners (i.e. apmd).

Changes:
* Two new ACPI ioctls:  REQSLPSTATE and ACKSLPSTATE.  Request begins the
  process of suspending by notifying all listeners.  acpi is monitored by
  devd(8) and /dev/apm listener(s) are also counted.  Users register their
  approval or disapproval via Ack.  If anyone disapproves, suspend is vetoed.
* Old user programs or kernel modules that used SETSLPSTATE continue to
  work.  A message is printed once that this interface is deprecated.
* acpiconf gains the -k flag to ack the suspend request.  This flag is
  undocumented on purpose since it's only used by /etc/rc.suspend.  It is
  not intended to be a permanent change and will be removed once a better
  power API is implemented.
* S5 (power off) is no longer supported via acpiconf -s 5 or apm -z/-Z.
  This restores previous behavior of halt/shutdown -p being the interface.
* Miscellaneous improvements to error reporting

Approved by:	re
2007-06-21 22:50:37 +00:00
takawata
116255f144 Correct HPET header handling.
MFC after: 7 days
2007-03-27 17:03:52 +00:00
jkim
c06098a406 Catch up with ACPI-CA 20070320 import. 2007-03-22 18:16:43 +00:00
njl
e985b603ab Document exact command preferred for sending ASL as part of bug reports. 2007-03-14 22:55:30 +00:00
jkim
e72362d4d0 Catch up with ACPI-CA 20051021 import 2005-11-01 22:44:08 +00:00
njl
b9ae4bae64 Correct column alignment. 2005-07-28 19:41:52 +00:00
njl
ff3802a6f0 Fix nits in reporting battery information and add battery status reporting.
Rate units are mA/mW, not mAh/mWh.  Get full battery status and time
remaining from ACPIIO_BATT_GET_BATTINFO instead of BST.

PR:		bin/83672
MFC after:	2 days
2005-07-28 19:31:28 +00:00
njl
feb635227b Use the current BST/BIF ioctls, not the deprecated ones.
MFC after:	2 days
2005-07-22 19:19:00 +00:00
scottl
f37aa50bc8 Fix a small style problem and add a __packed pragma for safety. 2005-02-17 21:09:26 +00:00
njl
01fa142d7e Note addition of MCFG support. 2005-02-14 16:32:32 +00:00
scottl
332a6d5ce3 Add support for parsing MCFG tables. 2005-02-14 11:21:48 +00:00
ru
114ea39c76 Fixed the misplaced $FreeBSD$. 2005-02-09 18:07:17 +00:00
ru
c05985f13f Sort sections. 2005-01-18 20:02:45 +00:00
njl
848b0d85e8 Catch up with the kernel and set any global variables we are using, in
particular, enabling interpreter workarounds for bad ASL.

MFC after:	1 day
2005-01-03 04:14:05 +00:00
imp
00db5ac668 o Report charge/discharge rate and remaining capacity in the proper
units (as specified in _BIF). (noted by Bruno Ducrot)
o In looking in the standard, if the cap numbers are 0xffffffff, then acpi
  is reporting unknown for that field.  Report unknown numbers properly.
o Update the state to reflect charging, discharging and critical.
2004-11-24 16:02:20 +00:00
imp
d211cd088b phk jumped the gun and posted what looks like a preliminary version of
my patches for this information.  Commit my more complete version.
This version isn't complete yet, since some details aren't handled
right just yet.

Poaching by: phk
2004-11-24 15:32:07 +00:00
phk
897db391de Dump current status of battery as well.
The -i code doesn't really belong here in the first place I would think,
but keep it together for now.
2004-11-24 12:49:39 +00:00
imp
b6ac51fc6e Minor style(9) before possible larger commits. 2004-11-16 06:25:02 +00:00
philip
34ee3dd317 Somehow I missed this last night, acpi_init() doesn't return an int.
Spotted by:	Randy Bush <randy@psg.com>
2004-11-13 15:16:35 +00:00
philip
39c4570592 With the addition of a proper prototype, this is now WARNS=6 clean. 2004-11-13 01:54:22 +00:00
philip
985b7bf736 Two uint32_t casts crept in where they shouldn't have.
ACPI_TYPE_INTEGER can be 64 bits wide in acpi v2.
2004-11-13 01:49:22 +00:00
philip
65415730ab Change some formats and add some casts to make this
WARNS=2 clean, and mark it as such.

PR:		71672 (partly)
Reviewed by:	njl
2004-11-13 01:34:51 +00:00
njl
122c371535 Update a comment that was outdated. 2004-10-05 21:24:20 +00:00
njl
d99a39abe6 Back out the -s flag and go back to dumping the SSDTs by default. 2004-10-05 20:45:05 +00:00
njl
c5a7af0768 Update the man page for the -s flag and other changes that we've missed.
MFC after:	3 days
2004-10-05 02:19:30 +00:00
njl
7195f265b6 Add the -s flag to make dumping SSDTs optional (disabled by default).
Since we can only override the DSDT, a custom ASL dumped previously that
contained SSDTs would result in lots of multiple definition errors.

A longer-term fix involves adding the ability to override SSDTs to ACPI-CA.

MFC after:	3 days
2004-10-05 02:18:53 +00:00
njl
0b7bb0599c When one entry in the RSDT is corrupted, just skip it instead of bailing out.
This gets us the info we need on systems which have proprietary tables that
don't match the standard.  For instance, an AMI system has a table of type
"OEMB" with an invalid checksum.

Tested by:	Maxim Maximov <mcsi_at_mcsi.pp.ru>
MFC after:	1 day
2004-08-18 05:56:07 +00:00
njl
83f40b7711 Update man page for supported table types.
MFC after:	1 day
2004-08-18 05:50:32 +00:00
njl
0e6427381e Remove the ACPIIO_ENABLE and ACPIIO_DISABLE ioctls as well as all
callers.  These ioctls attempted to enable and disable the ACPI
interpreter at runtime.  In practice, it is not possible to boot with
ACPI and then disable it on many systems and trying to do so can cause
crashes, interrupt storms, etc.  Binary compatibility with userland is
retained.

MFC after:	2 days
2004-08-18 05:48:24 +00:00
marcel
df7926e569 We now handle SSDT tables. Remove a reference from the BUGS section
and explicitly mention SSDT when we talk about the DSDT so that people
don't have to guess whether it includes the SSDT.
While here, touch date.

Pointed out by: le@
2004-08-16 20:33:20 +00:00
njl
5e2ceaef26 Comment out the ability to enable/disable ACPI at runtime. This appears
to not work reliably and crash some systems.  It is not supported at all
on others.  Pending discussion, the underlying ioctls will be removed.
2004-08-15 23:39:37 +00:00
marcel
a202a07472 Add support for SSDT tables. Dumping or disassembling the DSDT will
now include the contents if any SSDT table as well. This makes use
of the property that one can concatenate the body of SSDT tables to
the DSDT, updating the DSDT header (length and checksum) and end up
with a larger and valid DSDT table. Hence, this also works with -f.

Reviewed by: njl@
2004-08-13 22:59:09 +00:00
ru
4b39413aeb Removed trailing whitespace. 2004-07-02 19:07:33 +00:00
njl
df4b7b1ecb Also print out the standard header for FADT since it has one. 2004-06-30 03:23:51 +00:00
ru
dc54ee200d Assorted markup, grammar, and spelling fixes. 2004-06-13 18:03:44 +00:00