Jump to content

Lenovo ThinkPad T420 with UEFI Only


K0gen
 Share

5,271 posts in this topic

Recommended Posts

If you were having the IOAHCIBlockStorage timing issue from this: http://www.insanelymac.com/forum/topic/280062-waiting-for-root-device-when-kernel-cache-used-only-with-some-disks-fix/ thread, then the workaround of booting with UseKernelCache=no or -f should have worked. Otherwise, you were having one of the more mundane waiting-for-root-device issues, such as those mentiond in this thread: http://www.insanelymac.com/forum/index.php?showtopic=278075

 

With version 0.4 of my patch-ahci-mlion script, you can specify the kext directory to patch. So patch-ahci-mlion.pl -s /Volumes/whatever/System/Library/Extensions -o osx-release-number to patch some partition other than the one you're running. Or simply run the script with no options to patch the current running os (after booting with the kext cache turned off, as shown above).

 

I kind of doubt you were having the IOAHCIBlockStorage problem. If you were, then everyone with that laptop would be.

 

Maybe you just failed to set your disks to AHCI mode per post #18?

Link to comment
Share on other sites

Thanks Bcc,

 

I was so tired last night, I was up almost till 5am EDT. I actually made more progress and figured a few more things out. So here's my status: 

 

OS X install was successful. I mentioned the extra steps I took including mounting the drive externally to finish the install. Turns out it does boot when the drive is installed internally as was my goal. However it only boots about every other time. This morning I even had to cycle it 3 times before it boots. When it hangs, the console doesn't always stop at exactly the same spot, but after the hang, wait 1 min and it confirms still waiting for root device. Now, on the next boot or maybe the third boot after this, It boots right up. My observation is that it's random. I make absolutely no changes yet one time it'll boot and the second it won't.

 

My next idea is to dump and patch my own dsdt instead of using Gendalo's. Reason being that I've worked with T430's for a long time now and I know that the the 2349 is the (correct) model number for the T430, but the last 3 numbers/letters, 2349XXX correspond to package configuration. It may very well be that Gendalo has totally different hardware from me.

 

I read the second link you provided, but it doesn't apply. To answer your questions:

 

1. I am running in AHCI

2. booting with caches off is not any more effective, though theoretically it's supposed to give more time for the disk to detect.

3. I successfully ran your script, within the functional system, not the pre-installed environment. And it quit without patching. I believe the line goes something like nothing to patch or patch already applied.

 

Wether or not the problem is widespread I don't know. I turn up hardly any results searching for anything T430 and OS X related. So apart from Gendalo and myself, I daresay we're the only ones ever trying this. Or at least the only ones who've documented. When I saw that the issue is intermittent, that's when I got a little upset. I still think it's kext related, but I need to rethink my approach. I've covered a lot of ground in just a few nights, but I didn't envision being a pioneer, I thought someone else will have already done this.

 

I've burned through your suggestions Bcc, but I invite you and everyone else to throw more ideas at me. I'll investigate them thoroughly.

 

My other alternative would include switching to an SSD. Gendalo had success with his, but I was hoping to use the resources I have available rather than spend money on this.

I'm also interested in modding my bios to whitelist. This intel 6205 is amazing, but I can't use it in OSX. Ironically, Lenovo flashed a custom part number on the wlan card so even if I take it out, I can't use it in any other computer anyways. I tried. Under windows, I can download the Microsoft driver or the intel one but the inf's have lines in them that specifically exclude this part number. What a racket. So now I have another project open to modify intel's driver and then self sign it somehow, so I can use it. I'm getting really deep with what little I know, but I need all the help I can get.

Link to comment
Share on other sites

Turns out it does boot when the drive is installed internally as was my goal. However it only boots about every other time. This morning I even had to cycle it 3 times before it boots. When it hangs, the console doesn't always stop at exactly the same spot, but after the hang, wait 1 min and it confirms still waiting for root device.

That is the behavior you'd see with the AHCI driver timing bug. Why don't you try my fix and see if it works for you? It doesn't hurt. Or just upgrade to 10.8.4 and you shouldn't see the problem anymore if it is the AHCI driver timing issue.
Link to comment
Share on other sites

