acidanthera / bugtracker

Acidanthera Bugtracker
385 stars 44 forks source link

SMCBatteryManager is incompatible with Sierra 10.12.6 #1114

Open Sher1ocks opened 4 years ago

Sher1ocks commented 4 years ago

hi, today, I tested old macOS on my skylake laptop.

I'm using latest OC, Lilu with kexts.

  1. Catalina -> Perfect

  2. Mojave -> Perfect

  3. High Sierra -> Perfect

  4. Sierra 10.12.6 (16G29)

    • Battery icon SMCBatteryManager.kext : battery indicator is disappear, and showing 0% on energy saver menu. -> I changed ACPIBatteryManager.kext, battery indicator is working. - WIFI in recovery, wifi is working. but after installed Sierra, setting windows, can't find wifi in network. after setting, then get windows, I can't see wifi icon on menu bar. I have to change lang ko to en. and reboot, I can get wifi driver with icon -> cache issue? - PCI information(cosmetics) high Sierra and higher macOS, PCI Information(AAPL,slot-name, model, etc) showing correctly ~~in system report. but in Sierra, show error message. ~~ if I use ssdt _DSM cosmetic, showing PCI info(AAPL,slot-name, model, etc) correctly.

thanks in advance

vit9696 commented 4 years ago

I do not think we have ever tested SMCBatteryManager on 10.12. You could try publishing the kernel and the OpenCore log about it.

Wi-Fi… I do not know, if you use AirportBrcmFixup, then the same goes for its 10.12 compatibility. Need logs via the usual liludump=60 way.

PCI information — it is unclear what is broken here.

Sher1ocks commented 4 years ago

I do not think we have ever tested SMCBatteryManager on 10.12. You could try publishing the kernel and the OpenCore log about it.

Wi-Fi… I do not know, if you use AirportBrcmFixup, then the same goes for its 10.12 compatibility. Need logs via the usual liludump=60 way.

PCI information — it is unclear what is broken here.

  1. here is log file. 10.12.6_ 16G2136 _kernel.zip opencore-2020-08-23-020203.txt

  2. wifi log file with liludump=60 Lilu_1.4.6_16.7.txt

  3. pci information is like that Screen Shot 2020-08-23 at 11 09 20 AM

Sher1ocks commented 4 years ago

additionally, I had kernel panic. here is log panic-2020-08-23-012057.txt

Sher1ocks commented 4 years ago

once again, installed sierra. here is log

wifi report @lvs1974

  1. usb install log opencore-2017-12-10-081334.txt

  2. after install and setting window, then get log. not showing wifi. Lilu_1.4.6_16.7.txt opencore-2017-12-10-082615.txt

12:370 00:003 OCAK: Reducing prelink size from 2451000 to 21AA000 via plist 12:400 00:029 OC: Prelink injection Lilu.kext () - Success 12:417 00:017 OC: Prelink injection VirtualSMC.kext () - Success 12:428 00:010 OC: Prelink injection ACPIDebug.kext () - Success 12:436 00:007 OCAK: Dependency com.apple.driver.corecapture was not found for kext as.lvs1974.AirportBrcmFixup

additionally, after rebuild caches, then i can get wifi. as result, must be rebuild cache for wifi.

Sher1ocks commented 4 years ago

PCI information is not related in OC. some macOS need more key for showing pic info to avoid pci information error.

vit9696 commented 4 years ago

For Wi-Fi (AirportBrcmFixup) will need an ability to force loading dependencies from macOS root volume when unavailable. You will have to manually add corecapture kext to your configuration when the feature lands. This is what we want to do soon, but there the load is too high at the moment.

For PCI the issue is indeed not ours. It is macOS 10.12 specific.

For SMCBatteryManager, this looks like our bug, but I am not positive when we are going to explore it.

For the kernel panic, I believe it happened due to logging, so not a big deal.

lvs1974 commented 4 years ago

@Sher1ocks, the problem with com.apple.driver.corecapture rather related to kernelcache, than to AirportBrcmFixup.

Sher1ocks commented 4 years ago

For Wi-Fi (AirportBrcmFixup) will need an ability to force loading dependencies from macOS root volume when unavailable. You will have to manually add corecapture kext to your configuration when the feature lands. This is what we want to do soon, but there the load is too high at the moment.

For PCI the issue is indeed not ours. It is macOS 10.12 specific.

For SMCBatteryManager, this looks like our bug, but I am not positive when we are going to explore it.

For the kernel panic, I believe it happened due to logging, so not a big deal.

thanks alot, if there is test file in future, i will test

@Sher1ocks, the problem with com.apple.driver.corecapture rather related to kernelcache, than to AirportBrcmFixup.

right. if rebuild kernel caches once, there is no problem.

as result, now SMCBatteryManager is only issue on 10.12.6, other issues are not big issues

thanks alot

