Merge the last updates I have for ACPI. This just includes markup fixes
and the like.
This commit is contained in:
parent
f6bef84959
commit
bbbab1a75e
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/head/; revision=20056
1 changed files with 62 additions and 57 deletions
|
@ -2332,7 +2332,7 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
<acronym>ACPI-CA</acronym> interpreter continue to appear.</para>
|
||||
|
||||
<para>This document is intended to help you assist the &os;
|
||||
<acronym>ACPI</acronym> maintainers in identifying the culprit
|
||||
<acronym>ACPI</acronym> maintainers in identifying the root cause
|
||||
of problems you observe and debugging and developing a solution.
|
||||
Thanks for reading this and we hope we can solve your system's
|
||||
problems.</para>
|
||||
|
@ -2350,7 +2350,7 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
<para>Description of the buggy behavior, including system type
|
||||
and model and anything that causes the bug to appear. Also,
|
||||
please note as accurately as possible when the bug began
|
||||
occuring if it is new for you.</para>
|
||||
occurring if it is new for you.</para>
|
||||
</listitem>
|
||||
|
||||
<listitem>
|
||||
|
@ -2397,7 +2397,8 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
us track the problem and resolve it. Do not send a
|
||||
<acronym>PR</acronym> without emailing acpi-jp first as we use
|
||||
<acronym>PR</acronym>s as reminders of existing problems, not a
|
||||
reporting mechanism.</para>
|
||||
reporting mechanism. It is likely that your problem has been
|
||||
reported by someone before.</para>
|
||||
</sect2>
|
||||
|
||||
<sect2 id="ACPI-background">
|
||||
|
@ -2411,11 +2412,11 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
controllers, and bus enumeration. Most systems implement less
|
||||
than the full standard. For instance, a desktop system usually
|
||||
only implements the bus enumeration parts while a laptop might
|
||||
have a lot of cooling and battery management support as well.
|
||||
Laptops also have suspend and resume, with their own associated
|
||||
have cooling and battery management support as well. Laptops
|
||||
also have suspend and resume, with their own associated
|
||||
complexity.</para>
|
||||
|
||||
<para>An <acronym>ACPIM</acronym>-compliant system has various
|
||||
<para>An <acronym>ACPI</acronym>-compliant system has various
|
||||
components. The <acronym>BIOS</acronym> and chipset vendors
|
||||
provide various fixed tables (e.g., <acronym>FADT</acronym>)
|
||||
in memory that specify things like the <acronym>APIC</acronym>
|
||||
|
@ -2429,11 +2430,12 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
device drivers and the kernel to accept information from the
|
||||
<acronym>ACPI</acronym> subsystem. For &os;, Intel has
|
||||
provided an interpreter (<acronym>ACPI-CA</acronym>) that is
|
||||
shared with Linux and NetBSD. The path to
|
||||
<acronym>ACPI-CA</acronym> is
|
||||
<filename>src/sys/contrib/dev/acpica</filename>. The glue code
|
||||
that allows <acronym>ACPI-CA</acronym> to work on &os; is in
|
||||
<filename>src/sys/dev/acpica/Osd.</filename> Finally, drivers
|
||||
shared with Linux and NetBSD. The path to the
|
||||
<acronym>ACPI-CA</acronym> source code is
|
||||
<filename role="directory">src/sys/contrib/dev/acpica</filename>.
|
||||
The glue code that allows <acronym>ACPI-CA</acronym> to work on
|
||||
&os; is in
|
||||
<filename>src/sys/dev/acpica/Osd</filename>. Finally, drivers
|
||||
that implement various <acronym>ACPI</acronym> devices are found
|
||||
in
|
||||
<filename role="directory">src/sys/dev/acpica</filename>.</para>
|
||||
|
@ -2475,7 +2477,8 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
<literal>S4</literal><acronym>OS</acronym>, and
|
||||
<literal>S5</literal>. If <option>s4bios</option> was one
|
||||
(1), I would have <literal>S4</literal><acronym>BIOS</acronym>
|
||||
instead of <literal>S4</literal><acronym>OS</acronym>.</para>
|
||||
support instead of <literal>S4</literal>
|
||||
<acronym>OS</acronym>.</para>
|
||||
|
||||
<para>When testing suspend/resume, start with
|
||||
<literal>S1</literal>, if supported. This state is most
|
||||
|
@ -2539,8 +2542,7 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
the <acronym>BIOS</acronym> configures interrupts before boot,
|
||||
correctness of the <acronym>APIC</acronym>
|
||||
(<acronym>MADT</acronym>) table, and routing of the
|
||||
<acronym>SCI</acronym>. There are several patches and ad-hoc
|
||||
workarounds that may help.</para>
|
||||
<acronym>SCI</acronym>.</para>
|
||||
|
||||
<para>Interrupt storms can be distinguished from lost interrupts
|
||||
by checking the output of <command>vmstat</command>
|
||||
|
@ -2550,8 +2552,12 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
system appears hung, try breaking to <acronym>DDB</acronym>
|
||||
(<keycombo action="simul"><keycap>CTRL</keycap>
|
||||
<keycap>ALT</keycap><keycap>ESC</keycap></keycombo> on
|
||||
console) and type <command>show interrupts</command>. Patches
|
||||
to try if you get an interrupt storm are:</para>
|
||||
console) and type <option>show interrupts</option>.</para>
|
||||
|
||||
<para>Your best hope when dealing with interrupt problems is to
|
||||
try disabling <acronym>APIC</acronym> support with
|
||||
<option>hint.apic.0.disable=</option><quote>1</quote> in
|
||||
<filename>loader.conf</filename>.</para>
|
||||
</sect3>
|
||||
|
||||
<sect3>
|
||||
|
@ -2570,11 +2576,23 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
|
||||
<para>Then, try to isolate the problem by booting with
|
||||
<acronym>ACPI</acronym> disabled. If that works, you can
|
||||
isolate the <acronym>ACP</acronym>I subsystem by using various
|
||||
isolate the <acronym>ACPI</acronym> subsystem by using various
|
||||
values of <option>debug.acpi.disable</option>. See the
|
||||
&man.acpi.4; manual page for some examples.</para>
|
||||
</sect3>
|
||||
|
||||
<sect3>
|
||||
<title>System Powers Up After Suspend or Shutdown</title>
|
||||
<para>First, try setting
|
||||
<option>hw.acpi.disable_on_poweroff=</option><quote>0</quote>
|
||||
in &man.loader.conf.5;. This keeps <acronym>ACPI</acronym>
|
||||
from disabling various events during the shutdown process.
|
||||
Some systems need this value set to <quote>1</quote> (the
|
||||
default) for the same reason. This usually fixes
|
||||
the problem of a system powering up spontaneously after a
|
||||
suspend or poweroff.</para>
|
||||
</sect3>
|
||||
|
||||
<sect3>
|
||||
<title>Other Problems</title>
|
||||
|
||||
|
@ -2597,8 +2615,7 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
is usually manifested by kernel console messages like
|
||||
this:</para>
|
||||
|
||||
<screen>ACPI-1287: *** Error: Method execution failed</screen>
|
||||
<screen>[\\_SB_.PCI0.LPC0.FIGD._STA] (Node 0xc3f6d160), AE_NOT_FOUND</screen>
|
||||
<screen>ACPI-1287: *** Error: Method execution failed [\\_SB_.PCI0.LPC0.FIGD._STA] (Node 0xc3f6d160), AE_NOT_FOUND</screen>
|
||||
|
||||
<para>Often, you can resolve these problems by updating your
|
||||
<acronym>BIOS</acronym> to the latest revision. Most console
|
||||
|
@ -2657,44 +2674,28 @@ device_probe_and_attach: cbb0 attach returned 12</screen>
|
|||
various Windows versions. You can tell &os; to claim it is
|
||||
any <acronym>OS</acronym> to see if this fixes problems you
|
||||
may have. An easy way to override this is to set
|
||||
<option>hw.acpi.os_name</option>=<quote>Windows 2001</quote>
|
||||
<option>hw.acpi.osname</option>=<quote>Windows 2001</quote>
|
||||
in <filename>/boot/loader.conf</filename> or other similar
|
||||
strings you find in the <acronym>ASL</acronym>. You could
|
||||
also manually change references to <literal>_OS</literal> or
|
||||
<literal>_OS_</literal> (they are the same thing) to check for
|
||||
<quote>&os;</quote>. For example:</para>
|
||||
|
||||
<programlisting>If (MCTH (\_OS, "Microsoft Windows NT"))
|
||||
{
|
||||
Return (PIC1)
|
||||
}
|
||||
Else
|
||||
{
|
||||
Return (PIC0)
|
||||
}</programlisting>
|
||||
|
||||
<para>Modified to look for &os;:</para>
|
||||
|
||||
<programlisting>If (MCTH (\_OS, "FreeBSD"))
|
||||
{
|
||||
Return (PIC1)
|
||||
}
|
||||
Else
|
||||
{
|
||||
Return (PIC0)
|
||||
}</programlisting>
|
||||
strings you find in the <acronym>ASL</acronym>.</para>
|
||||
|
||||
<sect3>
|
||||
<title>Missing Return statements</title>
|
||||
|
||||
<para>Explaination of these things.</para>
|
||||
<para>Some methods do not explicitly return a value as the
|
||||
standard requires. While <acronym>ACPI-CA</acronym>
|
||||
does not handle this, &os; has a workaround that allows it to
|
||||
return the value implicitly. You can also add explicit
|
||||
Return statements where required if you know what value should
|
||||
be returned. To force <command>iasl</command> to compile the
|
||||
<acronym>ASL</acronym>, use the <option>-f</option>
|
||||
flag.</para>
|
||||
</sect3>
|
||||
|
||||
<sect3>
|
||||
<title>Overriding the Default <acronym>AML</acronym></title>
|
||||
|
||||
<para>After you customize <filename>your.asl</filename>, it
|
||||
will need rebuilt, run:</para>
|
||||
<para>After you customize <filename>your.asl</filename>, you
|
||||
will want to compile it, run:</para>
|
||||
|
||||
<screen>&prompt.root; <userinput>iasl your.asl</userinput></screen>
|
||||
|
||||
|
@ -2708,13 +2709,14 @@ Else
|
|||
filename for <command>iasl</command>. You can load this
|
||||
instead of your <acronym>BIOS</acronym>'s buggy copy (which
|
||||
is still present in flash memory) by editing
|
||||
<filename>/boot/loader.conf</filename> as follows:</para>
|
||||
<filename role="directory">/boot/loader.conf</filename> as
|
||||
follows:</para>
|
||||
|
||||
<programlisting>acpi_dsdt_load="YES"
|
||||
acpi_dsdt_name="/boot/DSDT.aml"</programlisting>
|
||||
|
||||
<para>Be sure to copy your <filename>DSDT.aml</filename> to the
|
||||
<filename>/boot</filename> directory.</para>
|
||||
<filename role="directory">/boot</filename> directory.</para>
|
||||
</sect3>
|
||||
|
||||
<sect2 id="ACPI-debugoutput">
|
||||
|
@ -2722,15 +2724,17 @@ acpi_dsdt_name="/boot/DSDT.aml"</programlisting>
|
|||
<acronym>ACPI</acronym></title>
|
||||
|
||||
<para>The <acronym>ACPI</acronym> driver has a very flexible
|
||||
debuging facility. It allows you to specify a set of subsystems
|
||||
debugging facility. It allows you to specify a set of subsystems
|
||||
as well as the level of verbosity. The subsystems you wish to
|
||||
debug are specified as <quote>layers</quote> and are broken down
|
||||
into <acronym>ACPI-CA</acronym> components (ACPI_ALL_COMPONENTS)
|
||||
and <acronym>ACPI</acronym> hardware support (ACPI_ALL_DRIVERS).
|
||||
The verbosity of debugging output is specified as the
|
||||
<quote>level</quote> and ranges from ACPI_LV_ERROR (just report
|
||||
errors) to ACPI_LV_VERBOSE (everything). In practice, you will
|
||||
want to use a serial console to log the output if it is so long
|
||||
errors) to ACPI_LV_VERBOSE (everything). The
|
||||
<quote>level</quote> is a bitmask so multiple options can be set
|
||||
at once, separated by spaces. In practice, you will want to use
|
||||
a serial console to log the output if it is so long
|
||||
it flushes the console message buffer. A full list of the
|
||||
individual layers and levels is found in the &man.acpi.4; manual
|
||||
page.</para>
|
||||
|
@ -2748,10 +2752,11 @@ acpi_dsdt_name="/boot/DSDT.aml"</programlisting>
|
|||
ACPI_DEBUG=1</userinput></screen>
|
||||
|
||||
<para>Install <filename>acpi.ko</filename> in
|
||||
<filename>/boot/kernel</filename> and add your desired level and
|
||||
layer to <filename>loader.conf</filename>. This example enables
|
||||
debug messages for all <acronym>ACPI-CA</acronym> components and
|
||||
all <acronym>ACPI</acronym> hardware drivers
|
||||
<filename role="directory">/boot/kernel</filename> and add your
|
||||
desired level and layer to <filename>loader.conf</filename>.
|
||||
This example enables debug messages for all
|
||||
<acronym>ACPI-CA</acronym> components and all
|
||||
<acronym>ACPI</acronym> hardware drivers
|
||||
(<acronym>CPU</acronym>, <acronym>LID</acronym>, etc.) It will
|
||||
only output error messages, the least verbose level.</para>
|
||||
|
||||
|
@ -2802,7 +2807,7 @@ debug.acpi.level="ACPI_LV_ERROR"</programlisting>
|
|||
<para><ulink
|
||||
url="http://www.cpqlinux.com/acpi-howto.html#fix_broken_dsdt">
|
||||
<acronym>DSDT</acronym> debugging resource</ulink>.
|
||||
(Uses Compaq as an example but useful.)</para>
|
||||
(Uses Compaq as an example but generally useful.)</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</sect2>
|
||||
|
|
Loading…
Reference in a new issue