Contribute
Register

(Req) DSDT patch for detect fan RPM on Asus laptop

Status
Not open for further replies.
You can see where OSDD reads the fan speed... from CFSP at _SB.PCI0.LPCB.H_EC.CFSP. You will need to find where CFSP is defined.

I didn't find the definition for CFSP in any table, even in the dynamics, i've extracted all tables with my linux box. What i can do in this case?
 
I didn't find the definition for CFSP in any table, even in the dynamics, i've extracted all tables with my linux box. What i can do in this case?

Nothing. The PTID table is invalid and useless. You can only go the "reverse engineer" route, where you use something like RW-Everything to see if you can determine where in the EC the fan speed is held.
 
Hi ReHab, i'm new at the forum. I've been following your post and your guides, with great success.

I've almost configured my Asus G51jx perfectly. The only thing left now is the fan control. The biggest problem of this laptop is the high temp. It can get to 90 C. :thumbdown:

I've installed HWSensors v6.11. My CPU fan didn't appeared. So, I applied your Acer patch and I got it to appear. The problem is that it doesn't return any value ("-"), so, i can't manually set the speed. See attachment.

Here is the DSDT patch:

Code:
Device (SMCD)    {
        Name (_HID, "MON0000")
        OperationRegion (ECRM, EmbeddedControl, Zero, 0xFF)
        Field (ECRM, ByteAcc, Lock, Preserve)
        {
                    Offset (0x93), 
            BIOS,   8, 
            FSPD,   8, 
                    Offset (0xA8), 
            CPUD,   8, 
                    Offset (0xAF), 
            GPUD,   8
        }


        Method (FAN0, 0, Serialized)
        {
            Store (FSPD, Local0)
            If (LEqual (Local0, 0xFF))
            {
                Store (Zero, Local0)
            }


            If (Local0)
            {
                Add (0x0003C000, ShiftRight (Local0, One), Local1)
                Divide (Local1, Local0, , Local0)
            }


            Return (Local0)
        }


        Method (TCPU, 0, Serialized)
        {
            Return (CPUD)
        }


        Method (TGPU, 0, Serialized)
        {
            Return (GPUD)
        }


        Name (FTAB, Buffer (0x24)
        {
            /* 0000 */    0x39, 0x73, 0x3C, 0x6D, 0x3D, 0x67, 0x3E, 0x60, 
            /* 0008 */    0x3F, 0x5A, 0x40, 0x57, 0x41, 0x55, 0x42, 0x52, 
            /* 0010 */    0x43, 0x50, 0x44, 0x4D, 0x45, 0x49, 0x46, 0x44, 
            /* 0018 */    0x47, 0x40, 0x48, 0x3B, 0x49, 0x38, 0x4A, 0x34, 
            /* 0020 */    0x4B, 0x31, 0xFF, 0x00
        })
        Name (FHST, Buffer (0x10)
        {
            /* 0000 */    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
            /* 0008 */    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
        })
        Name (FIDX, Zero)
        Name (FNUM, Zero)
        Name (FSUM, Zero)
        Name (FLST, 0xFF)
        Name (FCNT, Zero)
        Name (FCTU, 0x14)
        Name (FCTD, 0x28)
        Method (FCPU, 0, Serialized)
        {
            Store (0x14, BIOS)
            Store (CPUD, Local0)
            Add (Local0, FSUM, Local1)
            Store (FIDX, Local2)
            Subtract (Local1, DerefOf (Index (FHST, Local2)), Local1)
            Store (Local0, Index (FHST, Local2))
            Store (Local1, FSUM)
            Increment (Local2)
            If (LGreaterEqual (Local2, SizeOf (FHST)))
            {
                Store (Zero, Local2)
            }


            Store (Local2, FIDX)
            Store (FNUM, Local2)
            If (LNotEqual (Local2, SizeOf (FHST)))
            {
                Increment (Local2)
                Store (Local2, FNUM)
            }


            Divide (Local1, Local2, , Local0)
            If (LGreater (Local0, 0xFF))
            {
                Store (0xFF, Local0)
            }


            Store (Zero, Local2)
            While (LGreater (Local0, DerefOf (Index (FTAB, Local2))))
            {
                Add (Local2, 0x02, Local2)
            }


            If (LGreater (Local2, FLST))
            {
                Subtract (Local2, FLST, Local1)
                Store (FCTU, Local4)
            }
            Else
            {
                Subtract (FLST, Local2, Local1)
                Store (FCTD, Local4)
            }


            If (LEqual (Local1, Zero))
            {
                Store (Zero, FCNT)
            }
            Else
            {
                Store (FCNT, Local3)
                Increment (Local3)
                Store (Local3, FCNT)
                Divide (ShiftLeft (Local4, One), Local1, , Local1)
                If (LGreaterEqual (Local3, Local1))
                {
                    Store (Local2, FLST)
                    Increment (Local2)
                    Store (DerefOf (Index (FTAB, Local2)), FSPD)
                    Store (Zero, FCNT)
                }
            }


            Return (Local0)
        }


        Method (TCPP, 0, Serialized)
        {
            Store (FNUM, Local0)
            If (LNotEqual (Local0, Zero))
            {
                Store (FSUM, Local1)
                Divide (Local1, Local0, , Local0)
            }


            Return (Local0)
        }


        Method (TSYS, 0, Serialized)
        {
            Return (FCNT)
        }
    }
}


I hope you can guide me with the following steps. I've read that the user "el_charlie" got success, debugging the ACPI with one of your kext's (or something like that).

Any help is appreciated,

Thank you in advance!

Best regards,

Juan
 

Attachments

  • Fan speed problem.png
    Fan speed problem.png
    217.6 KB · Views: 453
Hi ReHab, i'm new at the forum. I've been following your post and your guides, with great success.

I've almost configured my Asus G51jx perfectly. The only thing left now is the fan control. The biggest problem of this laptop is the high temp. It can get to 90 C. :thumbdown:

I've installed HWSensors v6.11. My CPU fan didn't appeared. So, I applied your Acer patch and I got it to appear. The problem is that it doesn't return any value ("-"), so, i can't manually set the speed. See attachment.

You have an ASUS. A patch for an Acer is not likely to work. For that matter, it doesn't work on most Acer laptops, and was never tested on the intended laptop as the person who requested it lost interest.

Note: Your CPU temperature issue is more likely a power management issue.
 
Status
Not open for further replies.
Back
Top