]> git.saurik.com Git - apple/xnu.git/blobdiff - osfmk/i386/hibernate_i386.c
xnu-1504.7.4.tar.gz
[apple/xnu.git] / osfmk / i386 / hibernate_i386.c
index f82e45e6ab98cef6d3c760ec40ac4f7438d3bf5c..f164b8ec9cb1673aa29c27da771cab7a991d6c17 100644 (file)
@@ -85,7 +85,6 @@ hibernate_page_list_allocate(void)
            case kEfiBootServicesCode:
            case kEfiBootServicesData:
            case kEfiConventionalMemory:
-           case kEfiACPIReclaimMemory:
            case kEfiACPIMemoryNVS:
            case kEfiPalCode:
 
@@ -119,6 +118,8 @@ hibernate_page_list_allocate(void)
            // runtime services will be restarted, so no save
            case kEfiRuntimeServicesCode:
            case kEfiRuntimeServicesData:
+           // contents are volatile once the platform expert starts
+           case kEfiACPIReclaimMemory:
            // non dram
            case kEfiReservedMemoryType:
            case kEfiUnusableMemory:
@@ -211,10 +212,13 @@ hibernate_processor_setup(IOHibernateImageHeader * header)
 
     header->runtimePages     = args->efiRuntimeServicesPageStart;
     header->runtimePageCount = args->efiRuntimeServicesPageCount;
-    if (args->Version == kBootArgsVersion1 && args->Revision >= kBootArgsRevision1_5) {
-        header->runtimeVirtualPages = args->efiRuntimeServicesVirtualPageStart;
+    header->runtimeVirtualPages = args->efiRuntimeServicesVirtualPageStart;
+    if (args->Version == kBootArgsVersion1 && args->Revision >= kBootArgsRevision1_6) {
+        header->performanceDataStart = args->performanceDataStart;
+        header->performanceDataSize = args->performanceDataSize;
     } else {
-        header->runtimeVirtualPages = 0;
+        header->performanceDataStart = 0;
+        header->performanceDataSize = 0;
     }
 
     return (KERN_SUCCESS);