Boot menus for graphics output protocol.

Discussion in 'Mac Pro' started by DearthnVader, Nov 17, 2017.

  1. DearthnVader macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #1
    I compiled Jief_Machak's version of rEFInd, that should have support for initializing graphics cards that have a GOP rom on them. Pretty much any resent graphics card should work.

    If you don't know what rEFInd is, it's basically a boot manager, Jief said he was not able to boot Windows, but I'm not sure if he had Windows installed via Bootcamp, i.e. CSM, or Bios comparability.

    Seems if you have Windows installed via EFI/UEFI then this version of rEFInd should be able to boot it, but there maybe some roadblock we'll have to work out.

    I don't own a MacPro, so I can't test it, so don't be surprised if I screwed something up and it doesn't work, just let me know, and I'll try and figure out what I did wrong.

    As far as I remember, Apple's EFI looks for the boot.efi in /System/Library/CoreServices/, that is the file that gets blessed by the startup disk utility. I think Apple's Boot Manager, that you get when you hold the Option Key, if you have an EFI video card, also looks in the standard /EFI/Boot location for a file called BootX64.efi, and I think it also looks for other bootable files in the /EFI partition of all GUID disks.

    Because people using this version of rEFInd don't have EFI boot screens, it becomes necessary to "bless" rEFInd, rather than any other boot manager or boot file, don't worry it won't harm your Mac, and clearing the NVRam will have you right back where you were, without boot screens in you Apple Boot Manager.

    I'll be uploading the rEFInd files for testers in a few, as soon as my Qemu install of HS wants to start cooperating with me.

    The normal disclaimers apply, just don't blame me if this software knocks up you teenage daughter, kicks you dog, or burns your house down.
    --- Post Merged, Nov 17, 2017 ---
    Here is the link, it includes all the standard rEFInd file, plus refind_GOPX64.efi.

    That's really the file needed.

    https://drive.google.com/open?id=1_a3u4DAJKza_xT27lQ5uotW_1DHqG-8t

    You'll have to disable SIP, or at least disable the part of SIP that blocks access to NVRam, as you'll need to "Bless" the refind_GOPX64.efi.

    Sorry, 64 bit EFI only, right now.

    Here is a page that covers how to manually install rEFInd:

    http://www.rodsbooks.com/refind/installing.html#osx

    Also in the Doc dir of the zip file, you should find an install.html file.

    Don't use the install script, it doesn't yet support the refind_GOPX64.efi.

    Let me know if/how it works.
     
  2. DearthnVader thread starter macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #2
    From Jief's notes in the screen.c file, where he does the GOP inti code, he took the code from Clover, so Clover should be able to do the same thing, and likely would be a better bootlaoder/bootmanager than rEFInd, as I'm not sure rEFInd can boot macOS Recovery partitions.

    Tho Clover will try and overwrite some of you Mac's SMBios info if you don't get a proper config.plist for Clover, making Facetime and Messages not work.
     
  3. DearthnVader, Nov 17, 2017
    Last edited: Nov 17, 2017

    DearthnVader thread starter macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #3
    Just playing around with this version of rEFInd in Qemu it seems that Apple's boot.efi could not get the Console from rEFInd. I'm not sure that's going to be a problem on a real Mac or not.

    This version of rEFInd was able to load my GOP driver for my nVidia GTX 1050, that I'm passing to my Qemu virtual maching via PCI Passthrough. When the the rEFInd GUI loads, it loads at full screen resolution on my 1080p screen, so those with 4k screens and no Boot Screens may also find it useful, it should work.

    Just to cover how to use this, you can install rEFInd tow ways, one on the root of your HFS/APFS partition, or in the hidden ESP/EFI partition of your disk, however you'll have to disable SIP to "Bless" the install as bootable. This does present a problem for people without EFI graphics cards, as you'll have to boot Recovery mode blind and issue the commands.

    Once SIP is disabled, you can bless the install of rEFInd, to install rEFInd on you ESP/EFI partion you'll have to mount it first, I recommend downloading Clover Configurator http://mackie100projects.altervista.org/download-clover-configurator/

    And just chose Mount EFI, once your EFI is mounted make a dir name refind on it, then copy over the files refind_GOPx64.efi and refind.conf-sample( rename it refind.conf ), then the folders icons and drivers_x64, into the refind folder on your ESP/EFI disk.

    Just to be clear, put the refind folder in the efi floder on your ESP/EFI disk.

    Then you need to bless it,

    Code:
    sudo bless --mount /Volumes/EFI --setBoot --file /Volumes/EFI/efi/refind/refind_x64.efi --shortform
    You may need to replace EFI with ESP depending on how you mount it:

    Code:
    sudo bless --mount /Volumes/ESP --setBoot --file /Volumes/ESP/efi/refind/refind_GOPx64.efi --shortform
    If you get no errors, just reboot and you should get the rEFInd boot manager screen to select you OS, with any luck.

    The other way is to just create a folder named EFI on the root of one of your macOS boot drive, this is usually read only, so you'll need to use sudo:

    In the terminal app:

    Code:
    cd /
    sudo mkdir efi
    
    Then copy the files and folder I outlined in the steps for ESP installing, into the EFI folder at the root of your boot drive. Now you need to "Bless" it.

    Code:
    sudo bless --setBoot --folder /efi/refind --file /efi/refind/refind_GOPx64.efi
    If no errors, reboot to rEFInd.

    If something goes wrong, Commad+Option+P+R should get you back to the macOS, tho if you're using an nVidia card without a bootscreen it will clear the nv_driver 1 from your NVRam and you may need to do something to fix that.

    Also, I was able to boot Windows 10 from the rEFInd menu just fine, tho it's installed in EFI/UEFI mode, it's really better to install it that way, as it boots/reboots/shutdowns a lot quicker.
     
  4. ActionableMango, Nov 17, 2017
    Last edited: Nov 17, 2017

    ActionableMango macrumors G3

    ActionableMango

    Joined:
    Sep 21, 2010
    #4
    I really really wanted to see someone do this, so thank you so much for taking the time. If you can get it working, everyone with a card from the last few generations (GOP compatible) will be able to have boot screens.

    I know a lot of people say you don't need boot screens, but they are so nice to have especially for multibooters.

    FYI - I used rEFInd and IIRC it sees recovery partitions just fine.
     
  5. owbp macrumors 6502a

    owbp

    Joined:
    Jan 28, 2016
    Location:
    Belgrade, Serbia
    #5
    Followed the thread and installed rEFInd just to remember that i have GTX680 in my MP.
    So it's either EFI ROM or ROM without GOP...

    Right time to move on. :)

    I also remember seeing Recovery with rEFInd, the only question is will it see it now (with High Sierra) when it is "hidden" in Apple container.
     
  6. goMac macrumors 604

    Joined:
    Apr 15, 2004
    #6
    I've also wondered if it would be possible to do a UGA->GOP shim that could be baked into GPU ROMs.
     
  7. ActionableMango macrumors G3

    ActionableMango

    Joined:
    Sep 21, 2010
    #7
    A GTX600 series card (630 or better I think) will be GOP compatible if you install UEFI firmware.

    If it is EVGA, MSI, or PNY you can contact support with your model and serial number to request UEFI compatible firmware. For EVGA it is support@evga.com.

    If it is ASUS, you can get a utility package from them that includes GTX680 UEFI for their 12 models of GTX680 cards and a script that uses NVflash to install the correct model firmware into your card. ASUS says there is no going back--I don't understand how that could be, but to be safe I should share that warning. Maybe they just mean their scripted utility only goes in that direction. I suspect (but do not know) that you could use NVflash manually with your old saved ROM to flash that back in.

    Zotac, which I think you have, unfortunately will not provide a UEFI firmware. Well, they didn't the last I checked. Maybe they do now.

    Caveat - I never did this myself and don't know if there are any problems doing so. So 100% at your own risk.

    Obviously it is best for Mac Pro users with GTX680 to just use the Mac EFI ROM, but for other 600 series cards this is a possibility.
     
  8. owbp macrumors 6502a

    owbp

    Joined:
    Jan 28, 2016
    Location:
    Belgrade, Serbia
    #8
    I saw a while ago that Evga offered UEFI ROMs for their 680s on forum, as was MSI and Gigabyte for their Tahiti cards.

    The thing is i want to participate in this and help as much as i can.
    I had Gigabyte R9 280X (MacEFI on one side and GOP UEFI on other side of the switch) but i've sold it with my 6 core MP while trying to snag current one a week ago.
    Now I'm left with flashed Zotac GTX680, you're right about brand, and i think that it is time to move on, both because my video work, age of the card and participation in this great project.
     
  9. DearthnVader thread starter macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #9
    Shouldn't be a problem, with apfs.efi in the Mac Pro's bootrom, rEFInd doen't bock or overwrite any drivers in the Mac's EFI Rom, as far as I know.
     
  10. h9826790, Nov 17, 2017
    Last edited: Nov 18, 2017

    h9826790 macrumors G5

    h9826790

    Joined:
    Apr 3, 2014
    Location:
    Hong Kong
    #10
    Tried, not there yet. However, obviously not the GOP doesn't work, but most likely I did something wrong. Because it seems the whole rEFInd doesn't work in my case.

    This is what I've done.

    1) Mount the EFI partition via clover configurator (I use my backup drive's EFI partition, not the primary one)
    Screen Shot 2017-11-18 at 14.24.20.jpg
    2) Make a refind folder inside the EFI folder, and copy refind_GOPx64.efi, refind.conf-sample, icons folder and the drivers_x64 folder to that folder. Then rename the refind.conf-sample to refind.conf.
    Screen Shot 2017-11-18 at 15.16.34.jpg
    3) Bless the refind_GOPx64.efi (without error)
    Screen Shot 2017-11-18 at 14.34.14.jpg
    4) Reboot

    Expect behaviour:
    Able to see the rEFInd screen. Or if no screen, I can still just press Enter to continue boot to MacOS.

    Actual behaviour:
    No screen. Tried change the monitor setting to DP 1.1, DP1.2, and DP1.2+, no different
    No keyboard. (Caps lock key no respond)
    Hit enter and wait 5 min, nothing happen.

    How to fix:
    1) Long press power button to force shutdown the Mac
    2) open side panel, pull out the test drive
    3) Press power button
    4) The Mac will automatically boot to another MacOS (in my case, the primary drive)
    5) Open system preference, and select the primary drive and the startup disk.
    6) Shutdown
    7) re-insert the test drive
    8) close the side panel

    No need to perform PRAM reset, especially with the Nvidia Maxwell / Pascal card, do not recommend PRAM reset if there is another work around.

    P.S My cMP's spec as per my signature. The test drive is a WD Red 8TB pluged into the HDD bay 1. The graphic card is a PNY 1080Ti XLR8, pure reference design (except the cooler), installed into slot 1. And I only tried Display port connection, didn't try the HDMI yet.
     
  11. DearthnVader thread starter macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #11
    Seems like you did everything right, you may want to try and add the --verbose flag to the end of the bless command and post the results, that may tell us something. No need to reboot or pull drives again, just run the bless command with --verbose, the reselect your OS X drive with the startup disk utility so you don't reboot to a dark screen again.

    I can't really say what is going wrong, but if you look on the EFI partition you installed rEFInd too, there should be a rEFInd log file, that may tell us something, or I may have to enable some logging in the GOP code. The version I posted was the debug version, but I'll have to look into how to debug it.

    Anyway, thanks for trying it out for us, seems there is still work to be done. It works fine for me in Qemu, but I don't have a Mac Pro to test with.
     
  12. h9826790 macrumors G5

    h9826790

    Joined:
    Apr 3, 2014
    Location:
    Hong Kong
    #12
    Thanks for providing the direction, will do more test tonight.

    Anyway, this is the log, not much info in there.
    Screen Shot 2017-11-18 at 16.21.04.jpg
     
  13. DearthnVader thread starter macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #13
    It let's us know that rEFInd does start, I assume you're using a 4K display?

    Maybe trouble with 4k, your 1080's GOP should support it, but maybe rEFind needs some more code to support 4k.
     
  14. MriX macrumors member

    Joined:
    Oct 23, 2017
    Location:
    Germany
    #14
    How can I find out if I have a GOP graphics card?

    Currently I have a MSI NVIDIA GT 730 2GB silent in my Mac. Will this work or should I contact MSI to get an UEFI rom?
     
  15. h9826790 macrumors G5

    h9826790

    Joined:
    Apr 3, 2014
    Location:
    Hong Kong
    #15
    Good point, not really a 4K display, but a Samsung CHG90, 3840x1080 ultra wide display. I also suspect if that may make any difference, therefore tried DP 1.1 etc.

    I can force the monitor to ident and behave like a 27" 1080P monitor if that help.

    Anyway, have to go now, able to discuss here, but will not be at the cMP to do any test until about 7 hours later.
     
  16. DearthnVader thread starter macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #16
    From what I read, the Gt 730 is a a re-branded GT430, i.e. Fermi, so I don't think there will ever be a GOP rom for it, sorry.
    --- Post Merged, Nov 18, 2017 ---
    Ok, take your time, we'll still be here.

    This is what I get @ 1080p:

    [​IMG]

    The screen.c file does some polling for the displays max resolution, and, I think, tries to set the screen to that by default. Jief was nice enough to put in debugging strings in his code, I just need to figure out how to get rEFInd to dump them to it's log.
     
  17. MriX, Nov 18, 2017
    Last edited: Nov 20, 2017

    MriX macrumors member

    Joined:
    Oct 23, 2017
    Location:
    Germany
    #17
    Looks like it is a Kepler card.

    View attachment 736668

    So means that it will be compatible or do I need a special rom from MSI?
     
  18. h9826790 macrumors G5

    h9826790

    Joined:
    Apr 3, 2014
    Location:
    Hong Kong
    #18
    May be you can send this GPU-Z screen capture to MSI and ask them if your card has GOP.
    --- Post Merged, Nov 18, 2017 ---
    More info for other testers, you really need to bless the EFI file. Choose start up disk from system preference won’t work.

    I tried to boot from rEFInd 3 times.

    First one via bless Command
    Second one via start up disk selection
    Third one via bless Command

    Only the 1st and 3rd boot is recorded in the rEFInd log file. (2nd boot also only shows black screen, keyboard Cap lock no respond, and won’t boot to desktop)
     
  19. h9826790 macrumors G5

    h9826790

    Joined:
    Apr 3, 2014
    Location:
    Hong Kong
    #19
    This is the details return of the bless command
    Screen Shot 2017-11-19 at 00.32.44.jpg
     
  20. DearthnVader thread starter macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #20
    Yes, it all looks right, we know it was properly blessed, as rEFInd's boot log showed rEFInd booting, it got stuck somewhere in the GOP init, likely with the non standard max resolution, but I won't really know until I figure out how to enable logging of the print() debugging statements in the code Jief wrote.

    Let me know if you try 1080p.
     
  21. h9826790 macrumors G5

    h9826790

    Joined:
    Apr 3, 2014
    Location:
    Hong Kong
    #21
    Tried 1080P. I set the monitor to run at Picture by Picture mode to accept 2x 1080P 60Hz signal at the same time. Testing inside MacOS, system detected native max resolution become 1080P.

    Both display port and HDMI didn’t display anything. Same behaviour, keyboard Caps lock key also no response.
     
  22. DearthnVader thread starter macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #22
    Ok, rain here today, I try and figure out rEFInd's three debug modes, so we can figure out where it's failing.
     
  23. h9826790 macrumors G5

    h9826790

    Joined:
    Apr 3, 2014
    Location:
    Hong Kong
    #23
    Thanks in advance! I will be working on the next 3 days, but than I will have 2 weeks off to go through this project with you :D
     
  24. DearthnVader thread starter macrumors 6502a

    DearthnVader

    Joined:
    Dec 17, 2015
    Location:
    Red Springs, NC
    #25
    Really no one to test it, @h9826790 tried it, and it doesn't seem to work, but I'm not sure if that has to do with a non-standard display "he's" using.

    I tested it best I could, and it seemed to work just fine on my UEFI system. When I loaded rEFInd the screen resolution changed to the max supported by the monitor. However that system already loaded the GOP rom. Now I've had a chance to look at my settings in UEFI, I see that I can chose legacy boot for PCI cards, that should load the bios video driver, then I can load rEFInd and see if the GOP driver gets loaded.

    Tho, I'm not real motived to do it if there isn't anyone with a Mac Pro that cares about boot screens for PC video cards, one day, when they are a little cheaper, I'll pickup a cheese grader and get all this stuff working, until then I'd need at least a few bata testers to figure this out.
     

Share This Page

231 November 17, 2017