Contribute
Register

[Guide] Lenovo Y50 (UHD or 1080p) using Clover UEFI

Status
Not open for further replies.

RehabMan

Moderator
Joined
May 2, 2012
Messages
181,058
Motherboard
Intel DH67BL
CPU
i7-2600K
Graphics
HD 3000
Mac
  1. MacBook Air
Mobile Phone
  1. iOS
Overview

The purpose of this guide is to provide a step-by-step guide to installing Mojave, High Sierra, Sierra, El Capitan, or Yosemite on the Lenovo Y50-70 laptops. Please note I do not have this laptop, but this guide was created through my work helping others at the original guide thread. Since that thread is not well maintained and there are several problems with it, I decided to provide this guide.

Original guide thread here: http://www.tonymacx86.com/yosemite-laptop-guides/153390-guide-lenovo-y50-clover.html

Both laptops with 1080p and UHD displays are supported by this guide.

Note: This guide will probably also work with Mavericks.


What you need

- Lenovo Y50-70 (or Y70) with either 1080p or UHD/4K display
- macOS or OS X downloaded from the Mac App Store
- 8GB USB stick
- (optional) 32GB USB stick for Lenovo OEM backup
- Broadcom BCM94352Z for native WiFi (Lenovo FRU: 04X6020, Lenovo PN: 20-200480)


BIOS settings

To start, set BIOS to Windows 8 defaults.

Then insure:
- UEFI boot is enabled
- secure boot is disabled
- enable Legacy Boot (but UEFI first) and you may experience less boot time glitches

For the UHD model, the DVMT-prealloc BIOS setting must be changed to 128MB. One of two methods can be used:
- use a EFI shell to change the DVMT-prealloc from the shell.
- use a patched BIOS which unlocks the advanced menu

** Note: Those with the UHD model and who have used the UEFI shell method to set DVMT-prealloc, please reply to this thread with clear details (eg. setup_var variable offset and value). Since each laptop is likely the same, the information can be added to post #1 here after a few people confirm the same values on different Y50 laptops.

Note: It has been reported that BIOS version 1.14 or *older* must be used in order to set DVTM-prealloc via UEFI shell. Details here: http://www.tonymacx86.com/threads/g...using-clover-uefi.165188/page-19#post-1050617

BIOS link: http://www.tonymacx86.com/threads/g...lover-uefi-10-11.168612/page-104#post-1184979

BIOS images are specific to each laptop (Windows license keys), so a custom BIOS must be made by someone knowledgeable from a backup of your own BIOS. Sites such as bios-mods.com specialize in this.

But you can also use a UEFI shell to adjust the DVMT-prealloc and avoid using a patched BIOS. Lately this is commonly done on Broadwell machines. Check at the links from the FAQ: http://www.tonymacx86.com/el-capita...faq-read-first-laptop-frequent-questions.html. Look at question "Is Intel Broadwell graphics supported?". There are a number links there with a few different guides that explain how to extract BIOS, search for the variable, and set it with a special UEFI shell (based on grub). Since all Y50 laptops are likely to use the same variable offset, please post the details in this thread, so that this post can be updated.

Note: There are at least two posts in this thread stating the offset. One is this example:
FYI, my offset for the DMVT change was 0x18C

setup_var 0x18C 0x4

Whereas the HD5500 guide said to look under the Setup section, I found the settings in the SetupUtility section of the bios file.

The 0x18C and value 0x4 also corresponds with another report in this same thread.

If you own the laptop, please help with any additional required BIOS settings that may be required.

Note: The DSDT/SSDT patching script will automatically disable the discrete nVidia card if you have it enabled in BIOS. It is best, therefore to keep it enabled in BIOS so you can still use it on Windows, but have DSDT/SSDT patched properly for OS X.


Issue with booting UEFI-Shell USB for DVMT-prealloc

When booting from the USB, an error may be thrown by the BIOS stating the following: EFI USB Device <USB name> has been blocked by the current security policy. This issue is due to Secure Boot being enabled and it must be disabled to continue booting from the USB stick.

In order to disable Secure Boot:
From a powered off state press the NOVO button (to the left of the power button on the Y50-70) and select 'BIOS SETUP'. Navigate to the 'Security Tab' and at the bottom of that window select 'Reset to Setup Mode' to fully disable the Secure Boot. Once done, Navigate to the 'Exit' tab and select 'Exit Saving Changes'. You should now be able to boot from the USB stick.

