Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
Status
The first post of this thread is a WikiPost and can be edited by anyone with the appropiate permissions. Your edits will be public.
Hi,
and a big thanks to AppleMacFinder and all the other contributors for this guide! My late 2011 MBP's dGPU died on me 3 weeks ago, I applied this tutorial and since then everything works like a charm!
The only thing that bothers me though--and others have mentioned it--is that the dGPU stays powered on, which keeps the computer quite hot (so the fans speed up for almost nothing) and halves the battery life (at least).
Has anyone tried something to get rid of this issue? I don't get my hopes up, and I guess this is a small price to pay to have this laptop functional again, but still, this is the only thing that would prevent me from keeping it as my main computer for another 2 or 3 years.
Thanks again!
 
Fix for 17 inch dGPU switch issue

(Tested successfully in both “early” and “late” 2011 17 inch MacBook Pro)



This guide is based on the experience of many users (including me) while trying to fix the very well known issue with AMD dGPU on 17’’ MacBook Pro from 2011 (both early and late):



Step 0) As a starting point I made a clean installation of Sierra (Version 10.12.4) — This is just a step for establishing a common middle ground and is not really needed….

0.1) To do this just download the installer from the App Store and then use “DiskMaker X” to create a bootable installation.

0.2) After the bootable image is created, proceed to turn off your computer and hold the “Alt” or “Options” Key. Select the Sierra installer and proceed with the installation (I format the HDD partition to make a clean install on it)



Note: You might need to do this on another computer. Just buy one of those cheap usb to sata connectors and use it to connect it to another Mac so you don’t risk having your installation failed because of your machine.



Step 1) Prepare a Bootable USB pendrive with a non GUI Linux (Credits to AppleMacFinder)



1.1) Download ArchLinux ISO

You need a working computer for that and a spare CD/DVD/USB drive. Download the latest Arch Linux ISO image from this page - https://www.archlinux.org/download/ , at the time of writing it is archlinux-2017.03.01-dual.iso . Then you could either simply burn this ISO to CD/DVD (which later could be either inserted to MBP's SuperDrive or External DVD Drive connected to MBP by two USB cables) or create a bootable USB: use the great detailed instructions from this page, https://wiki.archlinux.org/index.php/USB_flash_installation_media



1.2) Creating the bootable USB with the .iso:

In macOS

First, you need to identify the USB device. Open /Applications/Utilities/Terminal and list all storage devices with the command:

*) diskutil list


Your USB device will appear as something like /dev/disk2 (external, physical). Verify that this is the device you want to erase by checking its name and size and then use its identifier for the commands below instead of /dev/diskX.

A USB device is normally auto-mounted in macOS, and you have to unmount (not eject) it before block-writing to it with dd. In Terminal, do:

*) diskutil unmountDisk /dev/diskX


Now copy the ISO image file to the device. The dd command is similar to its Linux counterpart, but notice the 'r' before 'disk' for raw mode which makes the transfer much faster:

*) sudo dd if=path/to/arch.iso of=/dev/rdiskX bs=1m

After completion, macOS may complain that "The disk you inserted was not readable by this computer". Select 'Ignore'. The USB device will be bootable.


Step 2) Boot to Linux (Credits to AppleMacFinder):

2.1) Boot to it: insert this CD/DVD/USB to Macbook Pro, hold Option key while booting, choose "EFI boot" (that is your bootable installation media), press "e" key to edit the GRUB options of the Arch Linux archiso x86_64 UEFI CD menu entry while it is selected at the main screen, add nomodeset to the end of this line and press Enter. If everything is done correctly, you will find yourself at the Linux console! (It takes some time so be patient and wait for the prompt)


2.2) Edit EFI vars: looks like efivarfs filesystem is mounted by default! So you can already cd /sys/firmware/efi/efivars and ls to explore this directory and see if there is a "gpu-power-prefs-..." variable (where ... is UUID of this variable).


2.2-Case 1:

If there is such a variable, its better to remove it with rm.

*) rm gpu-power-prefs-…


In my case the efivarfs has been mounted by default with read/write permissions, but if you are getting the "operation not permitted" message while attempting to rm, it means that in your case efivarfs has been mounted as read-only and you need to remount it with read-write permissions and try again (credits to totoe_84 for this valuable addition) (Try this and then try to remove it):

*) cd /

*) umount /sys/firmware/efi/efivars/

*) mount -t efivarfs rw /sys/firmware/efi/efivars/

*) cd /sys/firmware/efi/efivars/

*) rm gpu-power-prefs-…


If this also fails (If you still can’t erase the file) use chattr command to disable file immutability and then erase the file:

*) chattr -i "/sys/firmware/efi/efivars/gpu-power-prefs-…”

*) cd /sys/firmware/efi/efivars/

*) rm gpu-power-prefs-…


2.2-Case 2:

The file gpu-power-prefs-… doesn’t exist well then you don’t have to delete it hahaha. (I repaired 2 17 inch models and 1 didn’t have it, so it’s fine)


2.3) Create a new gpu-power-prefs-… file (Original credit mentioned above, https://github.com/0xbb/gpu-switch/blob/master/gpu-switch, Credits to AppleMacFinder):

*) printf "\x07\x00\x00\x00\x01\x00\x00\x00" > /sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9


2.4) Add immutability to the gpu-power-prefs-… file (Credits to AppleMacFinder):

This chattr command is supposed to lock a file to make it accessible only by "superuser" - and so that, while booting, your EFI will have no chance to screw up your gpu-power-prefs-... variable under any circumstances


*) chattr +i "/sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9"


2.5) Unmount efivars and reboot (Credits to AppleMacFinder):

Could not unmount efivars if you are inside this directory, so change to the root directory

*) cd /

*) umount /sys/firmware/efi/efivars/

Guarantees that your EFI variables are flushed to efivarfs filesystem, please unmount it safely before rebooting)

*) reboot


3) Eliminate AMD Kexts (Credits to newfield),
Note: You might need to do this every time you do an OS updates, since each update normally writes the AMD Kexts again.


(His words and this also happened to me!: After disabling the dGPU using Arch, normal boot would hang halfway. Although safe boot would work. I wound up having to remove all the AMD kext files in the Terminal in Recovery Console)


Trying to remove them in Single User just gave me sandbox errors. (Summary -> Don’t do it in Single User Mode the one that you boot with Cmd + S)


3.1) So what you have to do is:

If you have FileVault Unlock it first:

Unlock first.

Then Boot into Recovery (“cmd + r”, it will boot without failing, if it fails then repeat step 2 and then after that boot directly into recovery with command + R, I had to do this once because the dGPU got active again after booting into the os with AMD kexts)

*) Boot into recovery mode (Command + r)

*) Start Terminal

*) diskutil cs list (find UUID for drive)

*) diskutil coreStorage unlockVolume UUID

*) cd /Volumes/Macintosh\ HD

*) mkdir AMD_Kexts

*) mv System/Library/Extensions/AMD*.* AMD_Kexts/

*) reboot



(If you only have one storage with 1 partition just use "cd /Volumes/Macintosh\ HD" and the remaining commands after starting the terminal)


Extra STEP), if your PC is now working! Download “steveschow” branch of gfxCardStatus (gfxCardStatus v2.4.3i) or just download the app directly from:

URLS:

https://github.com/steveschow/gfxCardStatus/releases

https://github.com/steveschow/gfxCardStatus

With this application you can even prove that the dedicated GPU can't get activated. Even if you try to change the selected GPU to the dedicated one, it just won't change.


—————

The End!

AND VOILA!!! You have a working 17 inch MacBook Pro. As I said I tested this with an early 2011 and late 2011 17 inch MacBook Pro’s and both are now running (Before they were both dead)


Big thanks to AppleMacFinder, to the makers and contributors of this thread, to gfxCardStatus maker and forkers :D (steveschow) and to switch-gpu makers I can’t thank you guys enough as I am so happy to bring both of this incredible machines back to life. With this post I am not trying to take any credit, but as I had 2 machines I run into different issues with both, which could be helpful to others, thats why I was inclined to make “my own” guide and share it with you.


I just created an account here to share this, Hope it helps more people!
[doublepost=1497826668][/doublepost]Just signed up to the forum to say thanks to FGuarini and OP.
Following FGuarini's clear guide, I've brought two 2011 MBP (one 15'' and one 17'') in my home back to life in a couple of hours.
 
  • Like
Reactions: AppleMacFinder
My 2011 17" MBP has been less useful than a paperweight for more than two years. The extended service for repairing the discrete card fault is not available in my country. It costs less to buy a better computer than to travel for the repairs to the US. Now, my "best" MBP is smiling back at me, albeit with only one eye. May God bless all the contributors to this thread. Just like so many others, it took me so many pages and trials before getting here. I hope this comment will reduce the pain for others still searching for a solution.
 
  • Like
Reactions: AppleMacFinder
This fix got me to the stage of being able to boot up in safe mode with integrated GPU. Like others with Sierra installed normal booting still ends in hanging grey screen trying to go to login page.

Unfortunately trying to move the AMD kexts ends in 'system file is read only'. Is there a way to still move them. Or is it possible to go back to rw status booting up in Archlinux (EFI boot)?

Alternatively: is there another way to pass the grey screen?

In safe modus I can do 90% of what I use my MBP for, but no video and sound. And Spotlight does't work either (except as a dictionary).

Adding a couple of thoughts to my original post. Working in safe mode is not ideal. For video and sound I have to go back to my old white MacBook, which is very slow. So I would really like to get my MBP back in normal working order.

I suppose the terminal in Recovery mode would give the same result ('read-only file system') as single user mode when trying to move AMD kexts out of the way? Haven't tried it yet, but I don't think it is of any use.
Would it be possible to re-install Mac OS on my MBP (maybe clean install) under the given circumstances? Of course than I would have te do the EFI fix all over again, but if the system is read and write again that would be no major problem. Anyone have any thoughts on this?
 
  • Like
Reactions: AppleMacFinder
I'm getting the same "Operation not permitted" error. I can't boot into recovery mode as instructed in the link you posted. Is there an alternative way?

Edit : Never mind, for those of you who also get stuck on a grey screen booting into recovery mode, there is an undocumented single user recovery mode which you can access with CMD + R + S.

Unfortunately now I am being hit with a "Read-only file system" message.

Edit: Never mind again, I didn't mount the drive properly. It's working like a charm. Thanks a million AppleMacFinder!

Thank you for this tip (Command + R + S). Is much faster than having to load the graphical environment Command + R.
 
  • Like
Reactions: AppleMacFinder
Adding a couple of thoughts to my original post. Working in safe mode is not ideal. For video and sound I have to go back to my old white MacBook, which is very slow. So I would really like to get my MBP back in normal working order.

I suppose the terminal in Recovery mode would give the same result ('read-only file system') as single user mode when trying to move AMD kexts out of the way? Haven't tried it yet, but I don't think it is of any use.
Would it be possible to re-install Mac OS on my MBP (maybe clean install) under the given circumstances? Of course than I would have te do the EFI fix all over again, but if the system is read and write again that would be no major problem. Anyone have any thoughts on this?

SIP - System Integrity Protection is a security technology in OS X El Capitan and later.

Mac OS Sierra uses gfxcardstatus v2.4.3i (Steve Schow).

https://github.com/steveschow/gfxCardStatus/releases/tag/v2.4.3i


