X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=memory_mapping.c;h=e3ec70624f871db4fc26494cad17b79034feaabb;hb=28605a22f564860c885bde42ad91840e9aacec45;hp=a5d38552a6f1026cb24555a4d4ae0d46421f3165;hpb=f4f3082b0c35b5aa84616dc2dc8c9c0aac2d6a1c;p=mirror_qemu.git diff --git a/memory_mapping.c b/memory_mapping.c index a5d38552a6..e3ec70624f 100644 --- a/memory_mapping.c +++ b/memory_mapping.c @@ -206,7 +206,8 @@ static void guest_phys_blocks_region_add(MemoryListener *listener, /* we only care about RAM */ if (!memory_region_is_ram(section->mr) || - memory_region_is_ram_device(section->mr)) { + memory_region_is_ram_device(section->mr) || + memory_region_is_nonvolatile(section->mr)) { return; } @@ -222,7 +223,7 @@ static void guest_phys_blocks_region_add(MemoryListener *listener, if (!QTAILQ_EMPTY(&g->list->head)) { hwaddr predecessor_size; - predecessor = QTAILQ_LAST(&g->list->head, GuestPhysBlockHead); + predecessor = QTAILQ_LAST(&g->list->head); predecessor_size = predecessor->target_end - predecessor->target_start; /* the memory API guarantees monotonically increasing traversal */ @@ -256,7 +257,7 @@ static void guest_phys_blocks_region_add(MemoryListener *listener, #ifdef DEBUG_GUEST_PHYS_REGION_ADD fprintf(stderr, "%s: target_start=" TARGET_FMT_plx " target_end=" - TARGET_FMT_plx ": %s (count: %u)\n", __FUNCTION__, target_start, + TARGET_FMT_plx ": %s (count: %u)\n", __func__, target_start, target_end, predecessor ? "joined" : "added", g->list->num); #endif }