Help with the DSDT for an Acer Ferrari 3400 laptop
Hello,
I'm new to this ACPI world and I'd like your help to fix the dsdt.dsl file that I got with this laptop. I followed the steps in the ACPI FAQ to disassemble the bin file and ended up with a source file that compiles with 8 errors and 1 warning using the Intel ASL compiler.
For your reference the problem I want to fix is that I have no control over the fan which is always on, quite annoying. Even though my Linux kernel has compiled ACPI fan support the directory /proc/acpi/fan is empty. I'm running vanilla kernel 2.6.10 with Debian-AMD64.
The good news is that the 8 errors are actually the same one spread all over the source file. So fixing it once will fix the whole file. The bad news is that I don't know how to fix it :|
The Error
---------
dsdt.dsl 4480: If (LLess (\_PR.CPU0._PPC, Local1))
Error 1022 - Object does not exist ^ (\_PR.CPU0._PPC)
The error is repeated every time the object \_PR.CPU0._PPC appears in the code. I read in the FAQ that one possible solution is to use the statement
External(\_PR.CPU0._PPC)
to tell the compiler that this is an external object. However I don't understand where this External statement should go. I've tried putting it at the beginning of the file and inside the Scope(\_PR) section which simply reads
Scope (\_PR)
{
Processor (CPU0, 0x00, 0x00004010, 0x06) {}
}In both cases the compiler complains. So, where shall this External statement go?
The Warning
-----------
dsdt.dsl 4287: Method (SMSL, 0, NotSerialized)
Warning 2019 - ^ Not all control paths return a value (SMSL)
I added a Return (0x00) statement at the very end of the method and the warning disappeared. But, is this right? Following my signature you will find the code of the offending method including my extra line.
Thanks in advance for any advice you can give me.
Signature · 101 lines
Pedro
Name (ACFL, 0x00)
Method (SMSL, 0, NotSerialized)
{
Store ("CMBatt - SMSL", Debug)
If (LEqual (\_SB.ECOK, 0x00))
{
Return (0xFF)
}
Acquire (\_SB.PCI0.PIB.EC0.MUT1, 0xFFFF)
If (LNot (\_SB.PCI0.PIB.EC0.SMRD (0x09, 0x14,
0x01, RefOf (Local0))))
{
Store (Local0, SEL0)
Store (SEL0, Debug)
If (LEqual (ALRT, 0x01))
{
\_SB.BAT1.IVBI ()
\_SB.BAT1.IVBS ()
Store (0x00, ALRT)
}
Store (\_SB.ACAD.CHAC (SEL0), Local1)
Store (\_SB.BAT1.CHBP (SEL0), Local2)
Or (SEL0, 0x0FFF, Local0)
SMWR (0x08, 0x14, 0x01, Local0)
If (LAnd (Local1, \_SB.ACAD.ACP))
{
Store ("CMBatt - Notify(ACAD,0x80):
AC_Inserted", Debug)
Notify (\_SB.ACAD, 0x80)
Store (0x02, ACFL)
}
If (And (0x04, Local2))
{
\_SB.BAT1.B1CK ()
}
If (And (0x02, Local2))
{
\_SB.BAT1.B1ST ()
}
If (And (0x01, Local2))
{
\_SB.BAT1.B1IF ()
}
If (LAnd (Local1, LNot (\_SB.ACAD.ACP)))
{
Store ("CMBatt - Notify(ACAD, 0x80):
AC_Removed", Debug)
Notify (\_SB.ACAD, 0x80)
Store (0x01, ACFL)
}
}
Store (0x3C, Local4)
If (\_SB.BAT1.REPT)
{
Store (0x02, Local4)
}
If (BFLG)
{
Store (0x01, Local5)
While (LNot (And (BFLG, 0x01)))
{
Increment (Local5)
ShiftRight (BFLG, 0x01, BFLG)
}
ShiftRight (BFLG, 0x01, BFLG)
If (LGreater (Local4, Local5))
{
Store (Local5, Local4)
}
}
Store (Local4, BPD)
BPOL ()
Release (\_SB.PCI0.PIB.EC0.MUT1)
If (ACFL)
{
Decrement (ACFL)
Store (0x00, ACFL)
}
Return (0x00)
}
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/Quoted 32 lines · Pedro I. Sanchez
Hello,
I'm new to this ACPI world and I'd like your help to fix the dsdt.dsl file that I got with this laptop. I followed the steps in the ACPI FAQ to disassemble the bin file and ended up with a source file that compiles with 8 errors and 1 warning using the Intel ASL compiler.
For your reference the problem I want to fix is that I have no control over the fan which is always on, quite annoying. Even though my Linux kernel has compiled ACPI fan support the directory
/proc/acpi/fanis empty. I'm running vanilla kernel 2.6.10 with Debian-AMD64.The good news is that the 8 errors are actually the same one spread all over the source file. So fixing it once will fix the whole file. The bad news is that I don't know how to fix it :|
The Error
---------
dsdt.dsl 4480: If (LLess (\_PR.CPU0._PPC, Local1))
Error 1022 - Object does not exist ^ (\_PR.CPU0._PPC)The error is repeated every time the object \_PR.CPU0._PPC appears in the code. I read in the FAQ that one possible solution is to use the statement
External(\_PR.CPU0._PPC)to tell the compiler that this is an external object. However I don't understand where this External statement should go. I've tried putting it at the beginning of the file and inside the
Scope(\_PR)section which simply reads
Quoted 7 lines
Scope (\_PR) { Processor (CPU0, 0x00, 0x00004010, 0x06) {} }In both cases the compiler complains. So, where shall this External statement go?
They go to a SSDT table likely. If you do something like:
sudo ./acpidmp SSDT > ssdt
and
iasl -d ssdt
you should get those external statements.
Quoted 8 lines
The Warning
-----------
dsdt.dsl 4287: Method (SMSL, 0, NotSerialized)
Warning 2019 - ^ Not all control paths return a value (SMSL)I added a Return (
0x00) statement at the very end of the method and the warning disappeared. But, is this right? Following my signature you will find the code of the offending method including my extra line.
Could you send me the original DSDT please (or better the full acpidmp) or even better provide a link?
I don't think it's very problematic, but I need to look a little bit further to be sure. This method is "internal" and is called by other methods, so need to check what those methods do with the return value.
Cheers,
Signature · 11 lines
Bruno Ducrot -- Which is worse: ignorance or apathy? -- Don't know. Don't care. ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/
Quoted 26 lines · Bruno Ducrot
Quoted 24 lines · Pedro I. Sanchez
Hello,
I'm new to this ACPI world and I'd like your help to fix the dsdt.dsl file that I got with this laptop. I followed the steps in the ACPI FAQ to disassemble the bin file and ended up with a source file that compiles with 8 errors and 1 warning using the Intel ASL compiler.
For your reference the problem I want to fix is that I have no control over the fan which is always on, quite annoying. Even though my Linux kernel has compiled ACPI fan support the directory
/proc/acpi/fanis empty. I'm running vanilla kernel 2.6.10 with Debian-AMD64.The good news is that the 8 errors are actually the same one spread all over the source file. So fixing it once will fix the whole file. The bad news is that I don't know how to fix it :|
The Error
---------
dsdt.dsl 4480: If (LLess (\_PR.CPU0._PPC, Local1))
Error 1022 - Object does not exist ^ (\_PR.CPU0._PPC)The error is repeated every time the object \_PR.CPU0._PPC appears in the code. I read in the FAQ that one possible solution is to use the statement
External(\_PR.CPU0._PPC)to tell the compiler that this is an external object. However I don't understand where this External statement should go. I've tried putting it at the beginning of the file and inside the
Scope(\_PR)section which simply readsScope (\_PR) { Processor (CPU0, 0x00, 0x00004010, 0x06) {} }
Quoted 9 lines
Quoted 1 line
In both cases the compiler complains. So, where shall this External statement go?
They go to a SSDT table likely. If you do something like:
sudo ./acpidmp SSDT > ssdt
and
iasl -d ssdt
you should get those external statements.
I'm looking for acpidmp in my Debian box but I can't find it, it's not in the pmtools package. And I can't find it in the Intel's download page either (http://www.intel.com/technology/iapc/acpi/downloads.htm). Where can I get it?
Also, what am I supposed to do after disassembling the ssdt?
Quoted 6 lines
Quoted 6 lines
The Warning
-----------
dsdt.dsl 4287: Method (SMSL, 0, NotSerialized)
Warning 2019 - ^ Not all control paths return a value (SMSL)
Quoted 6 lines
Quoted 1 line
I added a Return (
0x00) statement at the very end of the method and the warning disappeared. But, is this right? Following my signature you will find the code of the offending method including my extra line.Could you send me the original DSDT please (or better the full acpidmp) or even better provide a link?
You will find the DSDT and some other files at http://www.colcan.biz
Quoted 6 lines
I don't think it's very problematic, but I need to look a little bit further to be sure. This method is "internal" and is called by other methods, so need to check what those methods do with the return value.
Cheers,
Thank you for your follow up.
Signature · 7 lines
Pedro ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/
Quoted 8 lines · Pedro I. Sanchez
Quoted 7 lines
They go to a SSDT table likely. If you do something like:
sudo ./acpidmp SSDT > ssdt
and
iasl -d ssdt
you should get those external statements.
Quoted 4 lines
I'm looking for acpidmp in my Debian box but I can't find it, it's not in the pmtools package. And I can't find it in the Intel's download page either (http://www.intel.com/technology/iapc/acpi/downloads.htm). Where can I get it?
Oops sorry. I supposed you got the DSDT with acpidmp..
wget ftp://ftp.kernel.org//pub/linux/kernel/people/lenb/acpi/utils/pmtools-20031210.tar.bz2 make
sudo ./acpidmp > acpidmp.out
bzip2 acpidmp.out
NB: the debian package 'pmtools' is for some perl stuff (perl modules tools)...
Quoted 1 line
Also, what am I supposed to do after disassembling the ssdt?
Nothing. You asked where are the external statements. I just wanted to tell you where you can find them, and how to read them.
Quoted 10 lines
Quoted 10 lines
Quoted 8 lines
The Warning
-----------
dsdt.dsl 4287: Method (SMSL, 0, NotSerialized)
Warning 2019 - ^ Not all control paths return a value (SMSL)I added a Return (
0x00) statement at the very end of the method and the warning disappeared. But, is this right? Following my signature you will find the code of the offending method including my extra line.
Quoted 5 lines
Quoted 3 lines
Could you send me the original DSDT please (or better the full acpidmp) or even better provide a link?
You will find the DSDT and some other files at http://www.colcan.biz
Ok. Thanks.
SMSL() is only called as:
Method (_Q09, 0, NotSerialized)
{
Store ("QUERY_09", Debug)
SMSL ()
}and
Method (_Q8E, 0, NotSerialized)
{
SMSL ()
Notify (\_SB.BAT1, 0x80)
}so even if the 'return bug' (a bug in some ACPI interpreter) is present, it's not a real trouble. I guess they added a return only to break the method without having to worry to rewrite the method properly. Just adding a return statement do not have any bad side effect but prevent iasl to warn at compile time.
(BTW, there is something like that in the EC0 space:
OperationRegion (ERAM, EmbeddedControl, 0x00, 0xFF)
Field (ERAM, ByteAcc, Lock, Preserve)
{
...
...
Offset (0x18),
SMPR, 8,
SMST, 8,
SMAD, 8,
SMCM, 8,
SMD0, 256,
BCNT, 8,
SMAA, 8,
S1D0, 8,
S1D1, 8,
SM2A, 8,
...
...
}The SMPR, SMST, SMAD, ... indicate very likely a smbus access. Even though there is no HC EC smbus defined in this ASL, the whole ACPI control method battery defined under \_SB.BAT1 indicate that they have written access to a smart battery selector and a smart battery.
I guess Acer bios writers do not want anymore to write those codes for others models, since anyway smartbattery is supported (at spec level) by ACPI 1.0b at least.
Cheers,
Signature · 11 lines
Bruno Ducrot -- Which is worse: ignorance or apathy? -- Don't know. Don't care. ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/
Quoted 1 line · Pedro I. Sanchez
Hello,
...
Quoted 4 lines
For your reference the problem I want to fix is that I have no control over the fan which is always on, quite annoying. Even though my Linux kernel has compiled ACPI fan support the directory
/proc/acpi/fanis empty. I'm running vanilla kernel 2.6.10 with Debian-AMD64.
There is no fan stuff in this ASL so ACPI can't help you. But there is likely a thermal sensor that still have to be found under a smbus?
Cheers,
Signature · 11 lines
Bruno Ducrot -- Which is worse: ignorance or apathy? -- Don't know. Don't care. ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/