1 - Enter Boot Safe Mode (press SHIFT key on startup)

2 - Open Terminal (Finder -> Applications -> Utilities -> Terminal (copy and paste) :

sudo nvram fa4ce28d-b62f-4c99-9cc3-6815686e30f9:gpu-power-prefs=%01%00%00%00


3 - Reboot the system:

sudo shutdown -r now


4 - Enter Recovery Mode (text mode)

Command + R + S


5 - Disable SIP (SIP lock System folder -> no move kexts to another folder). SIP (csrutil) only enable / disable on Recovery Mode.

csrutil disable


6 - Restart the system

reboot


7 - Enter Single User mode (Command + S)

7.1 - Verify file system:

/sbin/fsck -fy

7.2 Mount system as Read/Write (Do not forget the slash at the end of the command). The slash is root system.

/sbin/mount -uw /


8 - Enter partition Mac OS System (If you have not changed the partition name then it is probably Macintosh HD).
Use the TAB key to autocomplete the partition name.

cd /Volumes/YourPartitionSystem

cd /Volumes/Macintosh\ HD/


9 - Create directory/foder DisableExtensions

mkdir DisableExtensions


10 - Move Kexts AMD and ATI to folder DisableExtensions

sudo mv -v /System/Library/Extensions/AMD*.* /DisableExtensions

sudo mv -v /System/Library/Extensions/ATI*.* /DisableExtensions


11 - Restart the system

reboot


12 - Before enabling SIP again, try the normal boot without pressing any key.

The Mac OS will rebuild the kernel cache and restart.


13 - Before enabling SIP again, try the normal boot without pressing any key.

See if the system starts normally.

See if the card in use is Intel with gfxcardstatus or System Report.

14 - Try switching to the AMD card with gfxcardstatus.
If all is right, it will not be possible to switch to the AMD chip. It gets lock on the Intel video chip.

15 - Enable SIP again (restart the system)


16 - Enter Recovery Mode (text mode)

Command + R + S


17 - Enable SIP again

csrutil enable


18 - Restart the system

reboot
[doublepost=1498087916][/doublepost]If the Mac OS is slow and or blinking then you are using discrete AMD.
Check with gfxcardstatus to see which graphics chip is being used.

Or, About this Mac -> System Report -> Graphics Displays -> Which of the graphics cards has the "Display Type: LCD".

If the AMD chip is "Display Type: LCD", then the chip being used is AMD.

You removed the AMD and ATI Kexts but the gpu-power-prefs was not enabled for the Intel graphics chip.


1 - Open Terminal (Finder -> Applications -> Utilities -> Terminal (copy and paste) :

sudo nvram fa4ce28d-b62f-4c99-9cc3-6815686e30f9:gpu-power-prefs=%01%00%00%00


2 - Restart the system

sudo shutdown -r now
 
Last edited:
  • Like
Reactions: AppleMacFinder
First of all thanks to everyone for this great hack!! Another late 2011 15" Macbook Pro is now up and running! :)

I have only 2 small inconveniences right now:
1) the Mac is running about 20C hotter than before, it looks like thermal management of the discrete GPU is gone. Not sure if it is due to the lack of AMD Kexts or the settings in gpu-power-prefs.. any ideas for that?
2) I cannot drive an external monitor/projector anymore due to the fact that the displayport seems to be directly wired to the (now bypassed) discrete gpu. Anyone with experience with those small usb external videocards? Do they work properly?

Thanks again!
 
Thank you nsgr and of course AppleMacFinder. Nsgr, you gave me some confidence that I could still succeed and now I have my MBP running normally again with only the integrated card and so far it runs smoothly. I haven't tried every possible task yet, but for now I'm happy.
However, in the process I encountered two weird things.

First when I entered the command cd /Volumes/MacBook\ HD/ (see picture): 'No such file or directory'. And I used TAB for autocompletion, so this must be the right name for the volume. Why?

Second. Because of the first problem I went back to the first post and tried to remove the AMD kexts according to the method AppleMacFinder described and all went well until the unmounting (also in the picture): 'resource busy - try diskutil unmount'. As you can see I tried that twice, but no success. So I just rebooted expecting it would fail, but after 'killing all processes' (I suppose this is normal) the MBP first rebooted itself again spontaneously and the second time booted normally.

Maybe this information will help others that are trying to remove the kexts. It looks as if my MBP is also a bit hotter, like iteration mentions above. But well, I can live with that.
AMD kexts - 1.jpg
 
  • Like
Reactions: AppleMacFinder
First of all thanks to everyone for this great hack!! Another late 2011 15" Macbook Pro is now up and running! :)

I have only 2 small inconveniences right now:
1) the Mac is running about 20C hotter than before, it looks like thermal management of the discrete GPU is gone. Not sure if it is due to the lack of AMD Kexts or the settings in gpu-power-prefs.. any ideas for that?
2) I cannot drive an external monitor/projector anymore due to the fact that the displayport seems to be directly wired to the (now bypassed) discrete gpu. Anyone with experience with those small usb external videocards? Do they work properly?

Thanks again!

Same problem for me. 15C or 20C more hot. (test Mac OS Lion 10.7.8, El Capitan 10.11.6, Sierra 10.12.3 and Sierra 10.12.5)

App Istat Menus -> Sensors -> CPU Die Analog ->50 degrees Celsius (Mac OS Lion, El Capitan, Sierra -> idle.

I'm investigating these settings:

/System/Library/Extensions/AppleGraphicsControl.kext/Contents/PlugIns/

AppleGraphicsDeviceControl.kext

AppleGraphicsDevicePolicy.kext

AppleMGPUPowerControl.kext

AppleMuxControl.kext

ApplePolicyControl.kext

/System/Library/Extensions/AppleGraphicsControl.kext/Contents/PlugIns/AppleMuxControl.kext/Contents/
Info.plist

/System/Library/Extensions/AppleGraphicsPowerManagement.kext/Contents/Info.plist

Example:

/System/Library/Extensions/AppleGraphicsControl.kext/Contents/PlugIns/AppleGraphicsDevicePolicy.kext/Contents/Info.plist

<key>GFX0</key>
<dict>
<key>EDID</key>
<dict>
<key>index</key>
<integer>0</integer>
</dict>
<key>FeatureControl</key>
<integer>12</integer>
<key>unload</key>
<false/>
</dict>
<key>IGPU</key>
<dict>
<key>unload</key>
<true/>
</dict>

--------------------
GFX0 should be the AMD video card.
IGPU the Intel integrated video card.

In the boot verbose ( sudo nvram boot-args="- v" ) the following AGC message appears:

IOGraphics flags 0x43
AGC: booted to IG, policy disable!!
AGC: 3.14.47, HW version=1.9.23, flags:1, features: 20600, policy:30

I think IG stands for Integrated Graphics.

1.9.23 -> About this Mac -> System Report -> Graphics/Displays -> AMD or Intel -> gMux version: 1.9.23

Since Mac OS does not load the AMD / ATI kext, then some configuration is not loaded.

I think this setting that is not being loaded is causing the temperature to rise.

I put my hand on the left side of the Macbook Pro 2011 (next to the Magsafe connector) and it gets hotter when the AMD / ATI kext is not loaded.

I tried ( sudo nvram gpu-policy=%01 ) but I think it did not work.

I'm looking for the Apple Technician Guide for Macbook Pro 2011. Who knows has some information on it.

I only found it for Macbook Pro 2010.


http://tim.id.au/laptops/apple/macbook/mbp15_mid2010.pdf

http://tim.id.au/laptops/apple/macbook/

[doublepost=1498205806][/doublepost]
Thank you nsgr and of course AppleMacFinder. Nsgr, you gave me some confidence that I could still succeed and now I have my MBP running normally again with only the integrated card and so far it runs smoothly. I haven't tried every possible task yet, but for now I'm happy.
However, in the process I encountered two weird things.

First when I entered the command cd /Volumes/MacBook\ HD/ (see picture): 'No such file or directory'. And I used TAB for autocompletion, so this must be the right name for the volume. Why?

Second. Because of the first problem I went back to the first post and tried to remove the AMD kexts according to the method AppleMacFinder described and all went well until the unmounting (also in the picture): 'resource busy - try diskutil unmount'. As you can see I tried that twice, but no success. So I just rebooted expecting it would fail, but after 'killing all processes' (I suppose this is normal) the MBP first rebooted itself again spontaneously and the second time booted normally.

Maybe this information will help others that are trying to remove the kexts. It looks as if my MBP is also a bit hotter, like iteration mentions above. But well, I can live with that.
View attachment 705216

1 - Photo -> The volume Macbook appears to be OK.

Weird. Why did not Macbook HD appear?

I prefer to create a system partition without having space in the name to avoid problems.

Example name system partition:
MacElCapitan
MacSierra

To know I would have to see your listing of directories/folder inside Volumes (ls command).

1.1 - Boot Single User (Command + S)

1.2 - /sbin/fsck -fy

1.3 - /sbin/mount -uw /

1.4 - ls -la /Volumes/


2 - sudo umount / -> resource is busy

You are inside the root directory "/".

A Unix system can not unmount a root "/" with the system running. It would be like taking apart an airplane with you flying. The plane is the "/".

Busy means you're on this partition.

You do not need to unmount the "/" partition on Boot Single User.

You only need to restart the system with the reboot command. Then Mac OS will unmount the root partition "/" correctly.

In the case of ArchLinux, you only unmount the efivars if you are not inside efivars.

cd command enter or leave a directory / folder.

cd /sys means enter sys directory.

cd .. (dot dot) leave sys directory if you are inside sys directory.

cd / means you leave all directories (levels). But it remains under the root directory called " / " (first level).

root " / " Is different from the /root directory. The system administrator is also called root. But it has different functions.

/root Is the personal directory of the system administrator.

/. . . . . . . . . . . . . . . . . . . . . . . . . (first level)
. . . /root . . . . . . . . . . . . . . . . . . . (2 level)
. . . /sys . . . . . . . . . . . . . . . . . . . (2 level)
. . . . . . . /firmware . . . . . . . . . . . (3 level)
. . . . . . . . . . . . . . . /efi . . . . . . . . (4 level)
. . . . . . . . . . . . . . . . . . . . /efivars (5 level)

https://davidcraddock.files.wordpress.com/2010/03/1348573631.png

To unmount the efivars directory, you must leave from this directory if you are inside it (cd .. or cd / ).

That is why it is recommended not to enter into the efivars directory.

You stay in the root directory "/" (first level) and use the full path.

Example full path staying at the first level " / "

chattr +i "/sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9"
 
Last edited:
  • Like
Reactions: AppleMacFinder
Thanks for the extensive explanation. According to the first post (AppleMacFinder) unmounting would secure the settings. Rebooting without unmounting first worked, so no problem.

I already did the fix for the evifars/gpu-power-prefs before removing the AMD kexts, so I don't need to go there anymore. But interesting to learn a little more about how things work.

The partition name not showing up is really strange. It is MacBook without a space (BTW I bought the MBP refurbished and the name was already MacBook), so that shouldn't be a problem. Anyway, I managed to get it up and running, everything is back to normal. It even seems a little faster than before.

If there is a solution for the temperature that would be nice, I suppose the MBP will last a little longer when it stays cool.

I found this technician guide. Hope it helps.

Apple Technician Guide MacBook Pro 17 inch, 2010/2011 - Westside ...
 
  • Like
Reactions: AppleMacFinder
Please try FGuarini's instruction here - https://forums.macrumors.com/thread...efi-variable-fix.2037591/page-5#post-24511780 These instructions are slightly different and their difference helps to some people who didn't have a 100% success with my version of them

Check FGuarini's instruction (link given above), it is slightly different and may help you

Uninstall VLC with the removal of its' plists (settings files), then install it again. There could be some setting in plist that is still trying to switch to discrete. Alternatively, maybe this fix haven't been completed to 100% and you need to repeat the last parts of instruction


Check FGuarini's instruction (link given above), it is slightly different and may help you.


Please tell us the results with USB to VGA converter, it will be great to know if its' possible


I just received my USB to VGA converter. It works, although not perfect. A little lagging noticed when manipulating windows (opening, closing, switching, etc). I've played youtube videos in HD, with screen resolution 1920*1080, and the lagging is barely noticeable. Also the taskbar is showing up in the wrong color and resolution. But other than that, no complains. Mine is 2011 MBP with USB2.0, USB3.0 might be better.

Great to have a functioning MBP connected to an external monitor again! Thanks a lot for your help @AppleMacFinder!
 
Last edited:
  • Like
Reactions: AppleMacFinder
Hi and THANK YOU after reading your post and going through the comments I managed to restart my MBP properly. The only problem I have now is that if I turn it off or reboot it, the but will happen again. Is there anything I can do in Mac OS to prevent it from reverting everything I did in linux' console? Anyway, Hope that's clear and hope you'll be able to help. Thanks a lot, again!
Jude
 
  • Like
Reactions: AppleMacFinder
If you don't have time to read my story (which also describes some interesting technical approaches) just scroll down this thread until a "100% WORKING SOLUTION" text

Discrete AMD GPU of my 2011 MacBook Pro 8,2 has finally failed because of the reasons mentioned here ( http://logicboardmac.blogspot.ru/ ) and there ( https://www.macrumors.com/2015/02/19/2011-macbook-pro-repair-program-apple/ ) . It has been working perfectly for 6 years under quite a high load, even tried SETI@HOME mining at background! So I was confident that my MBP is not affected by bad solder / bad soldering quality and didn't want to bring it to Apple for a free repair program - partially because couldn't find the time to pause my important software projects, partially because I was afraid that Apple might give me a less reliable logic board or refuse a free repair because of the several unrelated repairs that I did manually by myself earlier to save money: changed thermal paste a few times, replaced the internal battery 2 times, replaced a keyboard with broken buttons, etc. But it finally broke down last week: laptop's screen image became distorted, it refused to boot OS X (always freezing half-way), and - Apple free repair program has already ended! I know there are affordable solutions like $50 BGA resoldering at unofficial local repair shop and that its possible to get a new replacement HD 6750M chip from AliExpress for $35 or cheaper ( http://www.aliexpress.com/item/DC-2...0028-216-0810028-BGA-Chipset/32764872143.html or https://www.aliexpress.com/item/DC-2015-New-216-0810001-216-0810001-Graphic-Chipset/32718112928.html , because don't know if this is true - https://www.rossmanngroup.com/board...0604-replace-216-0810005-gpu-with-216-0810028 ) to guarantee a successful repair, so the total price of repair would be either $50 or $50+$35=$85 - less than $100 in any case. But I don't like investing money to the old computers, so I have thought - what if there is some hack to force MBP to use integrated graphics ALL THE TIME, even while booting ? And then started to explore the possible solutions...

===

First of all, it is possible to successfully boot a MBP to OS X while still using the failed GPU, after you remove the AMD drivers by booting in command line mode (CMD+S) and entering these commands:
1) fsck -fy (to check a disk)
2) mount -uw / (mount a root filesystem with read/write permissions)
3) sudo mkdir /AMD_Kexts/ (make a directory to store the AMD drivers in case you'll need them in future)
4) sudo mv /System/Library/Extensions/AMD*.* /AMD_Kexts/ (move the AMD drivers)
5) sudo rm -rf /System/Library/Caches/com.apple.kext.caches/ (remove the AMD drivers cache)
6) sudo mkdir /System/Library/Caches/com.apple.kext.caches/ (just in case OS X will be dumb and will not recreate this directory, I am creating it for OS X)
7) sudo touch /System/Library/Extensions/ (to update the timestamps so that new driver caches - without AMD drivers - will be definitely rebuilt)
8) sudo umount / (umount a partition to guarantee that your changes are flushed to it)
9) sudo reboot