There is an issue with BIOS v1.09 (may impact other versions as well) where no matter how you set Secure Boot it will not disable and you cannot get passed the 'EFI USB Device <USB name> has been blocked by the current security policy.' message... meaning you cannot boot from UEFI Shell. If you have this issue for any BIOS version under v1.14, upgrade to v1.14 but NOT ABOVE.. it has been reported that a BIOS version above 1.14 has the area encrypted that needs to be modified modify the DVMT. After upgrading the BIOS to v1.14 follow the above steps to disable Secure Boot.


Preparing USB and initial Installation

Prior to installing OS X, it is a good idea to create an OEM recovery USB from Windows. If anything goes wrong and you want/need to get back to Windows, you can restore it via the USB. Use the utility provided by Lenovo to accomplish this.

You can also leave Windows intact, but it can get tricky. Read here for more information: http://www.tonymacx86.com/multi-booting/133940-mavericks-windows-8-same-drive-without-erasing.html

This guide for creating USB and installing using Clover UEFI works well for this laptop: http://www.tonymacx86.com/el-capita...de-booting-os-x-installer-laptops-clover.html

Special notes:

- Use the latest RehabMan build of Clover

- Definitely copy RealtekRTL8111.kext to Clover/kexts/Other as having network support during post-install is helpful. The rest of this guide depends on it. An alternate is to AirportBrcmFixup.kext. This will enable WiFi, provided you have the BCM94352 WiFi card already installed.

- GenericUSBXHCI.kext is not necessary with this laptop. Do not use it.

- Use the 'createinstallmedia' approach. It works well, and there is little chance for pilot error. This method also gives you an OS X recovery partition.

- If your laptop has the UHD/4K screen, set config.plist/Graphics/ig-platform-id=0x12345678 for installation.

- Also copy USBXHCI_y50.kext to EFI/Clover/kexts/Other. You can get USBXHCI_y50.kext from the repo ZIP: https://github.com/RehabMan/Lenovo-Y50-DSDT-Patch/archive/master.zip


Post Installation

