Patchwork memory: fix memory_region_init_rom_device() not initializing ->ops

login
register
mail settings
Submitter Avi Kivity
Date Aug. 25, 2011, 11:57 a.m.
Message ID <1314273426-12526-1-git-send-email-avi@redhat.com>
Download mbox | patch
Permalink /patch/111560/
State New
Headers show

Comments

Avi Kivity - Aug. 25, 2011, 11:57 a.m.
Signed-off-by: Avi Kivity <avi@redhat.com>
---
 memory.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

Patch

diff --git a/memory.c b/memory.c
index 8e9ac46..b91c5da 100644
--- a/memory.c
+++ b/memory.c
@@ -967,6 +967,7 @@  void memory_region_init_rom_device(MemoryRegion *mr,
                                    uint64_t size)
 {
     memory_region_init(mr, name, size);
+    mr->ops = ops;
     mr->terminates = true;
     mr->destructor = memory_region_destructor_rom_device;
     mr->ram_addr = qemu_ram_alloc(dev, name, size);