Thanks again Bcc,

 

I did try your script:

 

3. I successfully ran your script, within the functional system, not the pre-installed environment. And it quit without patching. I believe the line goes something like nothing to patch or patch already applied.

 

But I like your suggestion about upgrading. I hadn't thought of that. I will try this next. I will post back with my results.

Link to comment
Share on other sites

So success. Updating to 10.8.4 solved my hit-or-miss booting situation. My Lenovo T430 (2349GCU) Hackintosh is a success.

 

Thanks to bcc9 for providing some much needed assistance in understanding my startup issue. Thanks to Gendalo for his original DSDT and EFI folder. Thanks to the developers of Clover EFI, whom I don't know first-hand, but without whose bootloader I would not have been successful. And of course thanks to all of you in this thread whose discussion on T420's was what originally motivated me to try this on my T430.

 

Also, if it makes you guys feel any better, This thread is the only thread of value on the entire internet that provided the information i needed to get this project off the ground. I'n not joking, I spent days Googling my fingers raw for tangible information on T430's or 420's for that matter before I came accross this little gem.

 

Working: (Tested)

Display

Ethernet

Graphics (QE/CI)

Software Updates

TrackPad (MButton Scrolling) [it's inverted, but I think Mac is this way on purpose]

TrackPoint

WebCam

 

Not Working:

Restart

Sound

WiFi (Buying http://www.monoprice.com/Product/Index?p_id=8072) [At least temporarily]

 

System Specs:

Intel® Core™ i5-3320M (2.60GHz) processor with dual-cores

Intel Turbo Boost 2.0 (3.30GHz), Hyper-Threading, 3MB cache

2 x 4GB PC3-12800 SO-DIMM's

320GB 7.2Krpm SATAII (3Gb/s) Seagate Momentus Thin (7mm) HD

14in 1600x900 HD+ LED-Backlit LCD

Intel® HD 4000 Graphics

Ultrabay enhanced DVDRW/CD-RW rambo drive

Intel® Centrino® Advanced-N 6205 (AGN)

Bluetooth 4.0

Intel® 82579LM 1Gb Ethernet

UltraNav

Secure Chip

Fingerprint reader

720p Front-Facing Wide-Angle Low-Light Camera

6c Li-Ion Battery Rated at 3-5.5 Life-Hours

Mac OS X (10.8.4) / Windows 8 / Ubuntu GNU/Linux

  • Like 1
Link to comment
Share on other sites

Great news.

Not sure about restart issue. where does it hang?
Sound - should be easy to solve with voodoohda or there is alc269 codec applehda.kext available.
Wifi - have to get usb wifi (like the one you selected). it probably is RTL8191 or RTL8192 based. I have 3 of these in various sizes. they work ok.

or get apple-compatible internal wifi express card  - but then this gets a bit more tricky - first you have to replace the card and 2nd you must use a BIOS with WL removed 

Glad to see new things on this thread!

Link to comment
Share on other sites

@okcakep - as artur-pt points out, the lack of KP on the USB boot is probably due to having nullcpupm kext there.

 

are you booting your HD with Clover or Chameleon. either way, on your HD, you will need to make sure you patch AppleIntelCPUPowerManagement. Clover can do it automatically. 

related to this issue, is making sure you have a proper SSDT - are you dropping the SSDT table and having the bootloader generate a proper table? 

 

you did not give any details on what system your are running on, what OS, what boot loader.  as many of us do, please add a signature to help set the context for the problem.

Link to comment
Share on other sites

Dear Expert thanks for your fast answer,

 

@artur-pt thanks...i'll check..

 

@tluck thanks for your answer,

 

This is my step :

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

My system T420 4236CTO

2G RAM

100G HD

VGA Intel 3000 no dual, intel 3000 only

Bios 1.46 version

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

From Kogen Mantis setting BIOS

 

Essential:
Config > Serial ATA (SATA) > SATA Controller Mode Option [AHCI]
Security > Memory Protection > Execution Prevention [Enabled]

Security > Intel ® VT-d Feature [Disabled] ---> i dont have this setting

My other settings:
Security > Security Chip > Security Chip [Disabled]
Startup > UEFI/Legacy Boot [Both]
Startup > UEFI/Legacy Boot Priority [UEFI First]

 

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

From your guide in post #1

1.

- 8GB+ USB pen-drive
- Legal copy of Mountain Lion install app ( 10.8.3 Golden )
- and an app called Lion Disk Maker
- my custom Clover Package: zip.gif  Clover_v2_r1625k0.pkg.zip 

- Till Making install media bootable on your ThinkPad

- Im replace EFI on pen-drive with T420-EFI-Clover-b1972

- Success, pen-drive ready for the boot

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

After that

2.

- Boot from pen-drive -succes with lenovo logo, lion logo

- Format HD with GUID partition ( 2 partition - LION & DATA )

- Install Mountain Lion to -> LION Partition

- +_ 10 minute done

- Reboot

- Chose Mountain Lion from

- No Luck !!!

- Hard shutdown !!! with press shutdown button more than 5 time !!! :)

- Try boot with NoCaches, PCIRootUID=1/0, GraphicsEnabler=No/Yes, npci=0x3000/2000 no luck..!!!

- Hard shutdown, unplug power ( cable & battery ) wait 5 minute

- Luck...can boot to Installation process...:)