The degree of your inconvenience while doing these steps - strongly depends on how heavily a screen's image is distorted in your case. In my case it was even more difficult because the OS X partition became a "read-only" partition (because of too many emergency shutdowns I did while desperately trying to boot OS X with a failed GPU) so I had to remove a hard drive from MacBook Pro and (using a USB to SATA 2.5" adapter taken from my portable HDD) attached it to a computer with Linux, then followed these instructions:

https://superuser.com/questions/961401/mounting-hfs-partition-on-arch-linux (1st answer) - carefully executed a number of commands, calculated a sizelimit for my parition layout, and finally ran sudo mount -t hfsplus -o force,rw,sizelimit=YOURNUMBER /dev/sdb2 /mnt to mount this HFS+ partition to /mnt directory in read-write mode. Then I performed these "1)-7)" steps you see above, and also repaired a filesystem by running sudo fsck.hfsplus -f /dev/sdb2 before unmounting a partition with sudo umount /mnt and putting a hard drive back to MBP...

===

This gave me a MBP which could boot to OS X although STILL using a broken AMD GPU: so it screen's image is very distorted (could browse the Internet but quite inconvenient to read a text), Launchpad is super laggy, and you can't switch to Integrated GPU using gfxCardStatus because: without AMD drivers (which we had to remove to successfully boot to OS X) Macbook Pro thinks its' internal screen is External Display and gfxCardStatus tells it is impossible to switch because External Display is using AMD GPU. Somewhere I found a suggestion that it is possible to rebuild a gfxCardStatus from the source code - https://github.com/codykrieger/gfxCardStatus - with removed or commented out 156-166 lines in the ./gfxCardStatus/Classes/GSProcess.m to make it to ignore the external display:

// find out if an external monitor is forcing the discrete gpu on
CGDirectDisplayID displays[8];
CGDisplayCount displayCount = 0;
if (CGGetOnlineDisplayList(8, displays, &displayCount) == noErr) {
for (int i = 0; i < displayCount; i++) {
if ( ! CGDisplayIsBuiltin(displays))
[list addObject:[NSDictionary dictionaryWithObjectsAndKeys:
Str(@"External Display"), kTaskItemName,
@"", kTaskItemPID, nil]];
}
}


So I rebuilt a gfxCardStatus using the instructions from the last reply of this issue -
https://github.com/codykrieger/gfxCardStatus/issues/229
(also had to download a MacOSX10.11.sdk from here - https://github.com/phracker/MacOSX-SDKs/releases - unpack and copy it to XCode's /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk - because of the Apple's stupidity the latest XCode for El Capitan does not include SDK for El Capitan!) However, it still didn't work - gfxCardStatus only pretended that it has switched to Integrated GPU, while in reality OS X did not let it switch! Even after I edited ./gfxCardStatus/Classes/GSGPU.m file to enable the mysterious "Nuke it from orbit switching" option, it still couldn't switch...

===

Then I discovered this interesting repository - https://github.com/0xbb/gpu-switch - which is partially similar by its' source code to gfxCardStatus but also has the "Login Hooks" (install_hooks.sh) to "automate the switching process for login/logout". Sadly it didn't work for me... However, there is a very interesting gpu-switch text file right at the root of this repository, which describes the EFI variables!

https://github.com/0xbb/gpu-switch/blob/master/gpu-switch

After studying it and also reading this issue's comments - https://github.com/0xbb/gpu-switch/issues/11 - I became confident to try this solution, but found out that my MacBook Pro 2011 8,2 with OS X El Capitan 10.11.6 is in a VERY problematic situation:

1) rEFInd is not installed, and to install it - must disable SIP protection. But I cannot boot to Recovery mode (Command+Option+R) or to OS X Installation DVD/USB (hold Option), (to disable SIP), because they freeze while booting! - although I removed AMD kexts from my system, of course these recovery tools are using AMD kexts integrated to their design. Also cannot use Rootfool hack ( https://github.com/gdbinit/rootfool ) to disable SIP during runtime, because it works only at OS X version older than 10.11.4

2) Tried overheating my Macbook Pro on purpose (forcing CPU usage to 100% and putting it to a tightly closed bag) to force it to shutdown from overheating and then quickly reboot so that Integrated graphics will be enabled during the boot time - making it possible to boot to Recovery. But because of the wonderful high end thermal paste I have applied not so long ago - cannot overheat it even after waiting for a long time! At this point I thought that could either: a) remove AMD kexts from Installation media, or b) to connect MBP's hard drive to a Linux machine again and run a bunch of chmods to remove the SIP flags from the directories mentioned here ( http://apple.stackexchange.com/questions/193368/what-is-the-rootless-feature-in-el-capitan-really ) which could potentially make a system unbootable, or c) to try installing rEFInd to HFS+ partition directly from a Linux machine with root rights because it will bypass SIP --- but have not explored these options, although some of them might have worked...

3) Wanted to boot a Linux LiveCD to edit the EFI variables from there, but no matter what I did: tried booting straight without GRUB option modifications, tried editing GRUB boot options (with "e" key) to add nomodeset / remove quiet splash / or both in every combination , or like suggested in this article ( https://wiki.archlinux.org/index.php/MacBookPro8,1/8,2/8,3_(2011) ) also add i915.modeset=0 radeon.modeset=0 or radeon.modeset=0 i915.modeset=1 i915.lvds_channel_mode=2 ; and then pressed Fn+F10 or Shift+Ctrl+Fn+F10 to boot with these options: but the Linux boot process always failed at different boot stages, no matter what popular user-friendly Linux distribution or what version of it I am trying: tried many releases of Ubuntu / Lubuntu / Fedora , even the old "AMD64 Mac" and "Alternate AMD64 Mac" images, but they always failed - either at the very beginning of boot process (black screen, or a black screen with a blinking or stuck _ character at the left upper corner) or failed at the very end of it - right before it is supposed to show a graphical desktop environment...

Later, totoe_84 wrote that he was able to boot Ubuntu in graphical mode using the following setup for GRUB:
  • To disable the AMD graphics card I added the following lines after set gfxpayload=keep
outb 0x728 1
outb 0x710 2
outb 0x740 2
outb 0x750 0
  • Next I added the following after quiet splash
    i915.lvds_channel_mode=2 i915.modeset=1 i915.lvds_use_ssc=0
(based on https://ubuntuforums.org/showthread.php?t=2157775 )

===

Then I remembered that there are not-mainstream Linux distributions for advanced users, which have a LiveCD without any graphical interface: you are dropped to a pure console and you are supposed to install the system along with only those graphical interfaces and software packages / groups of packages which you explicitly select. For example: Arch Linux (https://www.archlinux.org/) and Gentoo Linux (https://gentoo.org/) . Because their LiveCD does not have a graphical interface, they could be booted without a problem to a pure Linux console and there you could edit the EFI variables ! So here is a...

===
=== 100% WORKING SOLUTION
===
=== Force your MBP to ALWAYS use Intel integrated GPU (EFI variable fix)
===
=== to make it great again ! ;)
===


1) Create the Arch Linux LiveCD/LiveUSB :

You need a working computer for that and a spare CD/DVD/USB drive. Download the latest Arch Linux ISO image from this page - https://www.archlinux.org/download/ , at the time of writing it is archlinux-2017.03.01-dual.iso . Then you could either simply burn this ISO to CD/DVD (which later could be either inserted to MBP's SuperDrive or External DVD Drive connected to MBP by two USB cables) or create a bootable USB: use the great detailed instructions from this page, https://wiki.archlinux.org/index.php/USB_flash_installation_media

2) Boot to it: insert this CD/DVD/USB to Macbook Pro, hold Option key while booting, choose "EFI boot" (that is your bootable installation media), press "e" key to edit the GRUB options of the Arch Linux archiso x86_64 UEFI CD menu entry while it is selected at the main screen, add nomodeset to the end of this line and press Enter. If everything is done correctly, you will find yourself at the Linux console!

