]> git.saurik.com Git - apple/xnu.git/blobdiff - iokit/Kernel/IOStartIOKit.cpp
xnu-2782.20.48.tar.gz
[apple/xnu.git] / iokit / Kernel / IOStartIOKit.cpp
index 4a218304dc3ad1d951ab244b2c4bfcb47b29c7bb..787a69bf26679ddd080c2bf68d45b97da7fb7e14 100644 (file)
 #include <IOKit/pwr_mgt/IOPMinformeeList.h>
 #include <IOKit/IOStatisticsPrivate.h>
 #include <IOKit/IOKitKeysPrivate.h>
+#include <IOKit/IOInterruptAccountingPrivate.h>
 
 #include <IOKit/assert.h>
 
 #include "IOKitKernelInternal.h"
 
+const OSSymbol * gIOProgressBackbufferKey;
+OSSet *          gIORemoveOnReadProperties;
+
 extern "C" {
 
 extern void OSlibkernInit (void);
@@ -153,6 +157,11 @@ void StartIOKit( void * p1, void * p2, void * p3, void * p4 )
     IOLibInit(); 
     OSlibkernInit();
 
+    gIOProgressBackbufferKey  = OSSymbol::withCStringNoCopy(kIOProgressBackbufferKey);
+    gIORemoveOnReadProperties = OSSet::withObjects((const OSObject **) &gIOProgressBackbufferKey, 1);
+
+    interruptAccountingInit();
+
     rootNub = new IOPlatformExpertDevice;
 
     if( rootNub && rootNub->initWithArgs( p1, p2, p3, p4)) {
@@ -194,4 +203,17 @@ IORegistrySetOSBuildVersion(char * build_version)
     return;
 }
 
+void
+IORecordProgressBackbuffer(void * buffer, size_t size, uint32_t theme)
+{
+    IORegistryEntry * chosen;
+    if ((chosen = IORegistryEntry::fromPath(kIODeviceTreePlane ":/chosen")))
+    {
+        chosen->setProperty(kIOProgressBackbufferKey, buffer, size);
+       chosen->setProperty(kIOProgressColorThemeKey, theme, 32);
+
+        chosen->release();
+    }
+}
+
 }; /* extern "C" */