What the problem in this part ?????? pls help...

- Installation process +_ 20 minute, chose country, keybord, etc

- Yess...ML 10.8.3 on display

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

Step make booting from HD

3.

-Using - Clover Package: zip.gif  Clover_v2_r1625k0.pkg.zip

-Install clover on LION partition

-Mounting EFI,

 - mkdir /Volumes/efi

 - mount -t /dev/disk0s1 /Volumes/efi

-Replace CLOVER in /EFI/CLOVER directory with packet CLOVER in T420-EFI-Clover-b1972

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

Customize

4.

-Rename on directory OEM with 4236CTO

-Install dsdt.aml ( from Kogen Mantis ) on EFI/OEM/4236CTO/ACPI/patched/

-Using KextWizard install package from 1. Download Extra Folder: zip.gif  Extra.zip  post #1

-Reboot

 

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

No Luck !!! :D

5.

-No Luck boot from HD with anything parameter :)

-Luck boot from Pen-Drive with parameter NoCaches

-But glitch still appear

-No sound -->> Kogen Mantis patch post #22

 

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

 

I hope can solve :)

 

Thank you...

 

 

Link to comment
Share on other sites

@okcakep

 

the T420-EFI-Clover zip file should have everything you need to get up and running - custom kexts matching the included newer dsdt.aml.  you wont need to install kogens package or extra zip files.

i had some problems with kogens dsdt when i tested it at one point (audio issues primarily)

 

you should be able to get running with slight modification in your steps 3 and 4 above. reread my post (closely at bottom) -            #241             it has some instructions on how to install/replace your ESP (/Volumes/EFI) entirely /EFI/Boot /EFI/Clover (need both inititially) - instead of using the older 1625 version kogen packaged up.

 

without the OEM folder matching,  this should allow you to boot up using a totally vanilla OSX. (not everything works of course). But from there, then you can complete the customization - install/replace the kexts in the zip 10.8-SLE into your /S/L/E directory. (i have all the kexts in /EFI zip kext folder in my /S/L/E.)

then you can rename the 4236AT9 and make any mods to match your CPU and display -  1600x900 vs low-res. 

 

do you have 2.5Ghz i5 CPU? if not, you need modify the config.plist CPU section to match in the OEM folder.

Link to comment
Share on other sites

10.8.5 ok here.

 

Install, before reboot, put kexts in SLE

repair

reboot

 

 

to update config

in the OS start the Terminal and enter:

/usr/local/bin/clover-genconfig >config.plist
 
new config structure config is required 
not so easy to update
here is mine
Link to comment
Share on other sites

 

10.8.5 ok here

 

 

to update config

in the OS start the Terminal and enter:

/usr/local/bin/clover-genconfig >config.plist
 
new config structure config is required 
not so easy to update
 
config configurator doesn't allow to import config.plist to customize it

 