3) Edit EFI vars: looks like efivarfs filesystem is mounted by default! So you can already cd /sys/firmware/efi/efivars and ls to explore this directory and see if there is a "gpu-power-prefs-..." variable (where ... is UUID of this variable). If there is such a variable, its better to remove it with rm. In my case the efivarfs has been mounted by default with read/write permissions, but if you are getting the "operation not permitted" message while attempting to rm, it means that in your case efivarfs has been mounted as read-only and you need to remount it with read-write permissions and try again (credits to totoe_84 for this valuable addition) :
*) cd /
*) umount /sys/firmware/efi/efivars/
*) mount -t efivarfs rw /sys/firmware/efi/efivars/
*) cd /sys/firmware/efi/efivars/

If your screen is so distorted that it is difficult to see the letters, just start typing the rm gpu-power-pre and then press TAB key for autocompletion. In my case there were not such a EFI variable, only "gpu-active-..." and maybe somehow related "gfx-saved-config-restore-status-..." . Then I looked again at that gpu-switch text file (mentioned above, https://github.com/0xbb/gpu-switch/blob/master/gpu-switch),
and entered THESE COMMANDS:

*) chattr -i "/sys/firmware/efi/efivars/" <----- skip this command

Actually a gpu-switch script had "${sysfs_efi_vars}/${efi_gpu}" but I didnt have a "gpu-power-prefs-..." variable - so, partially by mistake, I didn't add that efi_gpu suffix and entered this incomplete path accidentally

*)
printf "\x07\x00\x00\x00\x01\x00\x00\x00" > /sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9

Did not have a EFI "gpu-power-prefs-" variable so I thought that it will be OK to create a new one with a random UUID - in this case, taken directly from a gpu-switch script

*) chattr +i "/sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9"

http://www.tecmint.com/chattr-command-examples/ - chattr (Change Attribute) is a command line Linux utility that is used to set/unset certain attributes to a file in Linux system to secure accidental deletion or modification of important files and folders, even though you are logged in as a root user.
...
Syntax of chattr ---> chattr [operator] [flags] [filename]
...
A file is set with ‘i‘ attribute (+i as you see in this command) ---> cannot be modified (immutable). Means no renaming, no symbolic link creation, no execution, no writable, only superuser can unset the attribute.
...
Operator
  1. + : Adds the attribute to the existing attribute of the files.
  2. : Removes the attribute to the existing attribute of the files.
  3. = : Keep the existing attributes that the files have.
This chattr command is supposed to lock a file to make it accessible only by "superuser" - and so that, while booting, your EFI will have no chance to screw up your gpu-power-prefs-... variable under any circumstances

*) cd /

Could not unmount efivars if you are inside this directory, so change to the root directory

*) umount /sys/firmware/efi/efivars/

Guarantees that your EFI variables are flushed to efivarfs filesystem, please unmount it safely before rebooting)

*) reboot

===> IF YOU DID EVERYTHING CORRECTLY, MOST LIKELY THAT YOUR MACBOOK PRO IS NOW USING INTEGRATED GRAPHICS WHILE BOOTING, AFTER BOOTING, AND IS WORKING GREAT AGAIN ! ;)

In the future maybe you could need to re-apply this solution if you would have to reset your PRAM / NVRAM / SMC because of some other problems, so remember this solution somewhere... Funny thing: now you can't switch to Discrete GPU even using gfxCardStatus, it is forever stuck at Integrated


I spent two working days to discover this solution, and really hope that it will work flawlessly for every MBP owner with a broken discrete GPU. Good luck!
[doublepost=1498471708][/doublepost]Hi,

Thanks for the post on this topic. I have had moderate success with this solution.

I have a Macbook Pro Nov, 2011 model with a failed gpu. I have modified the efivars as you describe above, and I am able to reboot the system and all works perfectly.

However, after a few hours the system randomly shuts down and I have to go through the whole process again. I have done this a half dozen times now, and each time the system works for a few hours or even a day or two and then randomly reverts back to the Apple gpu.

I noticed that within the efivarfs directory, there is also a variable called gpu-policy-xxx which has a UUID that is different from the UUID of the gpu-prefs-xxx. There is also an gpu-active-xxx which has the same UUID as the gpu-prefs-xxx.

I couldnt find any documentation on the gpu-policy variable, but might this variable be causing the system to revert back to the Apple gpu?

Note that I am not running any games or heavy graphics that might overload the graphics card. I am only using basic desktop applications. The system will even shut down randomly over night while I am not using it and revert back to the failed Apple gpu.

Any ideas on what would be causing the system to randomly revert back to the Apple gpu?
 
Created an account just to thank you for this!!!


Fix for 17 inch dGPU switch issue

(Tested successfully in both “early” and “late” 2011 17 inch MacBook Pro)



This guide is based on the experience of many users (including me) while trying to fix the very well known issue with AMD dGPU on 17’’ MacBook Pro from 2011 (both early and late):



Step 0) As a starting point I made a clean installation of Sierra (Version 10.12.4) — This is just a step for establishing a common middle ground and is not really needed….

0.1) To do this just download the installer from the App Store and then use “DiskMaker X” to create a bootable installation.

0.2) After the bootable image is created, proceed to turn off your computer and hold the “Alt” or “Options” Key. Select the Sierra installer and proceed with the installation (I format the HDD partition to make a clean install on it)



Note: You might need to do this on another computer. Just buy one of those cheap usb to sata connectors and use it to connect it to another Mac so you don’t risk having your installation failed because of your machine.



Step 1) Prepare a Bootable USB pendrive with a non GUI Linux (Credits to AppleMacFinder)



1.1) Download ArchLinux ISO

You need a working computer for that and a spare CD/DVD/USB drive. Download the latest Arch Linux ISO image from this page - https://www.archlinux.org/download/ , at the time of writing it is archlinux-2017.03.01-dual.iso . Then you could either simply burn this ISO to CD/DVD (which later could be either inserted to MBP's SuperDrive or External DVD Drive connected to MBP by two USB cables) or create a bootable USB: use the great detailed instructions from this page, https://wiki.archlinux.org/index.php/USB_flash_installation_media



1.2) Creating the bootable USB with the .iso:

In macOS

First, you need to identify the USB device. Open /Applications/Utilities/Terminal and list all storage devices with the command:

*) diskutil list


Your USB device will appear as something like /dev/disk2 (external, physical). Verify that this is the device you want to erase by checking its name and size and then use its identifier for the commands below instead of /dev/diskX.

A USB device is normally auto-mounted in macOS, and you have to unmount (not eject) it before block-writing to it with dd. In Terminal, do:

*) diskutil unmountDisk /dev/diskX


Now copy the ISO image file to the device. The dd command is similar to its Linux counterpart, but notice the 'r' before 'disk' for raw mode which makes the transfer much faster:

*) sudo dd if=path/to/arch.iso of=/dev/rdiskX bs=1m

After completion, macOS may complain that "The disk you inserted was not readable by this computer". Select 'Ignore'. The USB device will be bootable.


Step 2) Boot to Linux (Credits to AppleMacFinder):

2.1) Boot to it: insert this CD/DVD/USB to Macbook Pro, hold Option key while booting, choose "EFI boot" (that is your bootable installation media), press "e" key to edit the GRUB options of the Arch Linux archiso x86_64 UEFI CD menu entry while it is selected at the main screen, add nomodeset to the end of this line and press Enter. If everything is done correctly, you will find yourself at the Linux console! (It takes some time so be patient and wait for the prompt)


2.2) Edit EFI vars: looks like efivarfs filesystem is mounted by default! So you can already cd /sys/firmware/efi/efivars and ls to explore this directory and see if there is a "gpu-power-prefs-..." variable (where ... is UUID of this variable).


2.2-Case 1:

If there is such a variable, its better to remove it with rm.

*) rm gpu-power-prefs-…


In my case the efivarfs has been mounted by default with read/write permissions, but if you are getting the "operation not permitted" message while attempting to rm, it means that in your case efivarfs has been mounted as read-only and you need to remount it with read-write permissions and try again (credits to totoe_84 for this valuable addition) (Try this and then try to remove it):

*) cd /

*) umount /sys/firmware/efi/efivars/

*) mount -t efivarfs rw /sys/firmware/efi/efivars/

*) cd /sys/firmware/efi/efivars/

*) rm gpu-power-prefs-…


If this also fails (If you still can’t erase the file) use chattr command to disable file immutability and then erase the file:

*) chattr -i "/sys/firmware/efi/efivars/gpu-power-prefs-…”

*) cd /sys/firmware/efi/efivars/

*) rm gpu-power-prefs-…


2.2-Case 2:

The file gpu-power-prefs-… doesn’t exist well then you don’t have to delete it hahaha. (I repaired 2 17 inch models and 1 didn’t have it, so it’s fine)


2.3) Create a new gpu-power-prefs-… file (Original credit mentioned above, https://github.com/0xbb/gpu-switch/blob/master/gpu-switch, Credits to AppleMacFinder):

*) printf "\x07\x00\x00\x00\x01\x00\x00\x00" > /sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9


2.4) Add immutability to the gpu-power-prefs-… file (Credits to AppleMacFinder):

This chattr command is supposed to lock a file to make it accessible only by "superuser" - and so that, while booting, your EFI will have no chance to screw up your gpu-power-prefs-... variable under any circumstances


*) chattr +i "/sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9"


2.5) Unmount efivars and reboot (Credits to AppleMacFinder):

Could not unmount efivars if you are inside this directory, so change to the root directory

*) cd /

*) umount /sys/firmware/efi/efivars/

Guarantees that your EFI variables are flushed to efivarfs filesystem, please unmount it safely before rebooting)

*) reboot


3) Eliminate AMD Kexts (Credits to newfield),
Note: You might need to do this every time you do an OS updates, since each update normally writes the AMD Kexts again.


(His words and this also happened to me!: After disabling the dGPU using Arch, normal boot would hang halfway. Although safe boot would work. I wound up having to remove all the AMD kext files in the Terminal in Recovery Console)


Trying to remove them in Single User just gave me sandbox errors. (Summary -> Don’t do it in Single User Mode the one that you boot with Cmd + S)


3.1) So what you have to do is:

If you have FileVault Unlock it first:

Unlock first.

Then Boot into Recovery (“cmd + r”, it will boot without failing, if it fails then repeat step 2 and then after that boot directly into recovery with command + R, I had to do this once because the dGPU got active again after booting into the os with AMD kexts)

