diff mbox

[for-2.10,1/2] mmio-execution: warn the potential developer about migration

Message ID 1501575048-13485-2-git-send-email-frederic.konrad@adacore.com (mailing list archive)
State New, archived
Headers show

Commit Message

KONRAD Frederic Aug. 1, 2017, 8:10 a.m. UTC
There are two potential corner cases with mmio-execution:
 * It adds a mmio-interface device which will be migrated.
 * It modifies the RAMBlock list during live migration which odd
   side effects.

Signed-off-by: KONRAD Frederic <frederic.konrad@adacore.com>
---
 include/exec/memory.h | 4 ++++
 1 file changed, 4 insertions(+)
diff mbox

Patch

diff --git a/include/exec/memory.h b/include/exec/memory.h
index 400dd44..4ded02c 100644
--- a/include/exec/memory.h
+++ b/include/exec/memory.h
@@ -154,6 +154,10 @@  struct MemoryRegionOps {
      * @offset is the location of the pointer inside @mr.
      *
      * Returns a pointer to a location which contains guest code.
+     *
+     * Warning: This breaks migration if used before or during migration
+     *          because mmio-interface device will be migrated and because
+     *          RAMBlock list _must_ be static during migration.
      */
     void *(*request_ptr)(void *opaque, hwaddr addr, unsigned *size,
                          unsigned *offset);