• Stars
    star
    1,664
  • Rank 28,091 (Top 0.6 %)
  • Language
    C++
  • License
    BSD 3-Clause "New...
  • Created over 6 years ago
  • Updated 5 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

SMC emulator layer

VirtualSMC

Build Status Scan Status

Advanced Apple SMC emulator in the kernel. Requires Lilu for full functioning.

English (Current)
简体中文

Features

  • Supports macOS 10.4 and newer (10.9 and newer is recommended)
  • Implements MMIO protocol and interrupt-based responses for compatibility with modern OS
  • Properly reports key attributes and r/w protection in the keys
  • Allows tuning on per-model basis and allows to use different SMC generations
  • Extensible by the plugins for sensor and key addition support
  • Enables smcdebug=XX boot argument support on 10.9
  • Replaces hardware SMC it finds (to disable SMC entirely you need to flash a dedicated firmware)

Boot arguments

  • Add -vsmcdbg to enable debug printing (available in DEBUG binaries).
  • Add -vsmcoff to switch off all the Lilu enhancements.
  • Add -vsmcbeta to enable Lilu enhancements on unsupported OS (13 and below are enabled by default).
  • Add -vsmcrpt to report about missing SMC keys to the system log.
  • Add -vsmccomp to prefer existing hardware SMC implementation if found.
  • Add vsmcgen=X to force exposing X-gen SMC device (1 and 2 are supported).
  • Add vsmchbkp=X to set HBKP dumping mode (0 - off, 1 - normal, 2 - without encryption).
  • Add vsmcslvl=X to set value serialisation level (0 - off, 1 - normal, 2 - with sensitive data (default)).
  • Add smcdebug=0xff to enable AppleSMC debug information printing.
  • Add watchdog=0 to disable WatchDog timer (if you get accidental reboots).

Credits

  • Apple for macOS
  • netkas for the original idea of creating a software SMC emulator
  • CupertinoNet for reversing most of MMIO protocol and SMC headers
  • Alex Ionescu for the initial reverse of SMC firmware
  • 07151129 for co-devoloping VirtualSMC and invaluable help during the research
  • lvs1974 for developing laptop sensor support
  • usr-sse2 for developing laptop sensor support
  • joedmru for developing Super I/O chips support
  • theopolis for smc-fuzzer tool
  • kokke for tiny-AES-c
  • vit9696 for Lilu.kext and this software
  • Additional big thanks go to all the contributors and researchers involved in Apple SMC exploration!

More Repositories

1

OpenCorePkg

OpenCore bootloader
C
13,029
star
2

Lilu

Arbitrary kext and process patching on macOS
C
3,585
star
3

AppleALC

Native macOS HD audio for not officially supported codecs
C++
3,439
star
4

WhateverGreen

Various patches necessary for certain ATI/AMD/Intel/Nvidia GPUs
C++
3,236
star
5

BrcmPatchRAM

C++
1,037
star
6

MaciASL

ACPI editing IDE for macOS
Objective-C
749
star
7

OcBinaryData

733
star
8

NVMeFix

C++
685
star
9

AirportBrcmFixup

An open source kernel extension providing a set of patches required for non-native Airport Broadcom Wi-Fi cards.
C++
643
star
10

MacHyperVSupport

Hyper-V integration support for macOS
C++
620
star
11

AppleSupportPkg

AppleSupportPkg - contains UEFI drivers for Apple environment support
559
star
12

CPUFriend

Dynamic macOS CPU power management data injection
C++
535
star
13

VoodooPS2

C++
513
star
14

IntelMausi

Intel Ethernet LAN driver for macOS
C
390
star
15

bugtracker

Acidanthera Bugtracker
375
star
16

HibernationFixup

A Lilu plugin intended to fix hibernation compatibility issues
C++
371
star
17

FeatureUnlock

Add Sidecar support to unsupported models
C++
362
star
18

gfxutil

Device Properties conversion tool
C
274
star
19

MacInfoPkg

Mac Platform Information
249
star
20

RestrictEvents

C++
249
star
21

CpuTscSync

It is a Lilu plugin, combining functionality of VoodooTSCSync and disabling xcpm_urgency if TSC is not in sync. It should solve kernel panics after wake.
C++
171
star
22

MacKernelSDK

macOS kernel SDK targeting various XNU versions
C
167
star
23

AptioFixPkg

AptioFixPkg drivers to workaround macOS compatibility with APTIO UEFI FW
161
star
24

Shiki

Protected video playback support and hardware video acceleration on various hardware.
152
star
25

VoodooInput

Generic Multitouch Handler kernel extension for macOS
C++
151
star
26

BrightnessKeys

Handler for brightness keys without DSDT patches
C++
132
star
27

RTCMemoryFixup

open source kernel extension providing a way to emulate some offsets in your CMOS (RTC) memory
C++
97
star
28

macserial

Decode mac serial number
96
star
29

CryptexFixup

Various patches to install Rosetta Cryptex
C++
88
star
30

BT4LEContinuityFixup

72
star
31

OcSupportPkg

OpenCore common libraries
71
star
32

IOJones

Realtime I/O Registry viewer
60
star
33

DebugEnhancer

A Lilu plugin intended to enable debug output in the macOS kernel
C++
58
star
34

audk

Acidanthera UEFI Development Kit based on EDK II edk2-stable202405
C
57
star
35

dmidecode

dmidecode version with macOS specific improvements
C
40
star
36

ocbuild

Shell
39
star
37

EmeraldSDHC

SD host controller support for macOS
C++
39
star
38

OpenCoreShell

Patched UDK Shell adopted for wide firmware range
38
star
39

EfiPkg

38
star
40

UEFIGraphicsFB

UEFI framebuffer driver for macOS
C++
28
star
41

mac-efi-firmware

C
24
star
42

CpuTopologySync

Rebuild asymmetric CPU topology on macOS.
23
star
43

DuetPkg

Duet UEFI firmware emulator
15
star
44

ocmtoc

C
7
star
45

OcLegacyPkg

Legacy OpenCorePkg repository left for historical purposes
7
star