Skip to contentSkip to conversation

cfi02: Fix lazy ROMD switching - once again

PATCH Applied Jan Kiszka 2 participants 2 messages Feb 4, 2012 – Feb 11, 2012

lore
Share & tools
lore

Jan Kiszka

author
#0 lore raw

PATCH 1/1 cfi02: Fix lazy ROMD switching - once again

The conversion to memory regions broke lazy ROMD switching by forgetting to update the rom_mode state variable.

---
 hw/pflash_cfi02.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
hw/pflash_cfi02.c +1 -0
index a9e88b9..2ca0fd4 100644
@@ -102,6 +102,7 @@ static void pflash_setup_mappings(pflash_t *pfl)
 static void pflash_register_memory(pflash_t *pfl, int rom_mode)
 {
     memory_region_rom_device_set_readable(&pfl->orig_mem, rom_mode);
+    pfl->rom_mode = rom_mode;
 }
 
 static void pflash_timer (void *opaque)
Signature · 1 line
1.7.3.4
Applied
#1 lore raw

Thanks, applied.

Quoted 22 lines · Jan Kiszka

The conversion to memory regions broke lazy ROMD switching by forgetting to update the rom_mode state variable.

---
 hw/pflash_cfi02.c |    1 +

 1 files changed, 1 insertions(+), 0 deletions(-)
hw/pflash_cfi02.c +1 -1
index a9e88b9..2ca0fd4 100644
@@ -102,6 +102,7 @@ static void pflash_setup_mappings(pflash_t *pfl)
  static void pflash_register_memory(pflash_t *pfl, int rom_mode)
  {
     memory_region_rom_device_set_readable(&pfl->orig_mem, rom_mode);
+    pfl->rom_mode = rom_mode;
  }
 
  static void pflash_timer (void *opaque)
--

1.7.3.4