*) Boot into recovery mode (Command + r)

*) Start Terminal

*) diskutil cs list (find UUID for drive)

*) diskutil coreStorage unlockVolume UUID

*) cd /Volumes/Macintosh\ HD

*) mkdir AMD_Kexts

*) mv System/Library/Extensions/AMD*.* AMD_Kexts/

*) reboot



(If you only have one storage with 1 partition just use "cd /Volumes/Macintosh\ HD" and the remaining commands after starting the terminal)


Extra STEP), if your PC is now working! Download “steveschow” branch of gfxCardStatus (gfxCardStatus v2.4.3i) or just download the app directly from:

URLS:

https://github.com/steveschow/gfxCardStatus/releases

https://github.com/steveschow/gfxCardStatus

With this application you can even prove that the dedicated GPU can't get activated. Even if you try to change the selected GPU to the dedicated one, it just won't change.


—————

The End!

AND VOILA!!! You have a working 17 inch MacBook Pro. As I said I tested this with an early 2011 and late 2011 17 inch MacBook Pro’s and both are now running (Before they were both dead)


Big thanks to AppleMacFinder, to the makers and contributors of this thread, to gfxCardStatus maker and forkers :D (steveschow) and to switch-gpu makers I can’t thank you guys enough as I am so happy to bring both of this incredible machines back to life. With this post I am not trying to take any credit, but as I had 2 machines I run into different issues with both, which could be helpful to others, thats why I was inclined to make “my own” guide and share it with you.


I just created an account here to share this, Hope it helps more people!
 
  • Like
Reactions: AppleMacFinder
[doublepost=1498471708][/doublepost]Hi,

Thanks for the post on this topic. I have had moderate success with this solution.

I have a Macbook Pro Nov, 2011 model with a failed gpu. I have modified the efivars as you describe above, and I am able to reboot the system and all works perfectly.

However, after a few hours the system randomly shuts down and I have to go through the whole process again. I have done this a half dozen times now, and each time the system works for a few hours or even a day or two and then randomly reverts back to the Apple gpu.

I noticed that within the efivarfs directory, there is also a variable called gpu-policy-xxx which has a UUID that is different from the UUID of the gpu-prefs-xxx. There is also an gpu-active-xxx which has the same UUID as the gpu-prefs-xxx.

I couldnt find any documentation on the gpu-policy variable, but might this variable be causing the system to revert back to the Apple gpu?

Note that I am not running any games or heavy graphics that might overload the graphics card. I am only using basic desktop applications. The system will even shut down randomly over night while I am not using it and revert back to the failed Apple gpu.

Any ideas on what would be causing the system to randomly revert back to the Apple gpu?


------------------------------

Update to my issue noted above:

It looks like I am having the same issue with overheating as some of the other posters here. I have been monitoring the processes to ensure that the mac doesnt overheat and this is working well....so far I have gone 2 days without issue.

However, I restarted the computer voluntarily and it reverted back to AMD graphics card...and hence I had to redo the entire process again!

I did notice that I after umount the /sys/firmware/efi/efivars, and reboot, there is a note in the resultng dialogue that szys
Failed umount.

Maybe this has something to do with why the switch doesnt hold after rebooting a second time. But I did notice that the gpu-power-prefs is still there with the same UUID even though it fails to boot with this.

Anyways, thanks to all who have helped with this solution. While it is not perfect, it does at least allow me to access my MBP!
 
  • Like
Reactions: AppleMacFinder
Thanks for the extensive explanation. According to the first post (AppleMacFinder) unmounting would secure the settings. Rebooting without unmounting first worked, so no problem.

I already did the fix for the evifars/gpu-power-prefs before removing the AMD kexts, so I don't need to go there anymore. But interesting to learn a little more about how things work.

The partition name not showing up is really strange. It is MacBook without a space (BTW I bought the MBP refurbished and the name was already MacBook), so that shouldn't be a problem. Anyway, I managed to get it up and running, everything is back to normal. It even seems a little faster than before.

If there is a solution for the temperature that would be nice, I suppose the MBP will last a little longer when it stays cool.

I found this technician guide. Hope it helps.

Apple Technician Guide MacBook Pro 17 inch, 2010/2011 - Westside ...

Thanks for the PDF Guide MacBook Pro.
[doublepost=1498715381][/doublepost]
I found this: http://docshare04.docshare.tips/files/7903/79035001.pdf

It would be great to fix the heating, battery should improve too!

Thanks for the PDF guide MacBook Pro.
[doublepost=1498716323][/doublepost]

I found the heating problem.
It's the AMD kexts that are not loaded. When the kexts are not loaded, then some settings do not start (power save for GPU AMD).

Temperature 50 - 55 degrees Celsius - unloaded AMD kexts - idle.

Temperature 36 - 40 degrees Celsius - loaded AMD Kexts (AMD6000Controller.kext, AMDFramebuffer.kext, AMDSupport.kext, AMDRadeonX3000.kext) - idle.


Test:
MacBook Pro Early 2011

Integrated GPU: Intel HD 3000 - 512 MB VRAM - vendor 0x8086 - device id 0x0126

Discrete GPU: AMD Radeon HD 6750M - 1 GB VRAM - vendor 0x1002 - device id 0x6741

Mac OS Sierra 10.12.3 Installed -> Update to 10.12.5


AppleGraphicsDeviceControl.kext

AppleGraphicsDevicePolicy.kext

AppleMGPUPowerControl.kext

AppleMuxControl.kext

ApplePolicyControl.kext

One of the kexts that warmer if it is not loaded is the AMDRadeonX3000.kext. The non-loading of this kext adds 10 degrees Celsius of temperature.



kextstat | grep AMD

102 2 0xffffff7f8215b000 0x14c000 0x14c000 com.apple.kext.AMDSupport (1.4.8) 467A1A8B-7CA9-3F0E-86F5-B671F8A03BB9 <101 96 12 11 7 5 4 3 1>

103 0 0xffffff7f822a7000 0x624000 0x624000 com.apple.kext.AMD6000Controller (1.4.8) 5044F244-C9B0-353E-A5AD-EB17BD646559 <102 96 12 11 5 4 3 1>

141 0 0xffffff7f83745000 0x25000 0x25000 com.apple.kext.AMDFramebuffer (1.4.8) 0BE339EC-12BF-34FE-8FF9-A38B82AC724B <102 96 12 11 7 5 4 3 1>

158 0 0xffffff7f82b0b000 0x571000 0x571000 com.apple.AMDRadeonX3000 (1.5.1) 84843356-3B71-3A4A-8CF5-93954975B732 <157 152 96 12 7 5 4 3 1>



ioreg | grep AMD

| | | | +-o AMD6000Controller <class AMD6000Controller, id 0x1000003f8, registered, matched, active, busy 0 (0 ms), retain 5>

| | | | | +-o ATIFramebufferNI <class AMDFramebuffer, id 0x100000425, registered, matched, active, busy 0 (1464 ms), retain 16>

| | | | | +-o AMDNDRVService <class AtiAppServices, id 0x1000004bc, registered, matched, active, busy 0 (0 ms), retain 6>

| | | | | +-o ATIFramebufferNI <class AMDFramebuffer, id 0x100000441, registered, matched, active, busy 0 (0 ms), retain 14>

| | | | | +-o AMDNDRVService <class AtiAppServices, id 0x1000004be, registered, matched, active, busy 0 (0 ms), retain 6>

| | | | | +-o ATIFramebufferNI <class AMDFramebuffer, id 0x100000447, registered, matched, active, busy 0 (0 ms), retain 14>

| | | | | +-o AMDNDRVService <class AtiAppServices, id 0x1000004c2, registered, matched, active, busy 0 (0 ms), retain 6>

| | | | +-o AMDSupport <class AMDSupport, id 0x1000003f9, registered, matched, active, busy 0 (0 ms), retain 5>

| | | | +-o AMDTurksGraphicsAccelerator <class AMDTurksGraphicsAccelerator, id 0x1000006ce, registered, matched, active, busy 0 (1 ms), retain 12>

AMDTurksGraphicsAccelerator appears when the AMDRadeonX3000.kext is loaded.


cd /DisableExtensions

sudo kextload AMDRadeonX3000.kext


I put the AMD kexts (AMD6000Controller.kext, AMDFramebuffer.kext, AMDSupport.kext ) from the Mac OS Sierra 10.12.3 Installer (pendrive).

If I try to use the kexts of the Mac OS Sierra 10.12.5 installed along with the ArchLinux gpu-power-prefs, then the screen freezes at boot time in the IOConsoleUsers IOScreenLockState.

ls /System/Library/Extensions/ | grep AMD

AMD6000Controller.kext

AMDFramebuffer.kext

AMDSupport.kext



Tomorrow I put the test report in a more explanatory way.
 
Last edited:
  • Like
Reactions: AppleMacFinder
If you don't have time to read my story (which also describes some interesting technical approaches) just scroll down this thread until a "100% WORKING SOLUTION" text

Discrete AMD GPU of my 2011 MacBook Pro 8,2 has finally failed because of the reasons mentioned here ( http://logicboardmac.blogspot.ru/ ) and there ( https://www.macrumors.com/2015/02/19/2011-macbook-pro-repair-program-apple/ ) . It has been working perfectly for 6 years under quite a high load, even tried SETI@HOME mining at background! So I was confident that my MBP is not affected by bad solder / bad soldering quality and didn't want to bring it to Apple for a free repair program - partially because couldn't find the time to pause my important software projects, partially because I was afraid that Apple might give me a less reliable logic board or refuse a free repair because of the several unrelated repairs that I did manually by myself earlier to save money: changed thermal paste a few times, replaced the internal battery 2 times, replaced a keyboard with broken buttons, etc. But it finally broke down last week: laptop's screen image became distorted, it refused to boot OS X (always freezing half-way), and - Apple free repair program has already ended! I know there are affordable solutions like $50 BGA resoldering at unofficial local repair shop and that its possible to get a new replacement HD 6750M chip from AliExpress for $35 or cheaper ( http://www.aliexpress.com/item/DC-2...0028-216-0810028-BGA-Chipset/32764872143.html or https://www.aliexpress.com/item/DC-2015-New-216-0810001-216-0810001-Graphic-Chipset/32718112928.html , because don't know if this is true - https://www.rossmanngroup.com/board...0604-replace-216-0810005-gpu-with-216-0810028 ) to guarantee a successful repair, so the total price of repair would be either $50 or $50+$35=$85 - less than $100 in any case. But I don't like investing money to the old computers, so I have thought - what if there is some hack to force MBP to use integrated graphics ALL THE TIME, even while booting ? And then started to explore the possible solutions...

===

First of all, it is possible to successfully boot a MBP to OS X while still using the failed GPU, after you remove the AMD drivers by booting in command line mode (CMD+S) and entering these commands:
1) fsck -fy (to check a disk)
2) mount -uw / (mount a root filesystem with read/write permissions)
3) sudo mkdir /AMD_Kexts/ (make a directory to store the AMD drivers in case you'll need them in future)
4) sudo mv /System/Library/Extensions/AMD*.* /AMD_Kexts/ (move the AMD drivers)
5) sudo rm -rf /System/Library/Caches/com.apple.kext.caches/ (remove the AMD drivers cache)
6) sudo mkdir /System/Library/Caches/com.apple.kext.caches/ (just in case OS X will be dumb and will not recreate this directory, I am creating it for OS X)
7) sudo touch /System/Library/Extensions/ (to update the timestamps so that new driver caches - without AMD drivers - will be definitely rebuilt)
8) sudo umount / (umount a partition to guarantee that your changes are flushed to it)
9) sudo reboot