Hi Tetonne-

Any special instructions to upgrade to 10.8.5? Did you have to restore any of the custom kexts?

 

Thanks,

AJ

Link to comment
Share on other sites

T420 users. 

 

2 quick things .... and will update a final/new 10.8.5 zip using clover 2082 later on when I get it stabilized.

 

1) 10.8.5 Update: took awhile but building a successful 10.8.5 installer was not obvious! (vs using the combo update process).  There is an issue with BlueTooth that kept hanging me up. In the end, i was successful in making a Clover UEFI ML Disk tool (Lion Disk Maker) installer for 10.8.5 as well as a "you-nibeest" MBR installer. essentially I had to disable BT in the BIOS to get these to work. Then later on reenable BT and then I had to edit the BT kext (which seems to change in 10.8.5)

/System/Library/Extensions/IOBluetoothFamily.kext/Contents/PlugIns/BroadcomBluetoothHostControllerUSBTransport.kext/Info.plist - change 8532 to 8575. 

 

2) Clover 2082 Update: quite a bit changed in the layout of the config.plist structures, so i will repost with this version soon too! They moved and expanded some of the variable structures. i still seem to need to need a custom ssdt.aml but it does a lot better job on figuring out the CPU and and bus speeds automatically. i now get SpeedSteps 31x and 32x! (dont recall those from before).

 

Bottom line. 10.8.5 does replace a few of the custom kexts so be prepared to replace them. I will look at patching up the AppleHDA for 10.8.5 as well. but for a quick fix, rollback works.

  • Like 2
Link to comment
Share on other sites

Tluck,

 

I'm interested in testing both the 10.8.5 update and the Clover update on my T430. So It you have something I can test, please let me know. I tried using a plain install of the new Clover but was unable to boot with my current config. I haven't applied the 10.8.5 update either. I don't have any custom kexts loaded in OSX so I don't think that the update will break it, but how does it affect the custom kexts I load through clover? I'm still figuring out clover.


Great news.

Not sure about restart issue. where does it hang?
Sound - should be easy to solve with voodoohda or there is alc269 codec applehda.kext available.
Wifi - have to get usb wifi (like the one you selected). it probably is RTL8191 or RTL8192 based. I have 3 of these in various sizes. they work ok.

or get apple-compatible internal wifi express card  - but then this gets a bit more tricky - first you have to replace the card and 2nd you must use a BIOS with WL removed 

Glad to see new things on this thread!

Also @Tluck

 

It hangs after the system unloads. the console outputs all of the kill messages and then the console itself unloads, but then it hangs at the black. Backlight's still on, and the fan's running but I assume that the system is down at that point. I remember someone mentioning something about this earlier in the thread, but it might have been related to a different machine. How would I log the events at the end of system life? I'm sure there is some additional output after the display output unloads but before the full system shutdown. I have no experience in system shutdown process. I'm operating on the assumption that it's opposite of the boot process.

Link to comment
Share on other sites

It hangs after the system unloads. the console outputs all of the kill messages and then the console itself unloads, but then it hangs at the black. Backlight's still on, and the fan's running but I assume that the system is down at that point. I remember someone mentioning something about this earlier in the thread, but it might have been related to a different machine. How would I log the events at the end of system life? I'm sure there is some additional output after the display output unloads but before the full system shutdown. I have no experience in system shutdown process. I'm operating on the assumption that it's opposite of the boot process.

It's a bug with UEFI firmware (Tiano) that only happens when booting UEFI Clover. The bug is as old as the option to boot UEFI Clover (dating all the way back to June 2012). There wasn't any solution to this problem and more and more people (even on desktop machines) are getting this issue. One of the developers (apianti) has promised to look into the issue, but without logs and memmap dumps (DarwinDumper) from both CloverEFI and UEFI Clover from same machine there is no way it can be solved. Developers need debug material to work with (this is how immediate restart after sleep issue on AMI Aptio was solved on desktop boards).

Link to comment
Share on other sites

Thanks TimeWalker,

 

I wish people were this helpful offline as well  :lol:

 

Now pardon my ignorance:

What is the difference between CloverEFI and UEFI Clover? I was not aware of the distinction. Are you referring to Clover being able to boot in both EFI mode and legacy mode? Or am I way off the mark here?

 

Sorry in advance...


@All

 

I've noticed significant differences between UEFI vendors. I am wondering if others have had similar encounters. The UEFI on my ASUS K55A allows me to directly boot from any fat32 partition where it finds /boot/EFI/bootx64.efi or /EFI/bootx64.efi Boot sectors are not required at all. I first noticed this when I converted a Win8 install from MBR with BIOS boot to GPT with UEFI boot. It was super simple and didn't require copying boot sectors. I can also add UEFI boot options to my Boot menu as I want. I can actually install multiple bootx64.efi's in the same partition and create a separate Boot option for each one. I thought this was pretty cool. However, on my T430 which presumably is more advanced, has no such options.

 

Any thoughts?

Link to comment
Share on other sites

@bryan G - 

 

CloverEFI means essentially booting by MBR to the Clover GUI vs using UEFI directly to bring up the Clover GUI

 

 

(BIOS MBR -> boot0->boot1->boot->CloverX64.efi) versus

 direct UEFI (UEFI -> CloverX64.efi). 

 

on the laptop, if i select a GPT disk to boot, it will scan the ESP partition and look for /EFI/Boot/bootx64.efi - which is exactly the same thing as /EFI/CLOVER/Cloverx86.efi. 

however, if i select boot from a MBR formatted disk, then it will look in the MBR for boot0. 

Link to comment
Share on other sites

Updated 8-Oct-2013 - This old and pretty out of date -  moved on to Mavericks and Yosemite (10.9 and later) here Clover UEFI on T420 Guide

 

Attached is a current full /EFI pack for T420 on Clover and OSX 10.8.5 (12F45)

 

see instructions from post 486

 

Update 4-Oct-2013

  • Revised DSDT
    • for Shutdown hang (thanks to TimeWalker75a)
    • for native ACPIPlatform kext - no need to rollback or patch AppleACPIPlatform.kext - can use unmodified v1.8 from 10.8.5 (see notes below).
    • made a change/fix to reset LEDs upon wakeup.
  • Updated Clover to b2165 b2184
  • Updated AppleIntelE1000e.kext
  • Updated FakeSMC
  • Updated VoodooPS2Controller
  • Added Patched AICPUPM kext for Chameleon compatibility.