Install Clover UEFI as described in the guide linked by the previous section (post #2). After installing Clover, and configuring it correctly (config.plist, kexts, etc) you should be able to boot from the HDD/SSD.

But there are still many issues and devices that won't work correctly. For that, we need to patch ACPI, provide a proper config.plist, and install the kexts that are required.

Note: If you have the UHD screen you'll still need config.plist/Graphics/ig-platform-id=0x12345678 until all post-install tasks are complete.

Since you have RealtekRTL8111.kext already injected by Clover, you should have internet access simply by using an Ethernet cable to your router. Plug it in and make sure you have internet access before continuing. Or if you're using AirportBrcmFixup.kext, you can connect to your WiFi router before continuing.

Installation of the tools and patching is easy provided the scripts and tools at the repository: https://github.com/RehabMan/Lenovo-Y50-DSDT-Patch

To start, the developer tools must be installed. Run Terminal, and type:

Code:
xcode-select --install

You will be prompted to install the developer tools. Since you have internet working, you can choose to have it download and install them automatically. Do that before continuing.

After the developer tools are installed, we need to get a couple of projects from my github.

In Terminal:
Code:
mkdir ~/Projects
cd ~/Projects
git clone https://github.com/RehabMan/Lenovo-Y50-DSDT-Patch y50.git

Now it is time to install some more tools and all the kexts that are required...

In Terminal:
Code:
cd ~/Projects/y50.git
./download.sh
./install_downloads.sh

The download.sh script will automatically gather the latest version of all tools (patchmatic, iasl, MaciASL) and all the kexts (FakeSMC.kext, ACPIBatteryManager.kext, etc) from bitbucket. The install_downloads.sh will automatically install them to the proper locations.

Note: This guide is written assuming a Synaptics trackpad is installed. According to some of the feedback in this thread, some of these laptops come with an ELAN trackpad instead. I'm not going to link the ELAN trackpad, due to the author's disregard for the open source license, but you can find it on the internet. You will lose some of the keyboard functionality (eg. function keys) present in the Synaptics setup, although the brightness keys should be working (special patch in patches/keyboard.txt)

If you wish, you can reboot to verify a few more items are working (many only partially).

To finish the setup, we need a correctly patched DSDT/SSDT.

With the current project, no patched DSDT/SSDTs are used. Instead, Clover hotpatches and a small SSDT called SSDT-HACK are used instead.

In Terminal:
Code:
cd ~/Projects/y50.git
make
make install

The 'make' causes the SSDT-HACK.aml files to be compiled (with iasl), the results placed in ./build.

Finally, 'make install', mounts the EFI partition, and copies the built files where they can be loaded by Clover (to EFI/Clover/ACPI/patched).


Power Management

Everything required for CPU/IGPU power management is already installed with the steps above.
There is no longer any need to use the ssdtPRgen.sh script.

Also, be aware that hibernation (suspend to disk or S4 sleep) is not supported on hackintosh.

You should disable it:
Code:
sudo pmset -a hibernatemode 0
sudo rm /var/vm/sleepimage
sudo mkdir /var/vm/sleepimage

Always check your hibernatemode after updates and disable it. System updates tend to re-enable it, although the trick above (making sleepimage a directory) tends to help.


Patching the IOKit (or CoreDisplay) framework

If you have the UHD/4K display, you must defeat the IOKit/CoreDisplay framework pixel clock checks.

In the latest release of this guide, download.sh and install_downloads.sh installs WhateverGreen.kext (-cdfon, as provided in config_UHD.plist, enables the CoreDisplay patch) in order to accomplish this patch. As a result, no need to do this manually as was required in previous versions of this guide.


Final config.plist

Up to now, you've been using the same config.plist we were using for installation. After all the APCI files are in place, you're ready to use the final config.plist from the repo.

First, mount the EFI partition:
Code:
cd ~/Projects/y50.git
./mount_efi.sh

If you have the 1080p screen, use config.plist:
Code:
cd ~/Projects/y50.git
cp config.plist /Volumes/EFI/EFI/Clover/config.plist

If you have the UHD/4k screen, use config_UHD.plist:
Code:
cd ~/Projects/y50.git
cp config_UHD.plist /Volumes/EFI/EFI/Clover/config.plist

You could also copy the file using Finder.

After copying the config.plist from the repo to EFI/Clover/config.plist, you should customize the SMBIOS so you have a unique serial. You can use Clover Configurator to do this (use google to find/download it). DO NOT use Clover Configurator to edit your actual config.plist. Instead edit a "dummy" config.plist to create the SMBIOS data and then use copy/paste with a plist editor (I use Xcode) to copy the SMBIOS section into my active config.plist. Clover Configurator is too buggy and cannot be trusted with edits to your real config.plist. This guide uses MacBookPro11,1. Do not use any other model identifier.

Repeat: DO NOT edit your config.plist with Clover Configurator. Clover Configurator will erase important settings from the config.plist, and as a result, it will not work.

Do not stop reading

Although most of the post-install tasks are done, continue to read this guide. It it has important information you should know about.

In the case of a problem, don't bother asking about with without all files requested in "Problem Reporting".


Updates to the patch repositories

From time to time, updates may become available to the project repository. In the event of such updates, you may want to update your copies, and re-patch DSDT/SSDT with the updates.

Since you're using git, it is easy...

In Terminal:
Code:
cd ~/Projects/y50.git
git pull
./download.sh
./install_downloads.sh
make
make install


What works

Expect to work:
- UEFI booting via Clover
- built-in keyboard (with brightness keys)
- built-in trackpad (basic gestures)
- HDMI video/audio with hotplug (please verify, the patches came from the u430 repo and may need tweaking)
- AirPlay mirroring to AppleTV
- native WiFi via BCM94352Z
- Bluetooth (with handoff) using BCM94352Z
- native USB3 with AppleUSBXHCI (USB2 works also)
- native audio with AppleHDA (using injector for easy updates), including headphone
- built-in mic
- built-in camera
- native power management
- battery status
- backlight controls with smooth transitions, save/restore across restart
- accelerated graphics for HD4600 including OpenCL
- wired Ethernet
- Mac App Store working
- retina scaling (in the case of UHD screen)

Not tested/not working

The following features have issues, or have not been tested:
- Messages/FaceTime (not tested, see guide: http://www.tonymacx86.com/general-help/110471-how-fix-imessage.html)
- some special Fkeys not working (??)
- card reader is not working


Known Problems

Find My Mac/Locking: Find My Mac does not work properly. Don't lock your mac because it's difficult (or impossible) to unlock again.

Slow WiFi after sleep/wake cycle: Disable "Wake for network access" in SysPrefs->Energy Saver.

Audio: External mic via combo headphone/mic jack is not working.

Black screen after wake (UHD only): Some owners of the UHD model report that on wake from sleep, the screen comes on for a second, only to turn black. Most users seem to not have this problem. No known solution. If you find a solution, please reply here.

Screen flicker (FHD only): Some owners of the FHD model report that the there is flickering on the screen when legacy boot is enabled (still booting UEFI). This can be avoided by disabling legacy boot in BIOS, but the flicker returns after wake from sleep. No known solution. If you find a solution, please reply here.


System Updates

Before doing an update, it is important to have all components up-to-date as there may be changes required to kexts, ACPI, config.plist, Clover, etc to handle the new update.

First step should be to update to the latest repository.

To do so:
Code:
cd ~/Projects/y50.git
git stash
git pull
./download.sh
./install_downloads.sh
make
make install

Also update Clover to the latest using the Clover installer. Be sure to fix EFI/Clover/kexts, so that only EFI/Clover/kexts/Other is existing. All version specific directories under EFI/Clover/kexts should be removed.

Also update config.plist at EFI/Clover/config.plist to the latest content from the repo. Be sure to retain your own SMBIOS data at config.plist/SMBIOS.

Now you can update via the App Store. Just boot the installer/updater upon restart.

After updating, run ./install_downloads.sh again:
Code:
cd ~/Projects/y50.git
./install_downloads.sh


Other post-install tasks

Trackpad: Be sure to visit the options in SysPrefs->Trackpad and change them to your liking.

Trackpad three finger support: You can configure three finger swipes in SysPrefs->Keyboard->Shortcuts. Instead of pressing keys for a given function, do the three finger swipe (up/down/left/right).

Disable trackpad when using an external mouse: It allows you to disable the built-in trackpad when a USB mouse is plugged in. Just check the box in SysPrefs->Accessibility->"Mouse & Trackpad".

Bluetooth: If you get the Bluetooth Setup Assistant popup, go to SysPrefs->Bluetooth->Advanced, uncheck the boxes.


Keyboard Mapping

The mapping for Control, Option, and Command are according to the physical layout of the keys on an actual MacBook keyboard, not the labels on the keys. Control=Control, Windows=Option, and Alt=Command. If you want a more PC friendly keyboard layout, use Karabiner (formerly KeyRemap4MacBook).

Brightness up/down are implemented with DSDT patches and my VoodooPS2Controller. Mirror Toggle is not currently implemented.

The function of Fn+F1..F12 and F1..F12 can be changed in SysPrefs->Keyboard (actually, not currently implemented, but is possible).


Major updates

First step should be to update to the latest repository.

To do so:
Code:
cd ~/Projects/y50.git
git stash
git pull
make
make install
./download.sh
./install_downloads.sh

Also update Clover to the latest using the Clover installer. Be sure to fix EFI/Clover/kexts, so that only EFI/Clover/kexts/Other is existing. All version specific directories under EFI/Clover/kexts should be removed.

Also update config.plist at EFI/Clover/config.plist to the latest content from the repo. Be sure to retain your own SMBIOS data at config.plist/SMBIOS.

Now you can update via the App Store. Just boot the installer/updater upon restart.

After updating, run ./install_downloads.sh again:
Code:
cd ~/Projects/y50.git
./install_downloads.sh


Updating to High Sierra

As you probably already know, High Sierra has a new file system called APFS. Boot drives on SSDs will automatically be converted to APFS if you start the High Sierra installer in the default way (eg. running /Applications/Install macOS High Sierra.app).

If you intend to use APFS, don't forget to add apfs.efi to EFI/CLOVER/drivers64UEFI. Without apfs.efi in drivers64UEFI, Clover will not recognize APFS boot volumes. You can find apfs.efi at /usr/standalone/i386/apfs.efi inside of "/Applications/Install macOS High Sierra.app/Contents/SharedSupport/BaseBinaries.dmg".

But you can avoid converting to APFS if you want to stick with HFS+. To so so, don't use the Install macOS High Sierra.app to start the installer. Use 'startosinstall' instead:
Code:
/Applications/"Install macOS High Sierra.app"/Contents/Resources/startosinstall --converttoapfs NO


Problem reporting

Problem reports should be accompanied by various files that allow your progress to be accounted for...

Read FAQ, "Problem Reporting". Carefully. Attach all requested files/output.
https://www.tonymacx86.com/threads/faq-read-first-laptop-frequent-questions.164990/
Use the gen_debug.sh tool mentioned in the FAQ, that way it is less likely you'll omit something.
 
Hey RehabMan. I did a clean install of following the guide. Everything works except the bluetooth and the USB ports. Only one works. Attaching the IORegistryExplorer and the debug files. Please let me know if you can help me out.
 

Attachments

  • ioreg.ioreg
    7.3 MB · Views: 523
  • debug_18951.zip
    2.4 MB · Views: 313
Hey RehabMan. I did a clean install of following the guide. Everything works except the bluetooth and the USB ports. Only one works. Attaching the IORegistryExplorer and the debug files. Please let me know if you can help me out.

You did not follow the guide. You have no files in ACPI/patched, indicating you didn't do 'make install'.
Read post #1.

Note: You should delete drivers64UEFI/apfs.efi. It is not needed/wrong with ApfsDriverLoader-64.efi+AppleImageLoader-64.efi.
 
This is what I get when I execute that command

Rahuls-MacBook-Pro:y50.git $ make

make: Nothing to be done for `all'.

Rahuls-MacBook-Pro:y50.git $ make install

make: *** No rule to make target `install'. Stop.
 
This is what I get when I execute that command

Rahuls-MacBook-Pro:y50.git $ make

make: Nothing to be done for `all'.

Rahuls-MacBook-Pro:y50.git $ make install

make: *** No rule to make target `install'. Stop.

Try with latest github content.
 
Sweet. Looks like whatever change you made in the GitHub fixed the issue. Thank you RehabMan
 
Hi!

I have installed a fresh Mojave following the instructions (hope I didn't make a mistake). During the installation I have noticed that there was some problem with the scripts that are used for after install configurations (attached: cp_problem.txt). I believe the problem is that there is a space in the name of my EFI partition "NO NAME". I have tried to correct the problem by manually coping over the files.

I have also seen that it is recommended to disable legacy boot on FullHD systems to get rid of the black blinking screen issue. After making the changes in the BIOS and booting Mojave the internal display becomes garbled and unreadable (photo and screenshot attached), but the external HDMI-to-DVI monitor is still perfectly usable. If I re-enable legacy booting the display is usable again.

Thanks for the great support!
 

Attachments

  • debug_10242.zip
    8.1 MB · Views: 432
Hi!

I have installed a fresh Mojave following the instructions (hope I didn't make a mistake). During the installation I have noticed that there was some problem with the scripts that are used for after install configurations (attached: cp_problem.txt). I believe the problem is that there is a space in the name of my EFI partition "NO NAME". I have tried to correct the problem by manually coping over the files.

I have also seen that it is recommended to disable legacy boot on FullHD systems to get rid of the black blinking screen issue. After making the changes in the BIOS and booting Mojave the internal display becomes garbled and unreadable (photo and screenshot attached), but the external HDMI-to-DVI monitor is still perfectly usable. If I re-enable legacy booting the display is usable again.

Thanks for the great support!

As per guide, you should have repartitioned the target drive with macOS Disk Utility.
In that case, the EFI will be mounted at /Volumes/EFI.

BIOS settings are clearly stated in post #1... And, as is written there, legacy boot/CSM must be enabled.
 
As per guide, you should have repartitioned the target drive with macOS Disk Utility.
In that case, the EFI will be mounted at /Volumes/EFI.

BIOS settings are clearly stated in post #1... And, as is written there, legacy boot/CSM must be enabled.

I have changed the name of the EFI partition to EFI and the scripts are working.

Screen flicker (FHD only): Some owners of the FHD model report that the there is flickering on the screen when legacy boot is enabled (still booting UEFI). This can be avoided by disabling legacy boot in BIOS, but the flicker returns after wake from sleep. No known solution. If you find a solution, please reply here.

I was referring to this section, but then I will just have to re-enable legacy boot and ignore the blinking.

Thanks
 
Status
Not open for further replies.
Back
Top