The degree of your inconvenience while doing these steps - strongly depends on how heavily a screen's image is distorted in your case. In my case it was even more difficult because the OS X partition became a "read-only" partition (because of too many emergency shutdowns I did while desperately trying to boot OS X with a failed GPU) so I had to remove a hard drive from MacBook Pro and (using a USB to SATA 2.5" adapter taken from my portable HDD) attached it to a computer with Linux, then followed these instructions:

https://superuser.com/questions/961401/mounting-hfs-partition-on-arch-linux (1st answer) - carefully executed a number of commands, calculated a sizelimit for my parition layout, and finally ran sudo mount -t hfsplus -o force,rw,sizelimit=YOURNUMBER /dev/sdb2 /mnt to mount this HFS+ partition to /mnt directory in read-write mode. Then I performed these "1)-7)" steps you see above, and also repaired a filesystem by running sudo fsck.hfsplus -f /dev/sdb2 before unmounting a partition with sudo umount /mnt and putting a hard drive back to MBP...

===

This gave me a MBP which could boot to OS X although STILL using a broken AMD GPU: so it screen's image is very distorted (could browse the Internet but quite inconvenient to read a text), Launchpad is super laggy, and you can't switch to Integrated GPU using gfxCardStatus because: without AMD drivers (which we had to remove to successfully boot to OS X) Macbook Pro thinks its' internal screen is External Display and gfxCardStatus tells it is impossible to switch because External Display is using AMD GPU. Somewhere I found a suggestion that it is possible to rebuild a gfxCardStatus from the source code - https://github.com/codykrieger/gfxCardStatus - with removed or commented out 156-166 lines in the ./gfxCardStatus/Classes/GSProcess.m to make it to ignore the external display:

// find out if an external monitor is forcing the discrete gpu on
CGDirectDisplayID displays[8];
CGDisplayCount displayCount = 0;
if (CGGetOnlineDisplayList(8, displays, &displayCount) == noErr) {
for (int i = 0; i < displayCount; i++) {
if ( ! CGDisplayIsBuiltin(displays))
[list addObject:[NSDictionary dictionaryWithObjectsAndKeys:
Str(@"External Display"), kTaskItemName,
@"", kTaskItemPID, nil]];
}
}


So I rebuilt a gfxCardStatus using the instructions from the last reply of this issue -
https://github.com/codykrieger/gfxCardStatus/issues/229
(also had to download a MacOSX10.11.sdk from here - https://github.com/phracker/MacOSX-SDKs/releases - unpack and copy it to XCode's /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk - because of the Apple's stupidity the latest XCode for El Capitan does not include SDK for El Capitan!) However, it still didn't work - gfxCardStatus only pretended that it has switched to Integrated GPU, while in reality OS X did not let it switch! Even after I edited ./gfxCardStatus/Classes/GSGPU.m file to enable the mysterious "Nuke it from orbit switching" option, it still couldn't switch...

===

Then I discovered this interesting repository - https://github.com/0xbb/gpu-switch - which is partially similar by its' source code to gfxCardStatus but also has the "Login Hooks" (install_hooks.sh) to "automate the switching process for login/logout". Sadly it didn't work for me... However, there is a very interesting gpu-switch text file right at the root of this repository, which describes the EFI variables!

https://github.com/0xbb/gpu-switch/blob/master/gpu-switch

After studying it and also reading this issue's comments - https://github.com/0xbb/gpu-switch/issues/11 - I became confident to try this solution, but found out that my MacBook Pro 2011 8,2 with OS X El Capitan 10.11.6 is in a VERY problematic situation:

1) rEFInd is not installed, and to install it - must disable SIP protection. But I cannot boot to Recovery mode (Command+Option+R) or to OS X Installation DVD/USB (hold Option), (to disable SIP), because they freeze while booting! - although I removed AMD kexts from my system, of course these recovery tools are using AMD kexts integrated to their design. Also cannot use Rootfool hack ( https://github.com/gdbinit/rootfool ) to disable SIP during runtime, because it works only at OS X version older than 10.11.4

2) Tried overheating my Macbook Pro on purpose (forcing CPU usage to 100% and putting it to a tightly closed bag) to force it to shutdown from overheating and then quickly reboot so that Integrated graphics will be enabled during the boot time - making it possible to boot to Recovery. But because of the wonderful high end thermal paste I have applied not so long ago - cannot overheat it even after waiting for a long time! At this point I thought that could either: a) remove AMD kexts from Installation media, or b) to connect MBP's hard drive to a Linux machine again and run a bunch of chmods to remove the SIP flags from the directories mentioned here ( http://apple.stackexchange.com/questions/193368/what-is-the-rootless-feature-in-el-capitan-really ) which could potentially make a system unbootable, or c) to try installing rEFInd to HFS+ partition directly from a Linux machine with root rights because it will bypass SIP --- but have not explored these options, although some of them might have worked...

3) Wanted to boot a Linux LiveCD to edit the EFI variables from there, but no matter what I did: tried booting straight without GRUB option modifications, tried editing GRUB boot options (with "e" key) to add nomodeset / remove quiet splash / or both in every combination , or like suggested in this article ( https://wiki.archlinux.org/index.php/MacBookPro8,1/8,2/8,3_(2011) ) also add i915.modeset=0 radeon.modeset=0 or radeon.modeset=0 i915.modeset=1 i915.lvds_channel_mode=2 ; and then pressed Fn+F10 or Shift+Ctrl+Fn+F10 to boot with these options: but the Linux boot process always failed at different boot stages, no matter what popular user-friendly Linux distribution or what version of it I am trying: tried many releases of Ubuntu / Lubuntu / Fedora , even the old "AMD64 Mac" and "Alternate AMD64 Mac" images, but they always failed - either at the very beginning of boot process (black screen, or a black screen with a blinking or stuck _ character at the left upper corner) or failed at the very end of it - right before it is supposed to show a graphical desktop environment...

Later, totoe_84 wrote that he was able to boot Ubuntu in graphical mode using the following setup for GRUB:
  • To disable the AMD graphics card I added the following lines after set gfxpayload=keep
outb 0x728 1
outb 0x710 2
outb 0x740 2
outb 0x750 0
  • Next I added the following after quiet splash
    i915.lvds_channel_mode=2 i915.modeset=1 i915.lvds_use_ssc=0
(based on https://ubuntuforums.org/showthread.php?t=2157775 )

===

Then I remembered that there are not-mainstream Linux distributions for advanced users, which have a LiveCD without any graphical interface: you are dropped to a pure console and you are supposed to install the system along with only those graphical interfaces and software packages / groups of packages which you explicitly select. For example: Arch Linux (https://www.archlinux.org/) and Gentoo Linux (https://gentoo.org/) . Because their LiveCD does not have a graphical interface, they could be booted without a problem to a pure Linux console and there you could edit the EFI variables ! So here is a...

===
=== 100% WORKING SOLUTION
===
=== Force your MBP to ALWAYS use Intel integrated GPU (EFI variable fix)
===
=== to make it great again ! ;)
===


1) Create the Arch Linux LiveCD/LiveUSB :

You need a working computer for that and a spare CD/DVD/USB drive. Download the latest Arch Linux ISO image from this page - https://www.archlinux.org/download/ , at the time of writing it is archlinux-2017.03.01-dual.iso . Then you could either simply burn this ISO to CD/DVD (which later could be either inserted to MBP's SuperDrive or External DVD Drive connected to MBP by two USB cables) or create a bootable USB: use the great detailed instructions from this page, https://wiki.archlinux.org/index.php/USB_flash_installation_media

2) Boot to it: insert this CD/DVD/USB to Macbook Pro, hold Option key while booting, choose "EFI boot" (that is your bootable installation media), press "e" key to edit the GRUB options of the Arch Linux archiso x86_64 UEFI CD menu entry while it is selected at the main screen, add nomodeset to the end of this line and press Enter. If everything is done correctly, you will find yourself at the Linux console!

3) Edit EFI vars: looks like efivarfs filesystem is mounted by default! So you can already cd /sys/firmware/efi/efivars and ls to explore this directory and see if there is a "gpu-power-prefs-..." variable (where ... is UUID of this variable). If there is such a variable, its better to remove it with rm. In my case the efivarfs has been mounted by default with read/write permissions, but if you are getting the "operation not permitted" message while attempting to rm, it means that in your case efivarfs has been mounted as read-only and you need to remount it with read-write permissions and try again (credits to totoe_84 for this valuable addition) :
*) cd /
*) umount /sys/firmware/efi/efivars/
*) mount -t efivarfs rw /sys/firmware/efi/efivars/
*) cd /sys/firmware/efi/efivars/

If your screen is so distorted that it is difficult to see the letters, just start typing the rm gpu-power-pre and then press TAB key for autocompletion. In my case there were not such a EFI variable, only "gpu-active-..." and maybe somehow related "gfx-saved-config-restore-status-..." . Then I looked again at that gpu-switch text file (mentioned above, https://github.com/0xbb/gpu-switch/blob/master/gpu-switch),
and entered THESE COMMANDS:

*) chattr -i "/sys/firmware/efi/efivars/" <----- skip this command

Actually a gpu-switch script had "${sysfs_efi_vars}/${efi_gpu}" but I didnt have a "gpu-power-prefs-..." variable - so, partially by mistake, I didn't add that efi_gpu suffix and entered this incomplete path accidentally

*)
printf "\x07\x00\x00\x00\x01\x00\x00\x00" > /sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9

Did not have a EFI "gpu-power-prefs-" variable so I thought that it will be OK to create a new one with a random UUID - in this case, taken directly from a gpu-switch script

*) chattr +i "/sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9"

http://www.tecmint.com/chattr-command-examples/ - chattr (Change Attribute) is a command line Linux utility that is used to set/unset certain attributes to a file in Linux system to secure accidental deletion or modification of important files and folders, even though you are logged in as a root user.
...
Syntax of chattr ---> chattr [operator] [flags] [filename]
...
A file is set with ‘i‘ attribute (+i as you see in this command) ---> cannot be modified (immutable). Means no renaming, no symbolic link creation, no execution, no writable, only superuser can unset the attribute.
...
Operator
  1. + : Adds the attribute to the existing attribute of the files.
  2. : Removes the attribute to the existing attribute of the files.
  3. = : Keep the existing attributes that the files have.
This chattr command is supposed to lock a file to make it accessible only by "superuser" - and so that, while booting, your EFI will have no chance to screw up your gpu-power-prefs-... variable under any circumstances

*) cd /

Could not unmount efivars if you are inside this directory, so change to the root directory

*) umount /sys/firmware/efi/efivars/

Guarantees that your EFI variables are flushed to efivarfs filesystem, please unmount it safely before rebooting)

*) reboot

===> IF YOU DID EVERYTHING CORRECTLY, MOST LIKELY THAT YOUR MACBOOK PRO IS NOW USING INTEGRATED GRAPHICS WHILE BOOTING, AFTER BOOTING, AND IS WORKING GREAT AGAIN ! ;)

In the future maybe you could need to re-apply this solution if you would have to reset your PRAM / NVRAM / SMC because of some other problems, so remember this solution somewhere... Funny thing: now you can't switch to Discrete GPU even using gfxCardStatus, it is forever stuck at Integrated


