Jump to content

Disabling NVIDIA Optimus card on all laptops


Whit3Spirit
 Share

345 posts in this topic

Recommended Posts

gee thanks  <_<

 

What I meant is, why is it not possible to call method SGOF directly from the DSDT using "External (_SB_.PCI0.PEG0.PEGP.SGOF, MethodObj)" as per your guide? Why do I have to copy all those methods from SSDT to DSDT?

 

Yes, it's possible but why make that ?

Link to comment
Share on other sites

Thanks Whit3Spirit for sharing.Work me too

  • Like 1
Link to comment
Share on other sites

please help me i don't know how to fix!

 

attached my dsdt from aida and my ssdt! thank you :)

 

You don't have attached the originaly DSDT and SSDT. ".bin" is the output format from AIDA. And you don't have attached all the SSDT files. This SSDT is for your CPU.

Link to comment
Share on other sites

what do you mean with "And you don't have attached all the SSDT files. This SSDT is for your CPU."?? i only have this SSDT file

Retry to extract SSDT with AIDA because you don't have the method in these files for desactivate the graphic card.

Link to comment
Share on other sites

Hi,WHit3Spirit,I have a question.In your methods M_ON and M_OF, why do you add something like "If (CondRefOf(...)) {...}"? Why not just write

Method (M_ON, 0, NotSerialized)
    {
        \_SB_.PCI0.PEG0.PEGP._ON() 
        \_SB_.PCI0.PEG0.PEGP._PS0()
        \_SB_.PCI0.PEG0.PEGP.SGON()
​    }
Method (M_OF, 0, NotSerialized)
    {
        \_SB_.PCI0.PEG0.PEGP._OFF()
        \_SB_.PCI0.PEG0.PEGP._PS3()
        \_SB_.PCI0.PEG0.PEGP.SGOF()
​    }

Thank you

Link to comment
Share on other sites

Hi,WHit3Spirit,I have a question.In your methods M_ON and M_OF, why do you add something like "If (CondRefOf(...)) {...}"? Why not just write

Method (M_ON, 0, NotSerialized)
    {
        \_SB_.PCI0.PEG0.PEGP._ON() 
        \_SB_.PCI0.PEG0.PEGP._PS0()
        \_SB_.PCI0.PEG0.PEGP.SGON()
​    }
Method (M_OF, 0, NotSerialized)
    {
        \_SB_.PCI0.PEG0.PEGP._OFF()
        \_SB_.PCI0.PEG0.PEGP._PS3()
        \_SB_.PCI0.PEG0.PEGP.SGOF()
​    }

Thank you

That's a good question.

I repeated the formula of RehabMan but I do not know why he chose this. Ask him. ^_^

Link to comment
Share on other sites

That's a good question.

I repeated the formula of RehabMan but I do not know why he chose this. Ask him. ^_^

Precaution. For the case of "pilot error" and SSDT doesn't get loaded in ACPI namespace...

Link to comment
Share on other sites

  • 2 weeks later...

hello,

 

i have an hp envy 17t-j100, haswell i7-4702mq, Intel HD Graphics 4600, nVidia GT 740m

 

i want to turn off my nvidia card, i extracted my dsdt and all ssdt files using linux and latest iasl. just to be sure, i also extracted them using AIDA (windows) and maciasl (with updated iasl 5.0). i had the same result using these methods.

 

i have this ssdt-5.aml file with 11 errors, i don't know how to fix. this is the file i believe that needs to be patched.

 

could you please help me fixing them?

 

find below the iasl log

 

