Jump to content

Lilu — kext and process patcher


vit9696
394 posts in this topic

Recommended Posts

They do. It is not 1.0.3, but actually 1.0.2 or 1.0.1. Read the changelogs, notes, and FAQ changes after updates, I had to disable connector prioritisation and connector patching by default to avoid issues with newer GPUs.

 

This is not a WhateverGreen support topic but Lilu development topic. Locked to avoid any further misunderstandings.

  • Like 6
Link to comment
Share on other sites

  • 1 month later...

Lilu is getting the largest update since its release. 1.2.0 will bring various improvements in functionality, stability and even speed.

Please refer to work-in-progress changelog for the news: https://github.com/vit9696/Lilu/blob/master/Changelog.md.

 

All the plugin developers are asked to perform the necessary changes to get their works compatible with the new release once it lands.

Please refer to the acknowledged plugins list for their current states: https://github.com/vit9696/Lilu/blob/master/KnownPlugins.md

The recommended timespan for readying all the necessary changes is 1-2 weeks. Ask your questions below if you have any ;)

  • Like 8
Link to comment
Share on other sites

  • 2 weeks later...

I'm pretty sure this is related to Lilu but it could also not be.

I built Lilu 1.2.0 and AppleALC 1.20 from source without any issues.

Installed both kexts to S/L/E.

Now when my machine goes to sleep, upon waking i do not get any image from my monitor.

So it could be related to NvidiaGraphicsFixup.kext in the way that it has not been updated to support 1.2.0 yet.

With Lilu 1.1.4 Installed i get my monitor after sleep but of course no sound from AppleALC 1.2.0

 

Edit: Where can i find the source code for AirportBrcmFixup, IntelGraphicsFixup and NvidiaGraphicsFixup?

Link to comment
Share on other sites

SavageAUS, if you are unaware on how to use beta software, do not install it. NvidiaGraphicsFixup updated code is on the repo :/

 

Sherlocks, add keepsyms=1 to boot args :/ I do not have symbol solver in my eyes.

  • Like 1
Link to comment
Share on other sites

SavageAUS, if you are unaware on how to use beta software, do not install it. NvidiaGraphicsFixup updated code is on the repo :/Sherlocks, add keepsyms=1 to boot args :/ I do not have symbol solver in my eyes.

I got it all sorted and built all the kext required but I get kp while trying to install High Sierra. The new kexts work fine in Sierra just not High Sierra.

Link to comment
Share on other sites

SavageAUS, after over a thousand posts of spam you have in your profile have not you learnt to provide at least something relevant to explore the issue and help you? I have several people running Lilu and various plugins on 10.13, so far nobody had panics. I do not have a crystal ball to imagine what and where panics.

  • Like 2
Link to comment
Share on other sites

Guest ricoc90

I got it all sorted and built all the kext required but I get kp while trying to install High Sierra. The new kexts work fine in Sierra just not High Sierra.

Which plugins exactly?

Some plugins (so not actually Lilu) are causing a KP when booting from installer media (full install as well as update). e.g. NightShiftUnlocker.kext.

Link to comment
Share on other sites

SavageAUS, if you are unaware on how to use beta software, do not install it. NvidiaGraphicsFixup updated code is on the repo :/

 

Sherlocks, add keepsyms=1 to boot args :/ I do not have symbol solver in my eyes.

Sorry for late reply.

Here is pic.

I tested 10.8~10.13.

 

Only 10.9 has kp. 10.8, 10.10 and over no problem.

 

Thanks in advance

 

6245b040ef5e81d40f7d2448c61fbdcc.jpg

 

나의 LG-F800S 의 Tapatalk에서 보냄

Link to comment
Share on other sites

Erng? Now 10.9? I definitely see 10.8.x kernel on your previous image. In fact I even took some of my free time and installed 10.8.5 yesterday. I tested several plugins (though, current master compiled from source), and had no issues with them:

AirportBrcmFixup.kext
AppleALC.kext
BT4LEContiunityFixup.kext
HibernationFixup.kext
IntelGraphicsFixup.kext
Lilu.kext
NvidiaGraphicsFixup.kext
Shiki.kext
WhateverGreen.kext

To save my free time, may I ask you to retry with the attached plugins? Install any you need, and tell me which of them you used along with the panic log.

 

*removed the attachment to avoid any confusion when 1.2.0 is released*

  • Like 1
Link to comment
Share on other sites

Erng? Now 10.9? I definitely see 10.8.x kernel on your previous image. In fact I even took some of my free time and installed 10.8.5 yesterday. I tested several plugins (though, current master compiled from source), and had no issues with them:

AirportBrcmFixup.kext
AppleALC.kext
BT4LEContiunityFixup.kext
HibernationFixup.kext
IntelGraphicsFixup.kext
Lilu.kext
NvidiaGraphicsFixup.kext
Shiki.kext
WhateverGreen.kext
To save my free time, may I ask you to retry with the attached plugins? Install any you need, and tell me which of them you used along with the panic log.
Thank you. I see my previous pic. Yeah 10.8.5 kernel. Hmm. Maybe rare into panic? I will try your files. And post again

 

Thanks

 

나의 LG-F800S 의 Tapatalk에서 보냄

Link to comment
Share on other sites

 

Checked the panic log. This is fixed in Lilu 1.2.0 I attached above (which is not released yet):

- Fixed FAT_CIGAM and FAT_MAGIC parsing issues
- Fixed a number of potential memory issues in mach parsing code

 

i can't download your package file. can you send me file? ex. pm. 

i used this files on 10.8 and 10.9.

IntelGraphicsFixup.kext 1.1.6

Lilu.kext 1.1.7

 

 

Link to comment
Share on other sites

SavageAUS, after over a thousand posts of spam you have in your profile have not you learnt to provide at least something relevant to explore the issue and help you? I have several people running Lilu and various plugins on 10.13, so far nobody had panics. I do not have a crystal ball to imagine what and where panics.

Posts of spam? wow. I didn't bother to report anything as i was testing unreleased software and it could have been my error. From what i could tell it was NvidiaGraphicsFixup.kext that was causing the issue with the 1.2.0 version while trying to install 10.13. I've built plenty of kexts from git repositories but have never used sf for git or svn repos, that is why i was asking. I apologise if asking where to find the source code was classified as spam but as the saying goes, you don't know unless you ask and not everyone is proficient with sf.

 

Anyway, good work with lilu + plugins.

Link to comment
Share on other sites