I spent two working days to discover this solution, and really hope that it will work flawlessly for every MBP owner with a broken discrete GPU. Good luck!
[doublepost=1498745937][/doublepost]I followed these steps, and it worked! HOWEVER, now everything is INSANELY SLOW. looks like a kernel process is using 99% of the CPU according to the activity monitor. I mean insanely slow as in took like 10 minutes from the point where it showed the desktop background image to the point where everything was finally displayed (stuff on desktop, time, date, wifi bar and background programs). whole process took less than 15 seconds before issue. Any ideas why this fix would cause the computer to become so confused?
 
  • Like
Reactions: AppleMacFinder
MacBook Pro Early 2011

Intel GPU - Intel HD 3000

AMD GPU - AMD Radeon HD 6750M

Mac OS Sierra 10.12.3 update to 10.12.5


I installed the gfxcardstatus Steve Show and tried to switch to the AMD video card but it is locked on the Intel video card because of Arch Linux gpu-power-prefs. Even with the AMD kexts loaded.

gfxCardStatus.app-v2.4.3i-Integrated-Only-Patch

https://github.com/steveschow/gfxCardStatus/releases

When I switch to the AMD video card by gfxcardstatus, the System Preferences setting is changed (disable Automatic Graphics Switching). But the video card remains Intel (gfxcardstatus and Istat Menu).

System Preference -> Energy Saver -> Automatic Graphics Switching (disable) -> gfxcardstatus -> remains intel video card. (temperature normal CPU Die Analog - 36 degrees Celsius - idle)

gfxcardstatus -> Discrete Only -> remains intel video card. (temperature normal CPU Die Analog - 36 degrees Celsius - idle)


The AMD kexts of the Mac OS Sierra 10.12.3 installer (pen drive) are different from the AMD kexts installed on the Hard Disk (Mac OS Sierra 10.12.3).

The AMD kexts (1.4.8) have to be placed on the system to not freeze the screen at boot (IOConsoleUsers IOScreenLockState).

Mac OS Sierra 10.12.3 Installer (pendrive)
AMDSupport.kext (1.4.8)
AMDFramebuffer.kext (1.4.8)
AMD6000Controller.kext (1.4.8)


Install macOS Sierra.app/Contents/SharedSupport/InstallESD.dmg
AMDSupport.kext (1.5.1)
AMDFramebuffer.kext (1.5.1)
AMD6000Controller.kext (1.5.1)


Kexts AMD on the Mac OS Sierra 10.12.5 (updated) installed hard disk. Is a Mac OS Sierra Frankenstein but works by normalizing the temperature.

kextstat | grep AMD

112 2 0xffffff7f832a5000 0x14d000 0x14d000 com.apple.kext.AMDSupport (1.4.8) 467A1A8B-7CA9-3F0E-86F5-B671F8A03BB9 <111 102 12 11 7 5 4 3 1>

113 0 0xffffff7f8343a000 0x624000 0x624000 com.apple.kext.AMD6000Controller (1.4.8) 5044F244-C9B0-353E-A5AD-EB17BD646559 <112 102 12 11 5 4 3 1>

133 0 0xffffff7f83401000 0x25000 0x25000 com.apple.kext.AMDFramebuffer (1.4.8) 0BE339EC-12BF-34FE-8FF9-A38B82AC724B <112 102 12 11 7 5 4 3 1>

159 0 0xffffff7f83cbb000 0x571000 0x571000 com.apple.AMDRadeonX3000 (1.5.1) 84843356-3B71-3A4A-8CF5-93954975B732 <158 141 102 12 7 5 4 3 1>


0 - ArchLinux - gpu-power-prefs

or

Enter boot Single User (Mac OS) - Command + S

sudo nvram fa4ce28d-b62f-4c99-9cc3-6815686e30f9:gpu-power-prefs=%01%00%00%00


1 - After installing Mac OS Sierra 10.12.3, first reboot - first rebuild kernel cache, you should remove the AMD kexts (1.5.1) and ATI kexts (1.5.1) using the AppleMacFinder or FGuarani method (mkdir DisableExtensions, mv AMD*.* /DisableExtensions, mv ATI*.* /DisableExtensions).

Probably in the first reboot / rebuild kernel cache, the system will be frozen in IOConsoleUser IOScreenLockState. Press the Power button to turn off the Macbook Pro and then restart the system and enter the Mac OS Sierra Installer (pendrive) - Option key at boot.

The AMDRadeonX3000.kext moved to DisableExtensions directory/folder.


2 - Boot from Mac OS Sierra Installer (pendrive), mount partition hard disk (diskutil) with Mac OS Sierra installed hard disk.


3 - Example /Volumes

Mac OS Sierra installer 10.12.3 (pendrive) - > /Volumes/OS\ X\ Base\ System/

Mac OS Sierra 10.12.3 installed on hard disk -> /Volumes/MacSierra


4 - Copy AMD kexts (1.4.8) from pendrive to hard disk - use TAB key to autocomplete name directory/folder:

cp -v -r (-v verbose / -r or -R - recursive - copy directory/folder). Example: AMD6000Controller.kext is a directory/folder.

cp -v -r /Volumes/OS\ X\ Base\ System/System/Library/Extensions/AMDSupport.kext /Volumes/MacSierra/System/Library/Extensions/

cp -v -r /Volumes/OS\ X\ Base\ System/System/Library/Extensions/AMDFramebuffer.kext /Volumes/MacSierra/System/Library/Extensions/

cp -v -r /Volumes/OS\ X\ Base\ System/System/Library/Extensions/AMD6000Controller.kext /Volumes/MacSierra/System/Library/Extensions/


5 - Restart the system:

reboot


6 - The kexts AMD (1.4.8) on the installed system (loaded at boot time):

/System/Library/Extensions/
AMDSupport.kext (1.4.8)
AMDFramebuffer.kext (1.4.8)
AMD6000Controller.kext (1.4.8)


7 - After login, load AMDRadeonX3000.kext - in Terminal:

Remember, AMDRadeonX3000.kext moved to /DisableExtensions directory.

cd /DisableExtensions

sudo kextload AMDRadeonX3000.kext


8 - Check kexts AMD loaded:

kextstat | grep AMD

109 2 0xffffff7f832a5000 0x14d000 0x14d000 com.apple.kext.AMDSupport (1.4.8) 467A1A8B-7CA9-3F0E-86F5-B671F8A03BB9 <108 103 12 11 7 5 4 3 1>

110 0 0xffffff7f8343a000 0x624000 0x624000 com.apple.kext.AMD6000Controller (1.4.8) 5044F244-C9B0-353E-A5AD-EB17BD646559 <109 103 12 11 5 4 3 1>

140 0 0xffffff7f83401000 0x25000 0x25000 com.apple.kext.AMDFramebuffer (1.4.8) 0BE339EC-12BF-34FE-8FF9-A38B82AC724B <109 103 12 11 7 5 4 3 1>

159 0 0xffffff7f83cbb000 0x571000 0x571000 com.apple.AMDRadeonX3000 (1.5.1) 84843356-3B71-3A4A-8CF5-93954975B732 <158 141 103 12 7 5 4 3 1>


9 - Check that the temperature starts decreasing with the Istat Menu.

https://bjango.com/mac/istatmenus/

My test:
Istat Menu:

CPU - GPU: N (show GPU in use) - i Integrated - a AMD

Sensors: CPU Die - Analog

Each update Mac OS Sierra, the procedure should be repeated with the AMD kexts.
 
Last edited:
  • Like
Reactions: AppleMacFinder
I cannot drive an external monitor/projector anymore due to the fact that the displayport seems to be directly wired to the (now bypassed) discrete gpu. Anyone with experience with those small usb external videocards? Do they work properly?

zz2003 reported that USB to VGA adapters are working ok. Great to know! Thank you zz2003 ;)

I just received my USB to VGA converter. It works, although not perfect. A little lagging noticed when manipulating windows (opening, closing, switching, etc). I've played youtube videos in HD, with screen resolution 1920*1080, and the lagging is barely noticeable. Also the taskbar is showing up in the wrong color and resolution. But other than that, no complains. Mine is 2011 MBP with USB2.0, USB3.0 might be better.

Is there anything I can do in Mac OS to prevent it from reverting everything I did in linux' console?
Please check FGuirani's instruction below: it is similar to my, but has a few differences that really help to achieve the permanent graphics switching solution to some people who didn't have it permanent after trying my instruction
https://forums.macrumors.com/thread...efi-variable-fix.2037591/page-5#post-24511780

However, after a few hours the system randomly shuts down and I have to go through the whole process again. I have done this a half dozen times now, and each time the system works for a few hours or even a day or two and then randomly reverts back to the Apple gpu

Same advice as above about FGuirani's version of instruction, please try it and hopefully it will work for you

I followed these steps, and it worked! HOWEVER, now everything is INSANELY SLOW. looks like a kernel process is using 99% of the CPU according to the activity monitor. I mean insanely slow as in took like 10 minutes from the point where it showed the desktop background image to the point where everything was finally displayed (stuff on desktop, time, date, wifi bar and background programs). whole process took less than 15 seconds before issue. Any ideas why this fix would cause the computer to become so confused?
Are you sure that you have removed AMD kexts? If you haven't, please look through my 1st message of this thread - it describes how to remove the AMD kexts
 
Hi,

First of all, thanks a lot MacFinder for the EFI variable fix. My macbook AMD just died again for the third time... Bt now that they shut down the ****** parts replacement program, I need to get this fix working. I followed the steps successfully but my graphics are now REALLY slow. I can't play a video or do any action without glitch appearing on the screen. I cannot boot normally, I have to boot in safe mode, otherwise it hangs in the middle of the progress bar on the apple logo. I moved the kext files and did all the steps to always use the integrated intel graphics (gfxCardStatus shows me only one card) but I can't use my laptop because of the slow graphics. I run Sierre 10.12.5.

I read that other can still do intensive tasks without any problems. Did I missed something ?

Again, thank you very much for helping us.
[doublepost=1498878798][/doublepost]
Hi,

First of all, thanks a lot MacFinder for the EFI variable fix. My macbook AMD just died again for the third time... Bt now that they shut down the ****** parts replacement program, I need to get this fix working. I followed the steps successfully but my graphics are now REALLY slow. I can't play a video or do any action without glitch appearing on the screen. I cannot boot normally, I have to boot in safe mode, otherwise it hangs in the middle of the progress bar on the apple logo. I moved the kext files and did all the steps to always use the integrated intel graphics (gfxCardStatus shows me only one card) but I can't use my laptop because of the slow graphics. I run Sierre 10.12.5.

I read that other can still do intensive tasks without any problems. Did I missed something ?

Again, thank you very much for helping us.

No need to answer, I thought I removed the kexts files but I had to remove de SIP first for it to work.

Thanks
 
  • Like
Reactions: AppleMacFinder
Had to sign up to thank you folks for solving my late 2011 Macbook problems, specially AppleMacFinder for starting this thread, and ngsr for solving the thermal issues! Moving the Kexts and creating the EFI changes gave me my screen back, and now with reasonable temperatures back - My Macbook Pro is back in full service! Thank you so much People!