21/06/14 18:38:28, iASLhORJ3g.dsl(1244) : error    6126: syntax error, unexpected PARSEOP_ARG0
21/06/14 18:38:28, iASLhORJ3g.dsl(1505) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'
21/06/14 18:38:28, iASLhORJ3g.dsl(1508) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'
21/06/14 18:38:28, iASLhORJ3g.dsl(1511) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'
21/06/14 18:38:28, iASLhORJ3g.dsl(1512) : error    6126: syntax error, unexpected ')'
21/06/14 18:38:28, iASLhORJ3g.dsl(1512) : error    6126: syntax error, unexpected ')'
21/06/14 18:38:28, iASLhORJ3g.dsl(2625) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'
21/06/14 18:38:28, iASLhORJ3g.dsl(2628) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'
21/06/14 18:38:28, iASLhORJ3g.dsl(2631) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'
21/06/14 18:38:28, iASLhORJ3g.dsl(2632) : error    6126: syntax error, unexpected ')'
21/06/14 18:38:28, iASLhORJ3g.dsl(2632) : error    6126: syntax error, unexpected ')'
21/06/14 18:38:28, ASL Input:     iASLhORJ3g.dsl - 2677 lines, 95262 bytes, 1322 keywords
21/06/14 18:38:28, Compilation complete. 11 Errors, 0 Warnings, 0 Remarks, 0 Optimizations

ssdt5.aml.zip

Link to comment
Share on other sites

hello,

 

i have an hp envy 17t-j100, haswell i7-4702mq, Intel HD Graphics 4600, nVidia GT 740m

 

i want to turn off my nvidia card, i extracted my dsdt and all ssdt files using linux and latest iasl. just to be sure, i also extracted them using AIDA (windows) and maciasl (with updated iasl 5.0). i had the same result using these methods.

 

i have this ssdt-5.aml file with 11 errors, i don't know how to fix. this is the file i believe that needs to be patched.

 

could you please help me fixing them?

 

find below the iasl log

 

21/06/14 18:38:28, iASLhORJ3g.dsl(1244) : error    6126: syntax error, unexpected PARSEOP_ARG0

21/06/14 18:38:28, iASLhORJ3g.dsl(1505) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'

21/06/14 18:38:28, iASLhORJ3g.dsl(1508) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'

21/06/14 18:38:28, iASLhORJ3g.dsl(1511) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'

21/06/14 18:38:28, iASLhORJ3g.dsl(1512) : error    6126: syntax error, unexpected ')'

21/06/14 18:38:28, iASLhORJ3g.dsl(1512) : error    6126: syntax error, unexpected ')'

21/06/14 18:38:28, iASLhORJ3g.dsl(2625) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'

21/06/14 18:38:28, iASLhORJ3g.dsl(2628) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'

21/06/14 18:38:28, iASLhORJ3g.dsl(2631) : error    6126: syntax error, unexpected PARSEOP_RETURN, expecting ',' or ')'

21/06/14 18:38:28, iASLhORJ3g.dsl(2632) : error    6126: syntax error, unexpected ')'

21/06/14 18:38:28, iASLhORJ3g.dsl(2632) : error    6126: syntax error, unexpected ')'

21/06/14 18:38:28, ASL Input:     iASLhORJ3g.dsl - 2677 lines, 95262 bytes, 1322 keywords

21/06/14 18:38:28, Compilation complete. 11 Errors, 0 Warnings, 0 Remarks, 0 Optimizations

Extract all DSDT/SSDT from Linux. Place in a single directory. Use 'iasl -da *' to disassemble them as a group.

  • Like 1
Link to comment
Share on other sites

dear rehabman,

 

sorry for my noobness, your advice worked like a charm.

 

i had only one error, which i could fix easily by deleting a line.

 

i'll try to turn my nvidia 740m card now by following the op steps.

 

thank you very very much, if i suceed i'll post my ssdt file here!

Link to comment
Share on other sites

hello again,

 

unfortunately i am unable to make this method work for me.

 

i use clover bootloader v2721, and the following files in \efi\clover\acpi\patched

 

dsdt.aml (various patches)

ssdt.aml (ssdtPRGen.sh generated)

ssdt-1.aml (brightness fix)

ssdt-2.aml (bcm94352 wifi dualband enabler)

 

for this reason, i cannot set dropoem=false in clover, otherwise i'll loose brightness fix, wifi dualband enabler and speedstep.

 

i'll attach my patched and pure (original) dsdt/ssdt files.

 

i would be grateful if you could let me know how to proceed to turn nvidia card off, without loosing speedstep, brightness fix and wifi dualband.

original_dsdt_ssdt.zip

patched_dsdt_ssdt.zip

Link to comment
Share on other sites

hello again,

 

unfortunately i am unable to make this method work for me.

 