If it was NvidiaGraphicsFixup, the you could have forgotten to check the radme (https://sourceforge.net/p/nvidiagraphicsfixup/svn/HEAD/tree/trunk/). The new NvidiaGraphicsFixup implements NVWebDriverLibValFix functionality and the system will effectively crash if NVWebDriverLibValFix is present at the same time.

Thanks for the heads up.

Link to comment
Share on other sites

If it was NvidiaGraphicsFixup, the you could have forgotten to check the radme (https://sourceforge.net/p/nvidiagraphicsfixup/svn/HEAD/tree/trunk/). The new NvidiaGraphicsFixup implements NVWebDriverLibValFix functionality and the system will effectively crash if NVWebDriverLibValFix is present at the same time.

 

I don't have NVWebDriverLibValFix in my system but it crash the same... so in kext clover's : 

 

Lilu.kext (1.2);

- NvidiaGraphicsFixup.kext (1.2);

- AppleALC.kext (1.2); 

- FakeSMC.kext (latest); 

- IntelMausiEthernet.kext (latest); 

- USBInjectAll.kext (latest)

- XHCI-200-series-injector.kext (latest)

 

@ Smbios 18.3

 

EDIT : 

 

sorry I'm a donkey!!!!

 

I had forgotten that I had installed (NVWebDriverLibValFix) in /L/E !!!!

 

So sorry, everything works perfectly! endless thanks for all the work you do

post-1373167-0-76898000-1507747677_thumb.jpg

Link to comment
Share on other sites

Hi,

 

I need a lilu-plugin that is able to patch AppleIntelCPUPowerManagement.

Is there anybody out there, who can help me with this?

 

From Clover's kext_patcher.c

////////////////////////////////////
//
// AsusAICPUPM patch
//
// fLaked's SpeedStepper patch for Asus (and some other) boards:
// http://www.insanelymac.com/forum/index.php?showtopic=258611
//
// Credits: Samantha/RevoGirl/DHP
// http://www.insanelymac.com/forum/topic/253642-dsdt-for-asus-p8p67-m-pro/page__st__200#entry1681099
// Rehabman corrections 2014
//

UINT8   MovlE2ToEcx[] = { 0xB9, 0xE2, 0x00, 0x00, 0x00 };
UINT8   MovE2ToCx[]   = { 0x66, 0xB9, 0xE2, 0x00 };
UINT8   Wrmsr[]       = { 0x0F, 0x30 };

VOID AsusAICPUPMPatch(UINT8 *Driver, UINT32 DriverSize, CHAR8 *InfoPlist, UINT32 InfoPlistSize, LOADER_ENTRY *Entry)
{
  UINTN   Index1;
  UINTN   Index2;
  UINTN   Count = 0;

  DBG_RT(Entry, "\nAsusAICPUPMPatch: driverAddr = %x, driverSize = %x\n", Driver, DriverSize);
  if (Entry->KernelAndKextPatches->KPDebug) {
    ExtractKextBundleIdentifier(InfoPlist);
  }
  DBG_RT(Entry, "Kext: %a\n", gKextBundleIdentifier);

  //TODO: we should scan only __text __TEXT
  for (Index1 = 0; Index1 < DriverSize; Index1++) {
    // search for MovlE2ToEcx
    if (CompareMem(Driver + Index1, MovlE2ToEcx, sizeof(MovlE2ToEcx)) == 0) {
      // search for wrmsr in next few bytes
      for (Index2 = Index1 + sizeof(MovlE2ToEcx); Index2 < Index1 + sizeof(MovlE2ToEcx) + 32; Index2++) {
        if (Driver[Index2] == Wrmsr[0] && Driver[Index2 + 1] == Wrmsr[1]) {
          // found it - patch it with nops
          Count++;
          Driver[Index2] = 0x90;
          Driver[Index2 + 1] = 0x90;
          DBG_RT(Entry, " %d. patched at 0x%x\n", Count, Index2);
          break;
        } else if ((Driver[Index2] == 0xC9 && Driver[Index2 + 1] == 0xC3) ||
                   (Driver[Index2] == 0x5D && Driver[Index2 + 1] == 0xC3) ||
                   (Driver[Index2] == 0xB9 && Driver[Index2 + 3] == 0 && Driver[Index2 + 4] == 0) ||
                   (Driver[Index2] == 0x66 && Driver[Index2 + 1] == 0xB9 && Driver[Index2 + 3] == 0)) {
          // a leave/ret will cancel the search
          // so will an intervening "mov[l] $xx, [e]cx"
          break;
        }
      }
    } else if (CompareMem(Driver + Index1, MovE2ToCx, sizeof(MovE2ToCx)) == 0) {
      // search for wrmsr in next few bytes
      for (Index2 = Index1 + sizeof(MovE2ToCx); Index2 < Index1 + sizeof(MovE2ToCx) + 32; Index2++) {
        if (Driver[Index2] == Wrmsr[0] && Driver[Index2 + 1] == Wrmsr[1]) {
          // found it - patch it with nops
          Count++;
          Driver[Index2] = 0x90;
          Driver[Index2 + 1] = 0x90;
          DBG_RT(Entry, " %d. patched at 0x%x\n", Count, Index2);
          break;
        } else if ((Driver[Index2] == 0xC9 && Driver[Index2 + 1] == 0xC3) ||
                   (Driver[Index2] == 0x5D && Driver[Index2 + 1] == 0xC3) ||
                   (Driver[Index2] == 0xB9 && Driver[Index2 + 3] == 0 && Driver[Index2 + 4] == 0) ||
                   (Driver[Index2] == 0x66 && Driver[Index2 + 1] == 0xB9 && Driver[Index2 + 3] == 0)) {
          // a leave/ret will cancel the search
          // so will an intervening "mov[l] $xx, [e]cx"
          break;
        }
      }
    }
  }
  DBG_RT(Entry, "= %d patches\n", Count);
  if (Entry->KernelAndKextPatches->KPDebug) {
    gBS->Stall(5000000);
  }
}

Edit:

I solved my problem with the help of the UEFIPatch but anyway, I think that could be a useful extension.

Link to comment
Share on other sites

SavageAUS, after over a thousand posts of spam you have in your profile have not you learnt to provide at least something relevant ...

 

 

Alright. What you expect me to do with that response?... - Do you read people's entire posts you quote or just spam threads?

 

 

I do read posts and I do not spam...

 

 

Posts of spam? wow. I didn't bother to report anything as i was testing unreleased software and it could have been my error. From what i could tell it was NvidiaGraphicsFixup.kext that was causing the issue with the 1.2.0 version while ...

 

lol. Some people never change on here... 

 

On a side note, grateful for Lilu vit9696 - thank you for your hard work.

 

EDIT: SavageAUS I'm not having a personal conversation with you/PMs I didn't even bother reading whatever you sent me I deleted it. 

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...

Hi i have problem with lilu and whatevergreen kext when i add pci-e i210 ethenert black screen back :( in log everything is ok! but when boot system with rx480 in the end normal is to go to black screen and back with login screen - when add pci-e i210 ethernet controllel all boot fine go to black screen and stay in it :(

Link to comment
Share on other sites

×
×
  • Create New...