lvs1974 commented 4 years ago

@Sher1ocks, could you test attached version in Sierra, please? I think you need to disable AirportBrcmFixup, rebuild kernel cache, install new version and try to boot. AirportBrcmFixup-2.0.9-DEBUG.zip I removed some dependencies (IONetworkFamily, corecapture and so on), it needs Lilu, IOPCIFamily and bsd, dsep, iokit, libkern, mach, unsupported). Running recovery and check wi-fi is also good test-case.

Sher1ocks commented 4 years ago

@Sher1ocks, could you test attached version in Sierra, please? I think you need to disable AirportBrcmFixup, rebuild kernel cache, install new version and try to boot. AirportBrcmFixup-2.0.9-DEBUG.zip I removed some dependencies (IONetworkFamily, corecapture and so on), it needs Lilu, IOPCIFamily and bsd, dsep, iokit, libkern, mach, unsupported). Running recovery and check wi-fi is also good test-case.

@lvs1974 wifi is perfect!! thanks alot both normal and recovery are no problem. also i tested clean sierra installation. here is log Lilu_1.4.6_16.7.txt opencore-2020-08-24-013147.txt

lvs1974 commented 4 years ago

@Sher1ocks, thank you very much for testing!

Sher1ocks commented 4 years ago

@Sher1ocks, thank you very much for testing!

you're welcome😀

zhen-zen commented 4 years ago

Could you confirm whether SMC keys in KeyImplementations present? And if there are some properties in SystemInformation.app or coconut Battery (updated via smbus)? The log shows that the battery was fully charged at that time so there's no follow-up pull. And the information from ACPI might be correct since cycle count is valid.

Sher1ocks commented 4 years ago

Could you confirm whether SMC keys in KeyImplementations present? And if there are some properties in SystemInformation.app or coconut Battery (updated via smbus)? The log shows that the battery was fully charged at that time so there's no follow-up pull. And the information from ACPI might be correct since cycle count is valid.

my acpi battery patch is good. 10.13, 10.14, 10.15, 11.0 everything is fine. only happen issue on 10.12 sierra. here is capture file 10.12.6 Sierra 스크린샷 2020-09-01 8 01 23 PM

11.0 Big Sur Screen Shot 2020-09-01 at 8 08 15 PM

how can i check SMC keys in KeyImplementations present? or there are some properties in SystemInformation.app

zhen-zen commented 4 years ago

Thanks for your patience. The SMC keys can be checked with the bundled tools with VirtualSMC. Both SMC keys submission and smbus should work as intended according to the log and your screenshot. States like kMStateCmd also got updated after correct battery status being polled. I'm afraid that I couldn't help debugging that currently, and maybe I will try 10.12.6 later.

Sher1ocks commented 4 years ago

Thanks for your patience. The SMC keys can be checked with the bundled tools with VirtualSMC. Both SMC keys submission and smbus should work as intended according to the log and your screenshot. States like kMStateCmd also got updated after correct battery status being polled. I'm afraid that I couldn't help debugging that currently, and maybe I will try 10.12.6 later.

thanks alot if you want debug, i can test

zhen-zen commented 3 years ago

Just downloaded 10.12.6 installer and booted into the recovery. Unlike 10.13.6, there's no battery indicator. I will install it when I find an empty drive later. (The APFS just won't shrink although it's half empty).

Edit: data from system_profiler in terminal is still valid.

zhen-zen commented 3 years ago

Sounds like the battery status is not acquired, or maybe the poll is too early? In ACPIBatteryManager, there's a note

Fix problem of losing battery icon on 10.13 High Sierra beta. It is a new timing bug introduced in High Sierra. Delaying the first poll and battery status publish fixes it. StartupDelay configuration is removed (not used, has no effect if specified in ACPI override). New configuration item FirstPollDelay is default at 7500. Slower computers may need a longer delay (for my Lenovo u430, 3500 is too short, 4000 is long enough).

With coconutBattery, the column "macOS Battery status" is empty with SMCBatteryManager. However it should show "Good" there, which is the case of higher OS and ACPIBatteryManager.

Sher1ocks commented 3 years ago

Sounds like the battery status is not acquired, or maybe the poll is too early? In ACPIBatteryManager, there's a note

Fix problem of losing battery icon on 10.13 High Sierra beta. It is a new timing bug introduced in High Sierra. Delaying the first poll and battery status publish fixes it. StartupDelay configuration is removed (not used, has no effect if specified in ACPI override). New configuration item FirstPollDelay is default at 7500. Slower computers may need a longer delay (for my Lenovo u430, 3500 is too short, 4000 is long enough).

With coconutBattery, the column "macOS Battery status" is empty with SMCBatteryManager. However it should show "Good" there, which is the case of higher OS and ACPIBatteryManager.

yes. i don't know that exactly. but ACPIBatterymanager is no problem in 10.13