xref: /freebsd/share/man/man4/acpi.4 (revision 44cb3ab02e5cf5150233b7faceef035d988f5135)
1b6695bd0SMike Smith.\"
2b6695bd0SMike Smith.\" Copyright (c) 2001 Michael Smith
3b6695bd0SMike Smith.\" All rights reserved.
4b6695bd0SMike Smith.\"
5b6695bd0SMike Smith.\" Redistribution and use in source and binary forms, with or without
6b6695bd0SMike Smith.\" modification, are permitted provided that the following conditions
7b6695bd0SMike Smith.\" are met:
8b6695bd0SMike Smith.\" 1. Redistributions of source code must retain the above copyright
9b6695bd0SMike Smith.\"    notice, this list of conditions and the following disclaimer.
10b6695bd0SMike Smith.\" 2. Redistributions in binary form must reproduce the above copyright
11b6695bd0SMike Smith.\"    notice, this list of conditions and the following disclaimer in the
12b6695bd0SMike Smith.\"    documentation and/or other materials provided with the distribution.
13b6695bd0SMike Smith.\"
14b6695bd0SMike Smith.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15b6695bd0SMike Smith.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16b6695bd0SMike Smith.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17b6695bd0SMike Smith.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18b6695bd0SMike Smith.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19b6695bd0SMike Smith.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20b6695bd0SMike Smith.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21b6695bd0SMike Smith.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22b6695bd0SMike Smith.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23b6695bd0SMike Smith.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24b6695bd0SMike Smith.\" SUCH DAMAGE.
25b6695bd0SMike Smith.\"
26b6695bd0SMike Smith.\" $FreeBSD$
27b6695bd0SMike Smith.\"
286b6a920eSNate Lawson.Dd February 13, 2005
29b6695bd0SMike Smith.Dt ACPI 4
30b6695bd0SMike Smith.Os
31b6695bd0SMike Smith.Sh NAME
32b6695bd0SMike Smith.Nm acpi
33b6695bd0SMike Smith.Nd Advanced Configuration and Power Management support
34b6695bd0SMike Smith.Sh SYNOPSIS
3509f84dd1SRuslan Ermilov.Cd "device acpi"
36b6695bd0SMike Smith.Pp
3709f84dd1SRuslan Ermilov.Cd "options ACPI_DEBUG"
38b6695bd0SMike Smith.Sh DESCRIPTION
39b6695bd0SMike SmithThe
40b6695bd0SMike Smith.Nm
41b6695bd0SMike Smithdriver provides support for the Intel/Microsoft/Compaq/Toshiba ACPI
42b6695bd0SMike Smithstandard.
43b6695bd0SMike SmithThis support includes platform hardware discovery (superseding the
44b6695bd0SMike SmithPnP and PCI BIOS), as well as power management (superseding APM) and
45b6695bd0SMike Smithother features.
46b6695bd0SMike SmithACPI core support is provided by the ACPI CA reference implementation
47b6695bd0SMike Smithfrom Intel.
48d1f717d1SMike Smith.Pp
49d1f717d1SMike SmithNote that the
50d1f717d1SMike Smith.Nm
512010c542SRuslan Ermilovdriver is automatically loaded by the
522010c542SRuslan Ermilov.Xr loader 8 ,
532010c542SRuslan Ermilovand should only be
54edd84e48SNate Lawsoncompiled into the kernel on platforms where ACPI is mandatory.
5544cb3ab0SHiroki Sato.Sh SYSCTL VARIABLES
56edd84e48SNate LawsonThe
57edd84e48SNate Lawson.Nm
58edd84e48SNate Lawsondriver is intended to provide power management without user intervention.
59edd84e48SNate LawsonThus, some of these sysctls are controlled automatically by the
602010c542SRuslan Ermilov.Pa power_profile
612010c542SRuslan Ermilov.Xr rc 8
622010c542SRuslan Ermilovscript, which can be configured via
63edd84e48SNate Lawson.Xr rc.conf 5 .
642010c542SRuslan ErmilovIf values are specified manually, they may be overridden.
65edd84e48SNate Lawson.Bl -tag -width indent
66edd84e48SNate Lawson.It Va hw.acpi.cpu.cx_usage
67edd84e48SNate LawsonDebugging information listing the percent of total usage for each sleep state.
68edd84e48SNate LawsonThe values are reset when
69edd84e48SNate Lawson.Va hw.acpi.cpu.cx_lowest
70edd84e48SNate Lawsonis modified.
71edd84e48SNate Lawson.It Va hw.acpi.cpu.cx_lowest
72edd84e48SNate LawsonLowest Cx state to use for idling the CPU.
73edd84e48SNate LawsonA scheduling algorithm will select states between C1 and this setting
74edd84e48SNate Lawsonas system load dictates.
75edd84e48SNate LawsonTo enable ACPI CPU idling control,
76edd84e48SNate Lawson.Va machdep.cpu_idle_hlt
77edd84e48SNate Lawsonmust be set to 1.
78edd84e48SNate Lawson.It Va hw.acpi.cpu.cx_supported
79edd84e48SNate LawsonList of supported CPU idle states and their transition latency
80edd84e48SNate Lawsonin microseconds.
81edd84e48SNate LawsonEach state has a type (e.g., C2).
82edd84e48SNate LawsonC1 is equivalent to the ia32 HLT instruction, C2 provides a deeper
83edd84e48SNate Lawsonsleep with the same semantics, and C3 provides the deepest sleep
84edd84e48SNate Lawsonbut additionally requires bus mastering to be disabled.
85edd84e48SNate LawsonStates greater than C3 provide even more power savings with the same
86edd84e48SNate Lawsonsemantics as the C3 state.
87edd84e48SNate LawsonDeeper sleeps provide more power savings but increased transition
88edd84e48SNate Lawsonlatency when an interrupt occurs.
89edd84e48SNate Lawson.El
9044cb3ab0SHiroki Sato.Sh LOADER TUNABLES
913184cf5aSNate LawsonTunables can be set at the
9287b6284aSRuslan Ermilov.Xr loader 8
933184cf5aSNate Lawsonprompt before booting the kernel or stored in
943184cf5aSNate Lawson.Pa /boot/loader.conf .
95edd84e48SNate Lawson.Bl -tag -width indent
96edd84e48SNate Lawson.It Va acpi_dsdt_load
97edd84e48SNate LawsonEnables loading of a custom ACPI DSDT.
98edd84e48SNate Lawson.It Va acpi_dsdt_name
99edd84e48SNate LawsonName of the DSDT table to load, if loading is enabled.
100edd84e48SNate Lawson.It Va debug.acpi.disabled
101edd84e48SNate LawsonSelectively disables portions of ACPI for debugging purposes.
10226db811eSNate Lawson.It Va debug.acpi.max_threads
10326db811eSNate LawsonSpecify the number of task threads that are started on boot.
10426db811eSNate LawsonLimiting this to 1 may help work around various BIOSes that cannot
10526db811eSNate Lawsonhandle parallel requests.
10626db811eSNate LawsonThe default value is 3.
10747bc6a5eSNate Lawson.It Va debug.acpi.quirks
10847bc6a5eSNate LawsonOverride any automatic quirks completely.
109edd84e48SNate Lawson.It Va hint.acpi.0.disabled
110edd84e48SNate LawsonSet this to 1 to disable all of ACPI.
111edd84e48SNate LawsonIf ACPI has been disabled on your system due to a blacklist entry for your
112edd84e48SNate LawsonBIOS, you can set this to 0 to re-enable ACPI for testing.
113edd84e48SNate Lawson.It Va hw.acpi.ec.poll_timeout
114edd84e48SNate LawsonDelay in milliseconds to wait for the EC to respond.
115edd84e48SNate LawsonTry increasing this number if you get the error
1162010c542SRuslan Ermilov.Qq Li AE_NO_HARDWARE_RESPONSE .
11747bc6a5eSNate Lawson.It Va hw.acpi.host_mem_start
11847bc6a5eSNate LawsonOverride the assumed memory starting address for PCI host bridges.
119edd84e48SNate Lawson.It Va hw.acpi.pci.link.%d.%d.%d.irq
120edd84e48SNate LawsonOverride the interrupt to use.
121edd84e48SNate Lawson.It Va hw.acpi.reset_video
122edd84e48SNate LawsonEnables calling the VESA reset BIOS vector on the resume path.
123edd84e48SNate LawsonSome graphic chips have problems such as LCD white-out after resume.
124edd84e48SNate LawsonTry setting this to 0 if this causes problems for you.
125edd84e48SNate Lawson.It Va hw.acpi.serialize_methods
126edd84e48SNate LawsonAllow override of whether methods execute in parallel or not.
1272010c542SRuslan ErmilovEnable this for serial behavior, which fixes
1282010c542SRuslan Ermilov.Qq Li AE_ALREADY_EXISTS
1292010c542SRuslan Ermiloverrors for
1302010c542SRuslan ErmilovAML that really cannot handle parallel method execution.
131edd84e48SNate LawsonIt is off by default since this breaks recursive methods and some IBMs use
132edd84e48SNate Lawsonsuch code.
133edd84e48SNate Lawson.It Va hw.acpi.verbose
134edd84e48SNate LawsonTurn on verbose debugging information about what ACPI is doing.
135b6695bd0SMike Smith.El
136edd84e48SNate Lawson.Sh DISABLING ACPI
137edd84e48SNate LawsonSince ACPI support on different platforms varies greatly, there are many
138edd84e48SNate Lawsondebugging and tuning options available.
139b6695bd0SMike Smith.Pp
14007e2d046SMark SantcroosFor machines known not to work with
14107e2d046SMark Santcroos.Nm
14255c71dc9SMark Santcroosenabled, there is a BIOS blacklist.
14355c71dc9SMark SantcroosCurrently, the blacklist only controls whether
14407e2d046SMark Santcroos.Nm
14555c71dc9SMark Santcroosshould be disabled or not.
14655c71dc9SMark SantcroosIn the future, it will have more granularity to control features (the
14755c71dc9SMark Santcroosinfrastructure for that is already there).
14807e2d046SMark Santcroos.Pp
14907e2d046SMark SantcroosTo enable
15007e2d046SMark Santcroos.Nm
15155c71dc9SMark Santcroos(for debugging purposes, etc.) on machines that are on the blacklist, set the
15255c71dc9SMark Santcrooskernel environment variable
15307e2d046SMark Santcroos.Va hint.acpi.0.disabled
15455c71dc9SMark Santcroosto 0.
15555c71dc9SMark SantcroosBefore trying this, consider updating your BIOS to a more recent version that
15655c71dc9SMark Santcroosmay be compatible with ACPI.
15707e2d046SMark Santcroos.Pp
1584e3148f4SWarner LoshTo disable the
1594e3148f4SWarner Losh.Nm
1604e3148f4SWarner Loshdriver completely, set the kernel environment variable
1614e3148f4SWarner Losh.Va hint.acpi.0.disabled
162d865f9efSWes Petersto 1.
163d865f9efSWes Peters.Pp
1644e3148f4SWarner LoshSome i386 machines totally fail to operate with some or all of ACPI disabled.
1654e3148f4SWarner LoshOther i386 machines fail with ACPI enabled.
166edd84e48SNate LawsonDisabling all or part of ACPI on non-i386 platforms (i.e., platforms where
167edd84e48SNate LawsonACPI support is mandatory) may result in a non-functional system.
1684e3148f4SWarner Losh.Pp
169b6695bd0SMike SmithThe
170b6695bd0SMike Smith.Nm
171b6695bd0SMike Smithdriver comprises a set of drivers, which may be selectively disabled
172b6695bd0SMike Smithin case of problems.
173b6695bd0SMike SmithTo disable a sub-driver, list it in the kernel
174b6695bd0SMike Smithenvironment variable
1753184cf5aSNate Lawson.Va debug.acpi.disabled .
17637c51fd9SNate LawsonMultiple entries can be listed, separated by a space.
177b6695bd0SMike Smith.Pp
178b6695bd0SMike SmithACPI sub-devices and features that can be disabled:
1792010c542SRuslan Ermilov.Bl -tag -width ".Li sysresource"
18037c51fd9SNate Lawson.It Li all
181e821c364SNate LawsonDisable all ACPI features and devices.
18218974fe8SNate Lawson.It Li acad
18318974fe8SNate Lawson.Pq Vt device
18418974fe8SNate LawsonSupports AC adapter.
18587b6284aSRuslan Ermilov.It Li bus
186b6695bd0SMike Smith.Pq Vt feature
187b6695bd0SMike SmithProbes and attaches subdevices.
188b6695bd0SMike SmithDisabling will avoid scanning the ACPI namespace entirely.
18987b6284aSRuslan Ermilov.It Li children
190b6695bd0SMike Smith.Pq Vt feature
191b6695bd0SMike SmithAttaches standard ACPI sub-drivers and devices enumerated in the
192b6695bd0SMike SmithACPI namespace.
193b6695bd0SMike SmithDisabling this has a similar effect to disabling
19487b6284aSRuslan Ermilov.Dq Li bus ,
195b6695bd0SMike Smithexcept that the
196b6695bd0SMike SmithACPI namespace will still be scanned.
19787b6284aSRuslan Ermilov.It Li button
198b6695bd0SMike Smith.Pq Vt device
199bf7f20c2SRuslan ErmilovSupports ACPI button devices (typically power and sleep buttons).
20037c51fd9SNate Lawson.It Li cmbat
20137c51fd9SNate Lawson.Pq Vt device
20237c51fd9SNate LawsonControl-method batteries device.
20337c51fd9SNate Lawson.It Li cpu
20437c51fd9SNate Lawson.Pq Vt device
20537c51fd9SNate LawsonSupports CPU power-saving and speed-setting functions.
20687b6284aSRuslan Ermilov.It Li ec
207b6695bd0SMike Smith.Pq Vt device
20837c51fd9SNate LawsonSupports the ACPI Embedded Controller interface, used to communicate
20937c51fd9SNate Lawsonwith embedded platform controllers.
21087b6284aSRuslan Ermilov.It Li isa
211b6695bd0SMike Smith.Pq Vt device
212b6695bd0SMike SmithSupports an ISA bus bridge defined in the ACPI namespace,
213b6695bd0SMike Smithtypically as a child of a PCI bus.
21487b6284aSRuslan Ermilov.It Li lid
215b6695bd0SMike Smith.Pq Vt device
216b6695bd0SMike SmithSupports an ACPI laptop lid switch, which typically puts a
217b6695bd0SMike Smithsystem to sleep.
2184e376d58SNate Lawson.It Li quirks
2194e376d58SNate Lawson.Pq Vt feature
220bf7f20c2SRuslan ErmilovDo not honor quirks.
2214e376d58SNate LawsonQuirks automatically disable ACPI functionality based on the XSDT table's
2224e376d58SNate LawsonOEM vendor name and revision date.
22387b6284aSRuslan Ermilov.It Li pci
224b6695bd0SMike Smith.Pq Vt device
225b6695bd0SMike SmithSupports Host to PCI bridges.
22637c51fd9SNate Lawson.It Li pci_link
227e821c364SNate Lawson.Pq Vt feature
22837c51fd9SNate LawsonPerforms PCI interrupt routing.
22937c51fd9SNate Lawson.It Li sysresource
23037c51fd9SNate Lawson.Pq Vt device
23137c51fd9SNate LawsonPseudo-devices containing resources which ACPI claims.
23287b6284aSRuslan Ermilov.It Li thermal
233b6695bd0SMike Smith.Pq Vt device
234b6695bd0SMike SmithSupports system cooling and heat management.
23587b6284aSRuslan Ermilov.It Li timer
236b6695bd0SMike Smith.Pq Vt device
237b6695bd0SMike SmithImplements a timecounter using the ACPI fixed-frequency timer.
238401cdd95STom Rhodes.It Li video
239401cdd95STom Rhodes.Pq Vt device
2404f068961SRuslan ErmilovSupports
2414f068961SRuslan Ermilov.Xr acpi_video 4
2424f068961SRuslan Ermilovwhich may conflict with
2434f068961SRuslan Ermilov.Xr agp 4
2444f068961SRuslan Ermilovdevice.
245b6695bd0SMike Smith.El
246b6695bd0SMike Smith.Pp
247b6695bd0SMike SmithIt is also possible to avoid portions of the ACPI namespace which
248b6695bd0SMike Smithmay be causing problems, by listing the full path of the root of
249b6695bd0SMike Smiththe region to be avoided in the kernel environment variable
250b6695bd0SMike Smith.Va debug.acpi.avoid .
251b6695bd0SMike SmithThe object and all of its children will be ignored during the
25287b6284aSRuslan Ermilovbus/children scan of the namespace.
253401b484bSNate LawsonThe ACPI CA code will still know about the avoided region.
254edd84e48SNate Lawson.Sh DEBUGGING OUTPUT
255edd84e48SNate LawsonTo enable debugging output,
256edd84e48SNate Lawson.Nm
257edd84e48SNate Lawsonmust be compiled with
2582010c542SRuslan Ermilov.Cd "options ACPI_DEBUG" .
259edd84e48SNate LawsonDebugging output is separated between layers and levels, where a layer is
260edd84e48SNate Lawsona component of the ACPI subsystem, and a level is a particular kind
261edd84e48SNate Lawsonof debugging output.
262edd84e48SNate Lawson.Pp
263edd84e48SNate LawsonBoth layers and levels are specified as a whitespace-separated list of
264edd84e48SNate Lawsontokens, with layers listed in
265edd84e48SNate Lawson.Va debug.acpi.layer
266edd84e48SNate Lawsonand levels in
267edd84e48SNate Lawson.Va debug.acpi.level .
268401b484bSNate Lawson.Pp
269401b484bSNate LawsonThe first set of layers is for ACPI-CA components, and the second is for
270401b484bSNate Lawson.Fx
271401b484bSNate Lawsondrivers.
272401b484bSNate LawsonThe ACPI-CA layer descriptions include the prefix for the files they
273401b484bSNate Lawsonrefer to.
274edd84e48SNate LawsonThe supported layers are:
275edd84e48SNate Lawson.Pp
2762010c542SRuslan Ermilov.Bl -tag -compact -width ".Li ACPI_CA_DISASSEMBLER"
277edd84e48SNate Lawson.It Li ACPI_UTILITIES
278401b484bSNate LawsonUtility ("ut") functions
279edd84e48SNate Lawson.It Li ACPI_HARDWARE
280401b484bSNate LawsonHardware access ("hw")
281edd84e48SNate Lawson.It Li ACPI_EVENTS
282401b484bSNate LawsonEvent and GPE ("ev")
283edd84e48SNate Lawson.It Li ACPI_TABLES
284401b484bSNate LawsonTable access ("tb")
285edd84e48SNate Lawson.It Li ACPI_NAMESPACE
286401b484bSNate LawsonNamespace evaluation ("ns")
287edd84e48SNate Lawson.It Li ACPI_PARSER
288401b484bSNate LawsonAML parser ("ps")
289edd84e48SNate Lawson.It Li ACPI_DISPATCHER
290401b484bSNate LawsonInternal representation of interpreter state ("ds")
291edd84e48SNate Lawson.It Li ACPI_EXECUTER
292401b484bSNate LawsonExecute AML methods ("ex")
293edd84e48SNate Lawson.It Li ACPI_RESOURCES
294401b484bSNate LawsonResource parsing ("rs")
295edd84e48SNate Lawson.It Li ACPI_CA_DEBUGGER
296401b484bSNate LawsonDebugger implementation ("db", "dm")
297edd84e48SNate Lawson.It Li ACPI_OS_SERVICES
298401b484bSNate LawsonUsermode support routines ("os")
299edd84e48SNate Lawson.It Li ACPI_CA_DISASSEMBLER
300401b484bSNate LawsonDisassembler implementation (unused)
301edd84e48SNate Lawson.It Li ACPI_ALL_COMPONENTS
302edd84e48SNate LawsonAll the above ACPI-CA components
303edd84e48SNate Lawson.It Li ACPI_AC_ADAPTER
304edd84e48SNate LawsonAC adapter driver
305edd84e48SNate Lawson.It Li ACPI_BATTERY
306edd84e48SNate LawsonControl-method battery driver
307edd84e48SNate Lawson.It Li ACPI_BUS
308edd84e48SNate LawsonACPI, ISA, and PCI bus drivers
309edd84e48SNate Lawson.It Li ACPI_BUTTON
310edd84e48SNate LawsonPower and sleep button driver
311edd84e48SNate Lawson.It Li ACPI_EC
312edd84e48SNate LawsonEmbedded controller driver
313edd84e48SNate Lawson.It Li ACPI_FAN
314edd84e48SNate LawsonFan driver
315edd84e48SNate Lawson.It Li ACPI_OEM
316edd84e48SNate LawsonPlatform-specific driver for hotkeys, LED, etc.
317edd84e48SNate Lawson.It Li ACPI_POWER
318edd84e48SNate LawsonPower resource driver
319edd84e48SNate Lawson.It Li ACPI_PROCESSOR
320edd84e48SNate LawsonCPU driver
321edd84e48SNate Lawson.It Li ACPI_THERMAL
322edd84e48SNate LawsonThermal zone driver
323edd84e48SNate Lawson.It Li ACPI_TIMER
324edd84e48SNate LawsonTimer driver
325edd84e48SNate Lawson.It Li ACPI_ALL_DRIVERS
326edd84e48SNate LawsonAll the above
327edd84e48SNate Lawson.Fx
328edd84e48SNate LawsonACPI drivers
329edd84e48SNate Lawson.El
330edd84e48SNate Lawson.Pp
331edd84e48SNate LawsonThe supported levels are:
332edd84e48SNate Lawson.Pp
3332010c542SRuslan Ermilov.Bl -tag -compact -width ".Li ACPI_LV_AML_DISASSEMBLE"
334edd84e48SNate Lawson.It Li ACPI_LV_ERROR
335401b484bSNate LawsonFatal error conditions
336edd84e48SNate Lawson.It Li ACPI_LV_WARN
337401b484bSNate LawsonWarnings and potential problems
338edd84e48SNate Lawson.It Li ACPI_LV_INIT
339401b484bSNate LawsonInitialization progress
340edd84e48SNate Lawson.It Li ACPI_LV_DEBUG_OBJECT
341401b484bSNate LawsonStores to objects
342edd84e48SNate Lawson.It Li ACPI_LV_INFO
343401b484bSNate LawsonGeneral information and progress
344edd84e48SNate Lawson.It Li ACPI_LV_ALL_EXCEPTIONS
345401b484bSNate LawsonAll the previous levels
346edd84e48SNate Lawson.It Li ACPI_LV_INIT_NAMES
347edd84e48SNate Lawson.It Li ACPI_LV_PARSE
348edd84e48SNate Lawson.It Li ACPI_LV_LOAD
349edd84e48SNate Lawson.It Li ACPI_LV_DISPATCH
350edd84e48SNate Lawson.It Li ACPI_LV_EXEC
351edd84e48SNate Lawson.It Li ACPI_LV_NAMES
352edd84e48SNate Lawson.It Li ACPI_LV_OPREGION
353edd84e48SNate Lawson.It Li ACPI_LV_BFIELD
354edd84e48SNate Lawson.It Li ACPI_LV_TABLES
355edd84e48SNate Lawson.It Li ACPI_LV_VALUES
356edd84e48SNate Lawson.It Li ACPI_LV_OBJECTS
357edd84e48SNate Lawson.It Li ACPI_LV_RESOURCES
358edd84e48SNate Lawson.It Li ACPI_LV_USER_REQUESTS
359edd84e48SNate Lawson.It Li ACPI_LV_PACKAGE
360edd84e48SNate Lawson.It Li ACPI_LV_VERBOSITY1
361401b484bSNate LawsonAll the previous levels
362edd84e48SNate Lawson.It Li ACPI_LV_ALLOCATIONS
363edd84e48SNate Lawson.It Li ACPI_LV_FUNCTIONS
364edd84e48SNate Lawson.It Li ACPI_LV_OPTIMIZATIONS
365edd84e48SNate Lawson.It Li ACPI_LV_VERBOSITY2
366edd84e48SNate Lawson.It Li ACPI_LV_ALL
367edd84e48SNate Lawson.It Li ACPI_LV_MUTEX
368edd84e48SNate Lawson.It Li ACPI_LV_THREADS
369edd84e48SNate Lawson.It Li ACPI_LV_IO
370edd84e48SNate Lawson.It Li ACPI_LV_INTERRUPTS
371edd84e48SNate Lawson.It Li ACPI_LV_VERBOSITY3
372401b484bSNate LawsonAll the previous levels
373edd84e48SNate Lawson.It Li ACPI_LV_AML_DISASSEMBLE
374edd84e48SNate Lawson.It Li ACPI_LV_VERBOSE_INFO
375edd84e48SNate Lawson.It Li ACPI_LV_FULL_TABLES
376edd84e48SNate Lawson.It Li ACPI_LV_EVENTS
377edd84e48SNate Lawson.It Li ACPI_LV_VERBOSE
378401b484bSNate LawsonAll levels after
379401b484bSNate Lawson.Qq Li ACPI_LV_VERBOSITY3
380edd84e48SNate Lawson.El
381edd84e48SNate Lawson.Pp
382edd84e48SNate LawsonSelection of the appropriate layer and level values is important
383edd84e48SNate Lawsonto avoid massive amounts of debugging output.
384401b484bSNate LawsonFor example, the following configuration is a good way to gather initial
385401b484bSNate Lawsoninformation.
386401b484bSNate LawsonIt enables debug output for both ACPI-CA and the
387401b484bSNate Lawson.Nm
388401b484bSNate Lawsondriver, printing basic information about errors, warnings, and progress.
389401b484bSNate Lawson.Bd -literal -offset indent
390401b484bSNate Lawsondebug.acpi.layer="ACPI_ALL_COMPONENTS ACPI_ALL_DRIVERS"
391401b484bSNate Lawsondebug.acpi.level="ACPI_LV_ALL_EXCEPTIONS"
392401b484bSNate Lawson.Ed
393edd84e48SNate Lawson.Pp
394edd84e48SNate LawsonDebugging output by the ACPI CA subsystem is prefixed with the
395edd84e48SNate Lawsonmodule name in lowercase, followed by a source line number.
396edd84e48SNate LawsonOutput from the
397edd84e48SNate Lawson.Fx Ns -local
398edd84e48SNate Lawsoncode follows the same format, but
399edd84e48SNate Lawsonthe module name is uppercased.
400f0da5f56STakanori Watanabe.Sh OVERRIDING YOUR BIOS BYTECODE
401287460e8SNate LawsonACPI interprets bytecode named AML
402287460e8SNate Lawson(ACPI Machine Language)
403287460e8SNate Lawsonprovided by the BIOS vendor as a memory image at boot time.
404287460e8SNate LawsonSometimes, the AML code contains a bug that does not appear when parsed
405287460e8SNate Lawsonby the Microsoft implementation.
406287460e8SNate Lawson.Fx
407287460e8SNate Lawsonprovides a way to override it with your own AML code to work around
408287460e8SNate Lawsonor debug such problems.
409287460e8SNate LawsonNote that all AML in your DSDT and any SSDT tables is overridden.
410f0da5f56STakanori Watanabe.Pp
411287460e8SNate LawsonIn order to load your AML code, you must edit
412f0da5f56STakanori Watanabe.Pa /boot/loader.conf
413287460e8SNate Lawsonand include the following lines.
414f0da5f56STakanori Watanabe.Bd -literal -offset indent
415f0da5f56STakanori Watanabeacpi_dsdt_load="YES"
416287460e8SNate Lawsonacpi_dsdt_name="/boot/acpi_dsdt.aml" # You may change this name.
417f0da5f56STakanori Watanabe.Ed
418f0da5f56STakanori Watanabe.Pp
419a627f55aSRuslan ErmilovIn order to prepare your AML code, you will need the
420a627f55aSRuslan Ermilov.Xr acpidump 8
421a627f55aSRuslan Ermilovand
4222010c542SRuslan Ermilov.Xr iasl 8
423297835bcSNate Lawsonutilities and some ACPI knowledge.
424b6695bd0SMike Smith.Sh COMPATIBILITY
4256b74f9b7SNate LawsonACPI is only found and supported on i386/ia32, ia64, and amd64.
426b6695bd0SMike Smith.Sh SEE ALSO
4275413d9e0SWes Peters.Xr kenv 1 ,
428673fbcacSRuslan Ermilov.Xr acpi_thermal 4 ,
4295413d9e0SWes Peters.Xr device.hints 5 ,
430f0da5f56STakanori Watanabe.Xr loader.conf 5 ,
431f64a0a56SRobert Watson.Xr acpiconf 8 ,
432f0da5f56STakanori Watanabe.Xr acpidump 8 ,
433297835bcSNate Lawson.Xr config 8 ,
434297835bcSNate Lawson.Xr iasl 8
435f0da5f56STakanori Watanabe.Rs
436a627f55aSRuslan Ermilov.%A "Compaq Computer Corporation"
437a627f55aSRuslan Ermilov.%A "Intel Corporation"
438a627f55aSRuslan Ermilov.%A "Microsoft Corporation"
439a627f55aSRuslan Ermilov.%A "Phoenix Technologies Ltd."
440a627f55aSRuslan Ermilov.%A "Toshiba Corporation"
441c25a3f8aSNate Lawson.%D August 25, 2003
442f0da5f56STakanori Watanabe.%T "Advanced Configuration and Power Interface Specification"
443f0da5f56STakanori Watanabe.%O http://acpi.info/spec.htm
444f0da5f56STakanori Watanabe.Re
44587b6284aSRuslan Ermilov.Sh AUTHORS
44687b6284aSRuslan Ermilov.An -nosplit
447b6695bd0SMike SmithThe ACPI CA subsystem is developed and maintained by
448b6695bd0SMike SmithIntel Architecture Labs.
449b6695bd0SMike Smith.Pp
450b6695bd0SMike SmithThe following people made notable contributions to the ACPI subsystem
451b6695bd0SMike Smithin
452b6695bd0SMike Smith.Fx :
453718a5d6aSNate Lawson.An Michael Smith ,
45487b6284aSRuslan Ermilov.An Takanori Watanabe Aq takawata@jp.FreeBSD.org ,
45587b6284aSRuslan Ermilov.An Mitsuru IWASAKI Aq iwasaki@jp.FreeBSD.org ,
456b6695bd0SMike Smith.An Munehiro Matsuda ,
457718a5d6aSNate Lawson.An Nate Lawson ,
458b6695bd0SMike Smiththe ACPI-jp mailing list at
45987b6284aSRuslan Ermilov.Aq acpi-jp@jp.FreeBSD.org ,
460b6695bd0SMike Smithand many other contributors.
461b6695bd0SMike Smith.Pp
462b6695bd0SMike SmithThis manual page was written by
46387b6284aSRuslan Ermilov.An Michael Smith Aq msmith@FreeBSD.org .
464b6695bd0SMike Smith.Sh BUGS
465d1f717d1SMike SmithIf the
466d1f717d1SMike Smith.Nm
467d1f717d1SMike Smithdriver is loaded as a module when it is already linked as part of the
468d1f717d1SMike Smithkernel, odd things may happen.
469