Attached is a current full /EFI pack for T420 on Clover and OSX 10.8.5 (12F45)

  • Updated config.plist for Clover 2k
  • OEM 4236AT9 is for 1600x900 i5-2520M (with ssdt.aml)
  • OEM 4236Y33 is for 1366x768 
  • Removed CPU sections from the config.plist (as Clover compute Bus Speed ok now - check it though! should be around 99676 - 99700 
  • Kext Bundle for 10.8.4 is post #241

ACPI Notes:

  • the new DSDT conforms (more) to the native unmodified kexts ACPI spec... so dont have to replace the AppleACPIPlatform.kext. 
  • native AppleACPIPlatform.kext v1.8 (10.8.5)  some issues with Power button lights after wake. - fixed with new DSDT.
  • native AppleACPIPlatform.kext v1.7 (10.8.4) works but does not wake as well when you have external eSATA/USB drives. 

Notes:

there are 2 kext folders 

10.8 (which are good for vanilla boot) before using OEM folder and/or modified kexts are in place.

  • FakeSMC.kext (v5.2.877) - Kozlek's core hack mechanism + plugins - Note: Follow link to download full package - so you can install HWMonitor.app etc (just select Plugins ACPI and CPU)
  • VoodooPS2Controller.kext (v1.8.8) - RehabMans's PS2 Keyboad/Trackpad -   Note: Follow link to get full package and installation instructions to install daemon may still be subject to random sleep/wake issues... versions 1.8.5+ are proving to be more reliable.
  • AppleIntelE1000e.kext (v2.5.4) - gigE - goes in /System/Library/Extensions/IONetworkingFamily.kext/Contents/PlugIns

10.8-SLE which can be combined with above and will replace your /S/L/E versions.

  • AppleHDA.kext (v2.4.7 patched from 10.8.5)- for full audio support - note: requires matching DSDT sections using Conexant Codec and layoutID 12.
  • AppleACPIPlatform.kext (v1.7) - upgraded to ErmaC's Patched ML kext for sleep/wake + battery
  • ACPIBatteryManager.kext (v1.40) VoodooBattery.kext - Rehabman's kext configured for v3 ACPI per his instructions to show/track battery info on menu bar - requires rollback AppleACPIPlatform.kext
  • BroadcomBluetoothHostControllerUSBTransport.kext (v4.1.7 with patched Info.plist from 10.8.5) - adds ProductID 8575 to make BT work! Put/replace one in /S/L/E/IOBluetoothFamily.kext/Contents/PlugIns
  • IOAHCIBlockStorageInjector.kext -  makes DVD an internal device so iDVD player works. 

​10.8-Chameleon - extra patched kexts for use with Chameleon 

  • AppleIntelCPUPM.kext (patched v214.0.0 from 10.8.5) - not really necessary to install/replace with clover since it does the patching. Optional Install in /S/L/E for Chameleon compatibility.

 

The DSDT (in OEM) has some new mods in the IGPU are that seem to remove glitches/hangs on either Clover or Chameleon - go figure?! And there is generic/low-res dsdt for non-1600x900 users to try.

 

Basic instructions and notes:

  1. install vanilla 10.8.5 to GUID formated disk - use USB or other method
    1. You can use this zip to build a clover based USB built by Lion Disk Maker - or other method create an Installer
    2. Note: you may need to disable BlueTooth in the BIOS to install 10.8.5 directly. Enable later when you boot up.
  2. install standard Clover into ESP - use link to download from sourceforge.
  3. mount ESP on /Volumes/ESP and replace /Volume/ESP/EFI with contents in zip
  4. boot up vanilla 10.8.5 with clover - this will use the kexts and "top" level config.plist (rename OEM to OEM.NU for now)
  5. now install kexts from ESP or zip to boot drive into /S/L/E (from /EFI/CLOVER/kexts/10.8 and 10.8-SLE) or use myhack method. see notes above
  6. here is the tricky part - fix OEM folder to match your system 
  7. DO NOT just hastily rename the folder OEM to match your productID -  you may need to modify some things to make it compatible with your specific model details.
    • If you have 1600x900 LCD, you can probably just use items as is - that is rename 4236AT9 to match your product name.
    • If you have 1366x768 LCD, you can probably just use items as is - that is rename 4236Y33 to match your product name.  Note: if you have similar CPU as i5-2520, the SSDT.aml from 4236AT9 may work for you (copy from 4326AT9/ACPI/patched)

Update: There is just a slight differences between these 2 config.plist files now - really just about the LCD resolution and EDID injection for high-res.

T420_UEFI-Clover-b3025_10.8.5.zip

Edited by tluck
  • Like 2
Link to comment
Share on other sites

Thanks, so far everything T420 related has been useful in figuring out T430 stuff. So anything I can use from you guys is always helpful.

 

Also, I believe that I've just confirmed that Gendalo's and my DSDT's are identical. Unless I did something wrong: I dumped my DSDT.aml using Clover. I decompiled it and Gendalo's with a DSDT utility, and then made plain text's from them so I could plug them in to a text file comparator and they came up equal. So, unless I did something wrong, for which there is lately a large possibility, I think they are the same. Both of our machines are 2349XXX so is it likely that they would share the same DSDT?

Link to comment
Share on other sites

@Bryan - good to know! generally the dsdt will be similar on each model. each BIOS update may tweak minor stuff.

 

Note: the source dsdt.dsl from the T420 is in the zip - marked with comments (look for tjl )

 

yeah I too used Clover and its capability to patch the DSDT. I booted up without my custom DSDT using fixmask 0xFFFF and extracted the DSDT using EVO DSDT. then hand edited/retrofitted some other fixes from other folks. many of the edits/fixes etc in the T420 dsdt should apply.

 

The zip is back on the post above.

Link to comment
Share on other sites

 Share

×
×
  • Create New...