i use clover bootloader v2721, and the following files in \efi\clover\acpi\patched

 

dsdt.aml (various patches)

ssdt.aml (ssdtPRGen.sh generated)

ssdt-1.aml (brightness fix)

ssdt-2.aml (bcm94352 wifi dualband enabler)

 

for this reason, i cannot set dropoem=false in clover, otherwise i'll loose brightness fix, wifi dualband enabler and speedstep.

In order to provide patched SSDTs you must use DropOem=true.

 

i'll attach my patched and pure (original) dsdt/ssdt files.

 

i would be grateful if you could let me know how to proceed to turn nvidia card off, without loosing speedstep, brightness fix and wifi dualband.

In your patched_dsdt_ssdt folder, ssdt-1.aml and ssdt-3.aml are duplicates (well, one is patched and other not).

What is the intention?

 

ssdt-5.dsl should be patched for turning nvidia off. It needs GFX0->IGPU rename and call _OFF from _INI.

 

With Clover, you can keep the original names of the SSDT files (no need to rename sequentially). It may be best to name your additional SSDT files with suffixes 10 or larger (eg. SSDT-10.aml) just to avoid confusion with those SSDTs that are patched.

  • Like 1
Link to comment
Share on other sites

In your patched_dsdt_ssdt folder, ssdt-1.aml and ssdt-3.aml are duplicates (well, one is patched and other not).

What is the intention?

i forgot that i had already used it in ssdt-1.aml. and due to my lack of knowledge, i tried to patch original ssdt4, named ssdt-3.aml, which didn't work.

 

 

ssdt-5.dsl should be patched for turning nvidia off. It needs GFX0->IGPU rename and call _OFF from _INI.

With Clover, you can keep the original names of the SSDT files (no need to rename sequentially). It may be best to name your additional SSDT files with suffixes 10 or larger (eg. SSDT-10.aml) just to avoid confusion with those SSDTs that are patched. 

i'll try to follow your advices and provide proper feedback asap

 

thank you again!

Link to comment
Share on other sites

dear rehabman,

 

i made two attempts to patch ssdt5.dsl

 

in the first one, i tried to follow your instructions

 

in the second one, i tried to implement the op's instructions

 

unfortunately none of them worked, probably due to my lack of knowledge

 

could you please point what i am doing wrong, so i can have directions on what to search and learn?

 

__________________

 

regarding the ssdt*.aml renaming, i renamed

 

ssdt.aml => ssdt_pr.aml

ssdt-1.aml => ssdt14.aml (ssdt4 patched)

ssdt-2.aml => ssdtwf.aml (ssdt wifi dual band enabler)

 

but then clover loaded none of them

 

so i renamed them to their previous names and clover loaded them as usual

 

 

 

if anyone else can help too, any and every help is very welcome!!!

 

thank you!

ssdt5 2 attempts.zip

Link to comment
Share on other sites

dear rehabman,

 

i made two attempts to patch ssdt5.dsl

 

in the first one, i tried to follow your instructions

 

in the second one, i tried to implement the op's instructions

 

unfortunately none of them worked, probably due to my lack of knowledge

 

could you please point what i am doing wrong, so i can have directions on what to search and learn?

 

__________________

 

regarding the ssdt*.aml renaming, i renamed

 

ssdt.aml => ssdt_pr.aml

ssdt-1.aml => ssdt14.aml (ssdt4 patched)

ssdt-2.aml => ssdtwf.aml (ssdt wifi dual band enabler)

 

but then clover loaded none of them

 

 

if anyone else can help too, any and every help is very welcome!!!

 

thank you!

SSDTs must be named SSDT.aml, SSDT-n.aml, or SSDT-nn.aml where n is a digit 0-9, and nn two digits 10-19.

From Clover source:

CHAR16* ACPInames[NUM_TABLES] = {
    L"SSDT.aml",
    L"SSDT-0.aml",
    L"SSDT-1.aml",
    L"SSDT-2.aml",
    L"SSDT-3.aml",
    L"SSDT-4.aml",
    L"SSDT-5.aml",
    L"SSDT-6.aml",
    L"SSDT-7.aml",
    L"SSDT-8.aml",
    L"SSDT-9.aml",
    L"SSDT-10.aml",
    L"SSDT-11.aml",
    L"SSDT-12.aml",
    L"SSDT-13.aml",
    L"SSDT-14.aml",
    L"SSDT-15.aml",
    L"SSDT-16.aml",
    L"SSDT-17.aml",
    L"SSDT-18.aml",
    L"SSDT-19.aml",
    L"APIC.aml",
    L"BOOT.aml",
    L"DMAR.aml",
    L"ECDT.aml",
    L"HPET.aml",
    L"MCFG.aml",
    L"SLIC.aml",
    L"SLIT.aml",
    L"SRAT.aml",
    L"UEFI.aml"
};
So, ssdt_pr.aml, ssdt14.aml, and ssdtwf.aml are all invalid.

 

I think this misunderstanding might have affected your results.

  • Like 1
Link to comment
Share on other sites

i renamed them according to your instructions, but it seems it made no difference comparing to the lowercase letters. but i'll keep the uppercase naming.

 

SSDTs are being loaded (brightness fix implemented from SSDT-14.aml [sSDT-4 patched] is working), but NVIDIA card stays on.

 

could you please tell me if this way of calling _OFF from _INI in SSDT-15.aml (SSDT-5 patched) is correct?

Method (_INI, 0, NotSerialized)  // _INI: Initialize
        {
            _OFF ()
            Store (Zero, \_SB.PCI0.PEG0.PEGP._ADR)
            Store (NVSD, \_SB.PCI0.PEG0.PEGP.NVID)
        }

thank you.

SSDT-15.dsl.zip

Link to comment
Share on other sites

i renamed them according to your instructions, but it seems it made no difference comparing to the lowercase letters. but i'll keep the uppercase naming.

FAT32 is case insensitive.

 

SSDTs are being loaded (brightness fix implemented from SSDT-14.aml [sSDT-4 patched] is working), but NVIDIA card stays on.

 

could you please tell me if this way of calling _OFF from _INI in SSDT-15.aml (SSDT-5 patched) is correct?

Method (_INI, 0, NotSerialized)  // _INI: Initialize
        {
            _OFF ()
            Store (Zero, \_SB.PCI0.PEG0.PEGP._ADR)
            Store (NVSD, \_SB.PCI0.PEG0.PEGP.NVID)
        }

thank you.

 

I would call it at the end of _INI. If still not working, post ioreg (use IORegistryExplorer v2.1).

  • Like 1
Link to comment
Share on other sites

good guide!!!

 

but i haven't followed, what does it mean: "After that, call M_ON method in _PTS (Prepare To Sleep) so that the _WAK after sleep can shutdown the card. (thanks to RehabMan)"

 

it means: the graphic card will be active when the laptop goes to sleep and during the sleep? and then when it wakes, then _wak method is called, and thus the graphic card is shutdown again? is that what you actually mean?


good guide!!!

 

but i haven't followed, what does it mean: "After that, call M_ON method in _PTS (Prepare To Sleep) so that the _WAK after sleep can shutdown the card. (thanks to RehabMan)"

 

it means: the graphic card will be active when the laptop goes to sleep and during the sleep? and then when it wakes, then _wak method is called, and thus the graphic card is shutdown again? is that what you actually mean?

 

but if the graphic card is not active when the _WAK() method wants to call M_OF() during the waking, then it will probably cause error, right?

Link to comment
Share on other sites

good guide!!!

 

but i haven't followed, what does it mean: "After that, call M_ON method in _PTS (Prepare To Sleep) so that the _WAK after sleep can shutdown the card. (thanks to RehabMan)"

 

it means: the graphic card will be active when the laptop goes to sleep and during the sleep? and then when it wakes, then _wak method is called, and thus the graphic card is shutdown again? is that what you actually mean?

Yes, this is a fix for restart/sleep problems. Do this part only if necessary. Based on what we found with the HP ProBook. Your machine/DSDT may vary.

 

And I would suggest calling _ON from the beginning of _PTS, and _OFF from the end of _WAK. Of course, this assumes your _WAK/_PTS are executing from beginning to end, which everyone should verify by using ACPIDebug.kext.

Link to comment
Share on other sites

 Share

×
×
  • Create New...