jloisel / t440p

Thinkpad T440p Hackintosh (macOS Mojave 10.14.x / Catalina 10.15.x) - Clover config.plist + kexts
244 stars 57 forks source link

Supports for dock USB ports, SD card reader from inherited codes #43

Closed rsuzuki0 closed 4 years ago

rsuzuki0 commented 4 years ago

notthebee says on his page his codes include "Special config.plist for USBInjectAll to support docking station USB ports" and also point to your page as more up-to-date. I wonder if his work is incorporated to your version. As of now, I don't seem to have any of the dock USB port active using your code set. (Additionally, docking station audio port would be very nice.) I tried to overwrite parts of your set with his codes but didn't work.

Also, Sniki/Lenovo-Thinkpad-T440P has Card Reader.zip in his kext folder. This ZIP expands to Sinetek-rtsx.kext from march 2019. I wonder if SD card reader issue is resolved. My laptop seems to have a reader that's different from what you described.

I have resolved this by modifying the SSDT used for USB port injection. Since the card reader did not appear as an obvious entry in System Report > Hardware > USB, I was wondering if it appeared at a port that I did not inject. To check this, I removed my compiled SSDT-UIAC.aml file from /Volumes/EFI/Clover/ACPI/patched and restarted. This results in all of the HSxx ports being injected and none of the SSxx ports being injected because the port limit is reached.

After restart, a Mass Storage Device appears at port HS12, which was not being injected in my SSDT. This appears in System Report > Hardware > USB as a "Mass Storage Device" (not USB 2.0-CRW). If I insert an SD card to the card reader, it appears at HS12, and also on the desktop, and in finder. I am able to access files on the card, so it appears to be working properly.

It didn't occur to me to use the card reader when I was doing the port identification step in creating the custom SSDT and so the relevant USB port didn't get injected. It turns out that I don't need to customize AppleStorageDriver.kext using the steps outlined in this guide. The card reader works with the default AppleStorageDriver.kext as long as the correct port has been injected.

I have only tested SD memory cards as I can't find any other kind of card here. I will see if I can get a few different ones to test. I would assume that all inserted cards appear at HS12, but I can't say that for sure until I test it.

Quote from: https://noobsplanet.com/index.php?threads/fix-internal-external-card-reader-hackintosh-guide.32/

Can you see if these updates/fixes are implemented?

Thanks!

jloisel commented 4 years ago

Please contribute to the repository by creating a pull request with relevant changes, if any found. I have no t440p for testing as of now, so contributions by members who have an hackintosh on hand are welcome.

rsuzuki0 commented 4 years ago

T440p Dock USB ports can be activated by using https://github.com/notthebee/t440p-hackintosh/tree/master/EFI/CLOVER/kexts/Other/USBPorts.kext/Contents and removing USBInjectAll.kext.

I think I the USB port HS12 needs to be activated and generate a new USBPorts.kext to activate the SD card reader, but I'm not as familiar with this art (yet!) I'll have to leave that part up to experts at this moment. See the link on this: https://noobsplanet.com/index.php?threads/fix-internal-external-card-reader-hackintosh-guide.32/#post-773

2000c43 commented 4 years ago

I also would love to have the USB and audio in the dock working. I will try the fix suggested by rsuzuki0 today and report back. As of now, I do not have any USB or audio on the dock working.

2000c43 commented 4 years ago

Wow... that was easy. I installed USBPorts.kext "as-is" from notthebee using the link from rsuzuki0 into my EFI and into Library/Extensions, deleted USBInjectAll.kext from both locations, repaired permissions, rebooted, and the USB ports on the dock work!!! See attached screenshot.

Now to try to figure out how to edit the plist for USBPorts.kext to try to enable the card reader and, in my case, the WWAN. Neither of which are recognized in the system information as of now. Then, finally, the audio port on the dock. At that point, the entire T440P and dock work 100% as far as I'm concerned.
Screen Shot 2020-01-09 at 1 41 32 PM

2000c43 commented 4 years ago

I got the Card Reader to work perfectly!!! Doing some more testing and will report back. Also trying to get the WWAN to get recognized now that the Card Reader is working.

2000c43 commented 4 years ago

Screen Shot 2020-01-09 at 10 07 50 PM

2000c43 commented 4 years ago

DiskSpeedTest

liberninja commented 4 years ago

I tried your method 2000c43. My dock USBs now work great, but I lost my webcam! I readded the USBInjectAll.kext (in combination with USBPorts.kext) and now have webcam back along with the working dock USB. I guess I'll just use both. Still no dock audio though...

What did you do to get your card reader working?

2000c43 commented 4 years ago

EvilistMonkey...you are correct...neither port mapping is perfect. I brought my dock home from the office and will map out a USBPorts.kext today or tomorrow are provide it to the group. I will likely do one as computer only (all USB 2.0 and 3.0, webcam, bluetooth, etc) and one for computer and dock. The reason for two is the 15 port limit. The dock has 6 usb ports and 3 are 2.0 and 3.0... so that's essentially 9 ports since you have to map the 2.0 and 3.0 separately. That leaves only 6 for the computer. Nevertheless, i'll make them up and post back. I'll hopefully have a card reader narrative too. Sorry for the delay but I had to teach myself the port mapping and now I understand it enough to make a USBPorts.kext for the computer and the computer / dock combo.

2000c43 commented 4 years ago

