Contribute
Register
Status
Not open for further replies.
Joined
Apr 25, 2014
Messages
88
Motherboard
Lenovo ThinkPad Edge E530
CPU
i5-3210M / HM77
Graphics
GT 635M / HD 4000, 1366x768
Mac
  1. MacBook
  2. Mac mini
Mobile Phone
  1. iOS
Hello there!

My laptop won't wake up from sleep, if it was booted on battery (without AC cable attached) - making some noise after keypress, but no any sings of life (LED sleep indicator shows that it is in sleep mode, and I have fixed it, yes).
When booted with AC cable attached, sleep works almost fine.

I tried everything I could, but no luck. Maybe, you can help me a little bit?

Here some general information about my laptop and problems I have (maybe useful):
  • I have an Intel HM77 chipset and Intel Core i5-3210m processor + NVIDIA GeForce GT 635m graphics card (disabled via DSDT at _INI, also I have added _PST/_WAK solution for sleep).
  • OEM Tables CpuPM and CPU0ICst are dropped, instead I use ssdt, generated by ssdtPRGen.sh script.
  • Powermanagement for CPU and iGPU is working, as far as I know.
  • But ACPIBacklight.kext or IntelBacklight.kext both broking my brightness on laptop screen (black screen), have no idea why, so I'm not using those.
  • USB ports all work, but after AC sleep some devices taking time too turn on again (for example, my 2.0 port, web cam and bluetooth). Also, it take a 10-20 or more seconds before my laptop goes to sleep completely (it's weird, on Windows 10 it takes second, not a half of a minute).
  • And I have applied a _PRW 0x00 solution, to resolve InstantWake problem.
  • Battery status and Brightness controls work fine (but I have some problems with brightness diapason (backlight shots down at least value and isn't bright enough at highest value)).
  • I have no WiFi, because my wi-fi card isn't supported by macOS, but it's bluetooth chip does, so I use a BRCMPatchRAM2 solution.
 

Attachments

  • Problem Reporting.zip
    5.2 MB · Views: 233
BTW, I noticed that I have created this thread in a wrong category, but I can't neither move or delete it.
Sorry for that, but selection interface wasn't intuitive enough.
 
Hello there!

My laptop won't wake up from sleep, if it was booted on battery (without AC cable attached) - making some noise after keypress, but no any sings of life (LED sleep indicator shows that it is in sleep mode, and I have fixed it, yes).
When booted with AC cable attached, sleep works almost fine.

I tried everything I could, but no luck. Maybe, you can help me a little bit?

Here some general information about my laptop and problems I have (maybe useful):
  • I have an Intel HM77 chipset and Intel Core i5-3210m processor + NVIDIA GeForce GT 635m graphics card (disabled via DSDT at _INI, also I have added _PST/_WAK solution for sleep).
  • OEM Tables CpuPM and CPU0ICst are dropped, instead I use ssdt, generated by ssdtPRGen.sh script.
  • Powermanagement for CPU and iGPU is working, as far as I know.
  • But ACPIBacklight.kext or IntelBacklight.kext both broking my brightness on laptop screen (black screen), have no idea why, so I'm not using those.
  • USB ports all work, but after AC sleep some devices taking time too turn on again (for example, my 2.0 port, web cam and bluetooth). Also, it take a 10-20 or more seconds before my laptop goes to sleep completely (it's weird, on Windows 10 it takes second, not a half of a minute).
  • And I have applied a _PRW 0x00 solution, to resolve InstantWake problem.
  • Battery status and Brightness controls work fine (but I have some problems with brightness diapason (backlight shots down at least value and isn't bright enough at highest value)).
  • I have no WiFi, because my wi-fi card isn't supported by macOS, but it's bluetooth chip does, so I use a BRCMPatchRAM2 solution.
moved to laptop support
 
I also have to say, that I already tried to rebuild my DSDTs from scratch.
Here's my rebuilded dsdt, just in case. It makes no difference for me, except for more fan noise (if I drop OEM _DSM methods).
Maybe it can help you to determine the wake problem reason.

And _PTS/_WAK NVIDIA patch also makes no difference (for the Battery sleep), but fixed AC sleep (without it my laptop won't wake). Maybe I should add somewhere else _ON/_OFF methods?

Here's my _WAK method:

Code:
    Method (_WAK, 1, NotSerialized)  // _WAK: Wake
    {
        If (LOr (LLess (Arg0, One), LGreater (Arg0, 0x05)))
        {
            Store (0x03, Arg0)
        }

        If (LEqual (Arg0, 0x03))
        {
            Store (0xE3, P80H)
        }

        If (LEqual (Arg0, 0x04))
        {
            Store (0xE4, P80H)
        }

        If (LEqual (Arg0, 0x05))
        {
            Store (0xE5, P80H)
        }

        If (LOr (LEqual (Arg0, Zero), LGreaterEqual (Arg0, 0x05)))
        {
            If (DRWN)
            {
                If (CondRefOf (\_SB.PCI0.PEG0.PEGP._OFF))
                {
                    \_SB.PCI0.PEG0.PEGP._OFF ()
                }
            }

            Return (WAKI)
        }

        Store (Zero, SPS)
        Store (Zero, \_SB.PCI0.LPCB.EC.HCMU)
        \_SB.PCI0.LPCB.EC.EVNT (One)
        \_SB.PCI0.LPCB.EC.HKEY.MHKE (One)
        \_SB.PCI0.LPCB.EC.FNST ()
        UCMS (0x0D)
        Store (Zero, LIDB)
        If (LEqual (Arg0, One))
        {
            Store (\_SB.PCI0.LPCB.EC.HFNI, FNID)
        }

        If (LEqual (Arg0, 0x03))
        {
            NVSS (Zero)
            \_SB.PCI0.LPCB.EC.LED (Zero, 0x80)
            Store (\_SB.PCI0.LPCB.EC.AC._PSR (), PWRS)
            \_SB.PCI0.LPCB.EC.HKEY.WGIN ()
            If (OSC4)
            {
                PNTF (0x81)
            }

            If (LNotEqual (ACST, \_SB.PCI0.LPCB.EC.AC._PSR ()))
            {
                \_SB.PCI0.LPCB.EC.ATMC ()
            }

            If (SCRM)
            {
                Store (0x07, \_SB.PCI0.LPCB.EC.HFSP)
                If (MTAU)
                {
                    Store (0x03E8, Local2)
                    While (LAnd (\_SB.PCI0.LPCB.EC.PIBS, Local2))
                    {
                        Sleep (One)
                        Decrement (Local2)
                    }

                    If (Local2)
                    {
                        Store (One, \_SB.PCI0.LPCB.EC.PLSL)
                        Store (MTAU, \_SB.PCI0.LPCB.EC.PLTU)
                        Store (PL1L, \_SB.PCI0.LPCB.EC.PLLS)
                        Store (PL1M, \_SB.PCI0.LPCB.EC.PLMS)
                    }
                }
            }

            If (LEqual (ISWK, One))
            {
                If (\_SB.PCI0.LPCB.EC.HKEY.DHKC)
                {
                    \_SB.PCI0.LPCB.EC.HKEY.MHKQ (0x6070)
                }
            }

            If (VIGD)
            {
                \_SB.PCI0.IGPU.GLIS (\_SB.LID0._LID ())
                If (WVIS)
                {
                    VBTD ()
                }
            }

            VCMS (One, \_SB.LID0._LID ())
            AWON (Zero)
            If (CMPR)
            {
                Store (Zero, CMPR)
            }

            Store (B1B2 (\_SB.PCI0.LPCB.EC.AK00, \_SB.PCI0.LPCB.EC.AK01), Local0)
            If (And (Local0, 0x04))
            {
                If (LNotEqual (ISWK, One))
                {
                    Notify (\_SB.PWRB, 0x02)
                }
            }
        }

        If (LEqual (Arg0, 0x04))
        {
            NVSS (Zero)
            \_SB.PCI0.LPCB.EC.HKEY.WGIN ()
            Store (Zero, \_SB.PCI0.LPCB.EC.HSPA)
            Store (\_SB.PCI0.LPCB.EC.AC._PSR (), PWRS)
            If (LEqual (\_SB.PCI0.LPCB.EC.DCWW, One))
            {
                Store (One, GP39)
            }
            Else
            {
                Store (Zero, GP39)
            }

            If (OSC4)
            {
                PNTF (0x81)
            }

            \_SB.PCI0.LPCB.EC.ATMC ()
            If (VIGD)
            {
                \_SB.PCI0.IGPU.GLIS (\_SB.LID0._LID ())
                If (WVIS)
                {
                    VBTD ()
                }
            }

            VCMS (One, \_SB.LID0._LID ())
            Notify (\_SB.LID0, 0x80)
            If (LNot (NBCF))
            {
                If (VIGD)
                {
                    \_SB.PCI0.LPCB.EC.BRNS ()
                }
                Else
                {
                    VBRC (BRLV)
                }
            }
        }

        \_SB.PCI0.LPCB.EC.BATW (Arg0)
        \_SB.PCI0.LPCB.EC.HKEY.WGWK (Arg0)
        Notify (\_TZ.TZ01, 0x80)
        VSLD (\_SB.LID0._LID ())
        If (VIGD)
        {
            \_SB.PCI0.IGPU.GLIS (\_SB.LID0._LID ())
        }

        If (LLess (Arg0, 0x04))
        {
            If (And (RRBF, 0x02))
            {
                ShiftLeft (Arg0, 0x08, Local0)
                Store (Or (0x2013, Local0), Local0)
                \_SB.PCI0.LPCB.EC.HKEY.MHKQ (Local0)
            }
        }

        If (LEqual (Arg0, 0x04))
        {
            Store (Zero, Local0)
            Store (CSUM (Zero), Local1)
            If (LNotEqual (Local1, CHKC))
            {
                Store (One, Local0)
                Store (Local1, CHKC)
            }

            Store (CSUM (One), Local1)
            If (LNotEqual (Local1, CHKE))
            {
                Store (One, Local0)
                Store (Local1, CHKE)
            }

            If (Local0)
            {
                Notify (_SB, Zero)
            }
        }

        Store (B1B2 (\_SB.PCI0.LPCB.EC.AK00, \_SB.PCI0.LPCB.EC.AK01), Local0)
        If (And (Local0, One))
        {
            And (Local0, 0xFE, Local0)
            Store (Local0, \_SB.PCI0.LPCB.EC.AK00)
            Store (ShiftRight (Local0, 0x08), \_SB.PCI0.LPCB.EC.AK01)
        }

        If (And (Local0, 0x02))
        {
            And (Local0, 0xFD, Local0)
            Store (Local0, \_SB.PCI0.LPCB.EC.AK00)
            Store (ShiftRight (Local0, 0x08), \_SB.PCI0.LPCB.EC.AK01)
        }

        If (And (Local0, 0x04))
        {
            And (Local0, 0xFB, Local0)
            Store (Local0, \_SB.PCI0.LPCB.EC.AK00)
            Store (ShiftRight (Local0, 0x08), \_SB.PCI0.LPCB.EC.AK01)
        }

        If (And (Local0, 0x10))
        {
            And (Local0, 0xEF, Local0)
            Store (Local0, \_SB.PCI0.LPCB.EC.AK00)
            Store (ShiftRight (Local0, 0x08), \_SB.PCI0.LPCB.EC.AK01)
        }

        If (And (Local0, 0x40))
        {
            And (Local0, 0xBF, Local0)
            Store (Local0, \_SB.PCI0.LPCB.EC.AK00)
            Store (ShiftRight (Local0, 0x08), \_SB.PCI0.LPCB.EC.AK01)
        }

        Store (Zero, RRBF)
        Return (WAKI)
    }

And I can see a two Return (WAKI) calls.
If I add _OFF method at the end, before return, it doesn't change anythings, it seems.
 

Attachments

  • dsdt_rebuld.aml
    47.4 KB · Views: 368
Last edited:
Hello there!

My laptop won't wake up from sleep, if it was booted on battery (without AC cable attached) - making some noise after keypress, but no any sings of life (LED sleep indicator shows that it is in sleep mode, and I have fixed it, yes).
When booted with AC cable attached, sleep works almost fine.

I tried everything I could, but no luck. Maybe, you can help me a little bit?

Here some general information about my laptop and problems I have (maybe useful):
  • I have an Intel HM77 chipset and Intel Core i5-3210m processor + NVIDIA GeForce GT 635m graphics card (disabled via DSDT at _INI, also I have added _PST/_WAK solution for sleep).
  • OEM Tables CpuPM and CPU0ICst are dropped, instead I use ssdt, generated by ssdtPRGen.sh script.
  • Powermanagement for CPU and iGPU is working, as far as I know.
  • But ACPIBacklight.kext or IntelBacklight.kext both broking my brightness on laptop screen (black screen), have no idea why, so I'm not using those.
  • USB ports all work, but after AC sleep some devices taking time too turn on again (for example, my 2.0 port, web cam and bluetooth). Also, it take a 10-20 or more seconds before my laptop goes to sleep completely (it's weird, on Windows 10 it takes second, not a half of a minute).
  • And I have applied a _PRW 0x00 solution, to resolve InstantWake problem.
  • Battery status and Brightness controls work fine (but I have some problems with brightness diapason (backlight shots down at least value and isn't bright enough at highest value)).
  • I have no WiFi, because my wi-fi card isn't supported by macOS, but it's bluetooth chip does, so I use a BRCMPatchRAM2 solution.

No "Problem Reporting" files attached.
Read FAQ, "Problem Reporting" again. Carefully. Attach all requested files/output.
https://www.tonymacx86.com/threads/faq-read-first-laptop-frequent-questions.164990/
 
There was a Data.zip file, I have renamed it to Problem Reporting.
All requested output should be inside.
 
There was a Data.zip file, I have renamed it to Problem Reporting.
All requested output should be inside.

Post #4, dated Nov 27, says you re-patched ACPI.
Post #1 files have ACPI/patched/DSDT.aml dated Nov 26.
Any change requires all new "problem reporting" files.
Also, the *.aml files in ACPI/origin in post #1 are messy. You need to remove all files from ACPI/origin, then press F4 to collect new ones.
 
Well, I've figured out, that this problem has nothing to do with DSDT/SSDTs, Clover or macOS...
Apparently, Lenovo's BIOS/UEFI is a garbage.
Case the same problem appears on other operation systems - on windows an linux.

And I also have solved this problem via downgrading my BIOS/UEFI firmware, and some other problems to.
BTW, there is also a problem when Clover just stucks on boot if CSM mode is disabled (image artifacts appears and nothing works).
Also, I can't use an HDMI or VGA during boot, it CSM is disabled.
And sometimes I can't enter boot menu or even BIOS/UEFI setting.
Furthermore, i can't change BIOS/UEFI setting normally, cause it often ends with CRC Checksum Error (This problem is quite common).

So solution for me was full BIOS reset (setting reset, CMOS reset via removing CMOS battery and again setting reset with OS Optimized setting afterwards), then enabling BIOS/UEFI rollback option, and downgrading to very first version (1.07) available for my device (and again, BIOS/UEFI setting reset), then upgrading to last stable version 2.52 (2.54, 2.55 are broken and has those problems, I've described above).
BTW, you can't downgrade from 2.x versions to 2.x version for some reason, but downgrade to 1.x and then upgrade to 2.x is a solution for this.

After this steps I have repatched my DSDTs again, using your guide (as always), and now all works fine.

And I have to say, that my fan is working more silently if I use T_X names instead of _T_X in some _DST. And it also works better, then if I rename those _DSM methods to XDSM.

Just in case, PNOT/PPTN are empty (patched). CpuPM and CPU0Ist are dropped, instead I use generated SSDT for my CPU.

In conclusion, I have 3 hours of battery life at normal usage and medium brightness.
 
And I have to say, that my fan is working more silently if I use T_X names instead of _T_X in some _DST. And it also works better, then if I rename those _DSM methods to XDSM.

T_X->_T_X rename is completely unnecessary. You are imagining things if you think this makes a material difference.
_DSM->XDSM is required if you're adding _DSM methods (either with static patch, or add-on SSDTs).

Just in case, PNOT/PPTN are empty (patched). CpuPM and CPU0Ist are dropped, instead I use generated SSDT for my CPU.

This is "alternate DropTables" as detailed in my guide.
Best to avoid this unless actually needed.
 
Maybe, I'm imagining things, now it makes no difference for me, since it works as I wanted it to.
Still, I wan't to figure out if I did it right.

I have an Ivy Bridge (i5-3210m) processor with HM77 chipset.
Now, the only problem I have is that after sleep my card reader isn't working and after long sleep my ethernet loses network. It still seems to work, but can't find ethernet network properly (For example, DHCP not working, networks isn't working, LEDs blinking and some random adresses are generation on cable re-attach, but not those that should be there).
Both devices are PCIe devices, so it has nothing to do with USB sleep problems, as far as I know.

I saw your "alternate DropTables" option in Filtering ACPI files entry, but it's clearly written that it's for Sandy Bridge and older.

So, should I drop my OEM CPU related tables and use a generated one or not?
My laptop is working with original tables, but without CPU/GPU power management and Intel SpeedStep and at constant 2.5 Ghz frequency.

I"ll send all neccessary files a little bit later on.
 
Status
Not open for further replies.
Back
Top