A novice working with Terminal and unix commands I finally figured out how to copy (Boot in Recovery Mode) the 1.44 AMD kexts in the extensions folder from the USB Sierra boot disk. (Small typo I think in the AMDSupport copy command.. Only one /Volumes/ instead of /Volumes/Volumes/... The other two copy instructions worked pefectly.) Did not want to download Sierra 10.12.5 from the App Store because I figured the AMD kexts would be the same vintage as I already had in my Sierra system. But I found a early version of Sierra Install that I downloaded when Sierra first came out, and used it to create the USB installation disk. They turned out to be ver 1.44 instead of ngsr's 1.48, but they worked fine and did the trick in reducing temps and current draws. With Opera Browser, and Mac Mail running before the changes, my MBP was sucking about 2500ma from the battery, and GPU temps were in the mid 50's. After restoring ver 1.44 kexts AMDSupport, AMD6000controller and AMDFramebuffer and the ver 1.51 of AMDRadeonX3000, current draws dropped to less than 1000ma, and temps fell to 36 degrees! iStat reports that expected battery life went from 3 hours to almost 5 hours!

Thank you all for converting my MBP from a doorstop to a fully refurbished machine!
 
I feel like you're instructions are incomplete as you expect us to just know certain things or there is a bunch of random extra information that is creating some confusion in your instructions because I'm struggling to make sense of most of what you have written.

Can this fix be done on a machine that is already running Sierra 10.12.5. or do I need to do a fresh install of 10.12.3?

If I go and make a bootable installer of Sierra how can I verify that my USB stick has 10.12.3 on it with the correct 1.4.8 kexts?



MacBook Pro Early 2011

Intel GPU - Intel HD 3000

AMD GPU - AMD Radeon HD 6750M

Mac OS Sierra 10.12.3 update to 10.12.5


I installed the gfxcardstatus Steve Show and tried to switch to the AMD video card but it is locked on the Intel video card because of Arch Linux gpu-power-prefs. Even with the AMD kexts loaded.

gfxCardStatus.app-v2.4.3i-Integrated-Only-Patch

https://github.com/steveschow/gfxCardStatus/releases

When I switch to the AMD video card by gfxcardstatus, the System Preferences setting is changed (disable Automatic Graphics Switching). But the video card remains Intel (gfxcardstatus and Istat Menu).

System Preference -> Energy Saver -> Automatic Graphics Switching (disable) -> gfxcardstatus -> remains intel video card. (temperature normal CPU Die Analog - 36 degrees Celsius - idle)

gfxcardstatus -> Discrete Only -> remains intel video card. (temperature normal CPU Die Analog - 36 degrees Celsius - idle)


The AMD kexts of the Mac OS Sierra 10.12.3 installer (pen drive) are different from the AMD kexts installed on the Hard Disk (Mac OS Sierra 10.12.3).

The AMD kexts (1.4.8) have to be placed on the system to not freeze the screen at boot (IOConsoleUsers IOScreenLockState).

Mac OS Sierra 10.12.3 Installer (pendrive)
AMDSupport.kext (1.4.8)
AMDFramebuffer.kext (1.4.8)
AMD6000Controller.kext (1.4.8)


Install macOS Sierra.app/Contents/SharedSupport/InstallESD.dmg
AMDSupport.kext (1.5.1)
AMDFramebuffer.kext (1.5.1)
AMD6000Controller.kext (1.5.1)


Kexts AMD on the Mac OS Sierra 10.12.5 (updated) installed hard disk. Is a Mac OS Sierra Frankenstein but works by normalizing the temperature.

kextstat | grep AMD

112 2 0xffffff7f832a5000 0x14d000 0x14d000 com.apple.kext.AMDSupport (1.4.8) 467A1A8B-7CA9-3F0E-86F5-B671F8A03BB9 <111 102 12 11 7 5 4 3 1>

113 0 0xffffff7f8343a000 0x624000 0x624000 com.apple.kext.AMD6000Controller (1.4.8) 5044F244-C9B0-353E-A5AD-EB17BD646559 <112 102 12 11 5 4 3 1>

133 0 0xffffff7f83401000 0x25000 0x25000 com.apple.kext.AMDFramebuffer (1.4.8) 0BE339EC-12BF-34FE-8FF9-A38B82AC724B <112 102 12 11 7 5 4 3 1>

159 0 0xffffff7f83cbb000 0x571000 0x571000 com.apple.AMDRadeonX3000 (1.5.1) 84843356-3B71-3A4A-8CF5-93954975B732 <158 141 102 12 7 5 4 3 1>


0 - ArchLinux - gpu-power-prefs

or

Enter boot Single User (Mac OS) - Command + S

sudo nvram fa4ce28d-b62f-4c99-9cc3-6815686e30f9:gpu-power-prefs=%01%00%00%00


1 - After installing Mac OS Sierra 10.12.3, first reboot - first rebuild kernel cache, you should remove the AMD kexts (1.5.1) and ATI kexts (1.5.1) using the AppleMacFinder or FGuarani method (mkdir DisableExtensions, mv AMD*.* /DisableExtensions, mv ATI*.* /DisableExtensions).

Probably in the first reboot / rebuild kernel cache, the system will be frozen in IOConsoleUser IOScreenLockState. Press the Power button to turn off the Macbook Pro and then restart the system and enter the Mac OS Sierra Installer (pendrive) - Option key at boot.

The AMDRadeonX3000.kext moved to DisableExtensions directory/folder.


2 - Boot from Mac OS Sierra Installer (pendrive), mount partition hard disk (diskutil) with Mac OS Sierra installed hard disk.


3 - Example /Volumes

Mac OS Sierra installer 10.12.3 (pendrive) - > /Volumes/OS\ X\ Base\ System/

Mac OS Sierra 10.12.3 installed on hard disk -> /Volumes/MacSierra


4 - Copy AMD kexts (1.4.8) from pendrive to hard disk - use TAB key to autocomplete name directory/folder:

cp -v -r (-v verbose / -r or -R - recursive - copy directory/folder). Example: AMD6000Controller.kext is a directory/folder.

cp -v -r /Volumes/Volumes/OS\ X\ Base\ System/System/Library/Extensions/AMDSupport.kext /Volumes/MacSierra/System/Library/Extensions/

cp -v -r /Volumes/OS\ X\ Base\ System/System/Library/Extensions/AMDFramebuffer.kext /Volumes/MacSierra/System/Library/Extensions/

cp -v -r /Volumes/OS\ X\ Base\ System/System/Library/Extensions/AMD6000Controller.kext /Volumes/MacSierra/System/Library/Extensions/


5 - Restart the system:

reboot


6 - The kexts AMD (1.4.8) on the installed system (loaded at boot time):

/System/Library/Extensions/
AMDSupport.kext (1.4.8)
AMDFramebuffer.kext (1.4.8)
AMD6000Controller.kext (1.4.8)


7 - After login, load AMDRadeonX3000.kext - in Terminal:

Remember, AMDRadeonX3000.kext moved to /DisableExtensions directory.

cd /DisableExtensions

sudo kextload AMDRadeonX3000.kext


8 - Check kexts AMD loaded:

kextstat | grep AMD

109 2 0xffffff7f832a5000 0x14d000 0x14d000 com.apple.kext.AMDSupport (1.4.8) 467A1A8B-7CA9-3F0E-86F5-B671F8A03BB9 <108 103 12 11 7 5 4 3 1>

110 0 0xffffff7f8343a000 0x624000 0x624000 com.apple.kext.AMD6000Controller (1.4.8) 5044F244-C9B0-353E-A5AD-EB17BD646559 <109 103 12 11 5 4 3 1>

140 0 0xffffff7f83401000 0x25000 0x25000 com.apple.kext.AMDFramebuffer (1.4.8) 0BE339EC-12BF-34FE-8FF9-A38B82AC724B <109 103 12 11 7 5 4 3 1>

159 0 0xffffff7f83cbb000 0x571000 0x571000 com.apple.AMDRadeonX3000 (1.5.1) 84843356-3B71-3A4A-8CF5-93954975B732 <158 141 103 12 7 5 4 3 1>


9 - Check that the temperature starts decreasing with the Istat Menu.

https://bjango.com/mac/istatmenus/

My test:
Istat Menu:

CPU - GPU: N (show GPU in use) - i Integrated - a AMD

Sensors: CPU Die - Analog

Each update Mac OS Sierra, the procedure should be repeated with the AMD kexts.
 
Had to sign up to thank you folks for solving my late 2011 Macbook problems, specially AppleMacFinder for starting this thread, and ngsr for solving the thermal issues! Moving the Kexts and creating the EFI changes gave me my screen back, and now with reasonable temperatures back - My Macbook Pro is back in full service! Thank you so much People!

A novice working with Terminal and unix commands I finally figured out how to copy (Boot in Recovery Mode) the 1.44 AMD kexts in the extensions folder from the USB Sierra boot disk. (Small typo I think in the AMDSupport copy command.. Only one /Volumes/ instead of /Volumes/Volumes/... The other two copy instructions worked pefectly.) Did not want to download Sierra 10.12.5 from the App Store because I figured the AMD kexts would be the same vintage as I already had in my Sierra system. But I found a early version of Sierra Install that I downloaded when Sierra first came out, and used it to create the USB installation disk. They turned out to be ver 1.44 instead of ngsr's 1.48, but they worked fine and did the trick in reducing temps and current draws. With Opera Browser, and Mac Mail running before the changes, my MBP was sucking about 2500ma from the battery, and GPU temps were in the mid 50's. After restoring ver 1.44 kexts AMDSupport, AMD6000controller and AMDFramebuffer and the ver 1.51 of AMDRadeonX3000, current draws dropped to less than 1000ma, and temps fell to 36 degrees! iStat reports that expected battery life went from 3 hours to almost 5 hours!

Thank you all for converting my MBP from a doorstop to a fully refurbished machine!

Thanks for the correction.

I made a mistake while putting the word Volumes twice in the path for the kexts.

I have corrected my previous post on the AMDSupport.kext path. (/Volumes/Volumes -> /Volumes)

When the AMD kexts were not loaded, Safari / Google Chrome or Firefox were at 85 degrees Celsius with several tabs open.

Now with the AMD kexts loaded, they reach a maximum of 60 degrees Celsius on news sites and Youtube.

When the AMD kexts are not loaded, the AMD video card should operate at maximum power even when not in use.
[doublepost=1498949336][/doublepost]
I feel like you're instructions are incomplete as you expect us to just know certain things or there is a bunch of random extra information that is creating some confusion in your instructions because I'm struggling to make sense of most of what you have written.

Can this fix be done on a machine that is already running Sierra 10.12.5. or do I need to do a fresh install of 10.12.3?

If I go and make a bootable installer of Sierra how can I verify that my USB stick has 10.12.3 on it with the correct 1.4.8 kexts?

I'm doing some tests here and then I answer in a more practical way.

But yes, you can do this with Sierra 10.12.5 installed. Every time there is an AMD kexts update from the App Store, you will have to repeat the procedure.

For example, if there is an AMD kexts update (Sierra 10.12.6), you will have to repeat the kexts procedure.

It is not necessary to have exactly the AMD kexts (1.4.8). What is needed is to have kexts AMD that do not freeze the screen in IOConsoleUsers IOScreenLockState.

When you do the procedure with ArchLinux, and do not remove the AMD kexts, then you may have this IOConsoleUsers IOScreenLock problem at the boot of the system installed on the hard disk.
 
Last edited:
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.