Ok. Good news and bad news.

  1. Good news... I have the USB 2.0, 3.0, Dock 2.0, 3.0, Camera, Bluetooth all good to go in a single kext. 10 USB entries in all as you can see in the Hacktintool screen shot. So there are a theoretical 5 more USB allowed by OS X but I can't find anymore on the computer or deck with the exception of the WWAN and fingerprint sensor (see below). Here is a link to my entire kext folder (same in EFI/Kext/Other and Library/Extensions). All kexts are up to date with the exception of BrcmPatchRam2 (for some reason when I try to use the most recent one it breaks bluetooth / wifi so I left it alone) and VoodooPS2Controller (since this one works very well on the T440P). https://drive.google.com/drive/folders/1VYfKg0XCX4sqSxNxlkrjXLMLVnS66AGJ?usp=sharing

  2. Bad news... I do have my card reader working. However, it only works if I boot to Win 10 (I have two SSDs... one windows in the primary drive and OS X in the CD drive slot) and then restart into OS X. I think what is happening is that the card reader goes into low power mode and OS X can't see it. When I boot to windows and stick an SD Card in I think it "wakes up" the card reader and when I reboot into OS X it works. This is not a USB device as I had originally thought but rather PCIE. So it works... but it doesn't work. I don't know how to fix it permanently so I removed Sinetek-rtsx from my kext folder in the link above since there is no reason to load that kext when the card reader essentially doesn't work reliably enough.

  3. I hope to work on Dock Audio and the WWAN module (which is USB). I can't figure out how to address the WWAN module. I can't find it using Hackintool USB tool to map it. I've tried but haven't figured it out yet. I am pretty sure that once the WWAN is mapped as a USB device, it will work. I uploaded screen shots of the various USB devices as seen by Windows in the link above. I need to find a way to address the WWAN device in the plist in the USBPortsT440Pby2000c43 kext. The plist entries use nomenclature like AQAAAA==, which tells the computer where the ports are. Each port has a unique address but I don't know how to convert what Windows sees the WWAN as to the "AQAAAA" for example to add the entry to the plist and then I think the WWAN will work.

2000c43 commented 4 years ago

Screen Shot 2020-01-12 at 10 51 19 AM

liberninja commented 4 years ago

Thanks for the kext update! I deleted the ones I was using and tried yours and it works perfectly. Card reader I'm just going to abandon. Don't really need it anyways.

jloisel commented 4 years ago

Hi,

Can you make a pull request so I can update the repo? Thanks!

rsuzuki0 commented 4 years ago

When you document the update, you could make it more specific. The update supports USB and audio ports of ThinkPad Ultra dock. The Ethernet port on the ultra dock worked before, without doing anything. The video ports, I think, still do not work.

rsuzuki0 commented 4 years ago

2000c43, thanks for the update. I tried your USBPorts.kext and I am afraid to report that the dock audio still does not work. Do you need a trick to make it active or need a different driver for that port? Unlike your screenshot, the audio device does not show up on the USB connection diagram on the system report.

However, when I insert my headphone into the dock's 3.5mm audio jack, the laptop's internal speaker gets disabled, so something is partially working.

  1. I hope to work on Dock Audio and [...]
2000c43 commented 4 years ago

@rsuzuki0... my usb kext is unrelated to dock audio. The usb kext is just my attempt at a clean, simple, fully functional usb kext for the laptop and the dock all in one. The audio is a different issue and mine functions exactly as you have described. It seems partially working. The solution is in the alc_fix.zip and its associated config.plist. I tried to figure it out but I am having trouble. In the mean time, a usb dac (cheap or expensive) will solve the issue. Just leave the usb audio dac plugged into a usb port and you will be able to switch to dock audio without issue. I'm still trying to get the built in audio to work just haven't cracked it yet. Here is one on Amazon for less than $10 that looks decent and won't take up more than a single USB port. Some adapters are wide and will take up two or three ports on the dock which sort of negates the purpose of the dock in the first place.

rsuzuki0 commented 4 years ago

Ok - I somehow thought that the dock audio port was activated by the USB Ports kext and the existing drivers. I have been using a similar adapter indeed. Thanks.

liberninja commented 4 years ago

2000c43, I've been experiencing problems with your kext. Whenever the laptop goes to sleep while in the dock it does a reboot. If I remove it from the dock sleep works just fine. Any idea what might be causing this?

2000c43 commented 4 years ago

@EvilistMonkey that behavior has been present with my laptop from day 1... with the original usb kext, my usb kext, and any other usb kext i've ever tried. When the laptop is in the dock and you do a "shut down"... it doesn't shut down but rather reboots. I haven't been able to figure out what causes it. I don't have any issues with sleep however. In the dock, my laptop can sleep and wake up just fine. I only have the reboot issue when I try to shut down.

swatchie-1 commented 4 years ago

Hello @2000c43 any progress on the dock audio, dock usb and without rebooting upon wake? Appreciate your works here, hope we have a solution.

karnadii commented 4 years ago

i read somewhere someone use layout id 55 and the dock audio working, but have to wait a little longer to enable the audio on startup. and yeah its working.

swatchie-1 commented 4 years ago

@karnadii nice. however using the USBports.kext which supports the dock causes reboots upon wake from sleep. I guess that's why @jloisel reverted back to USBInjectAll.kext. However this USBInjectAll.kext does not support the Ultra Dock's USB ports and audio from the dock.

Wonder if anyone has a steady USBPorts.kext which supports the USB and Audio for the dock and won't reboot upon wake.

karnadii commented 4 years ago

Don't connect your monitor to docking. Use mini display port on ur laptop. If you connect ur monitor using docking, this will happen.

swatchie-1 commented 4 years ago

@karnadii yeah got it to work thanks. Used applealc 1.4.3 Was hoping the display port on dock can be used without causing reboot when it goes to sleep. This way it's easy to remove the laptop and dock it again without issues. Works well in Windows.

swatchie-1 commented 4 years ago

Hi guys. anybody got their Ultra Dock to Sleep/Shut Down when a display port is connected from the Dock to an external monitor? Mine keeps having kernel panics and rebooting when I do any of the above.