diff options
author | Jagannathan Raman <jag.raman@oracle.com> | 2021-01-29 11:46:18 -0500 |
---|---|---|
committer | Stefan Hajnoczi <stefanha@redhat.com> | 2021-02-10 09:23:28 +0000 |
commit | c746b74a7d881c7da4afdd7b29353a90c445a8ab (patch) | |
tree | 798a89b7087a39b793d5800582d633a6659f6e0b /hw/remote/message.c | |
parent | 7ee3f82384f07e84f1d2e26a0ab1e5efa7e7f822 (diff) | |
download | qemu-c746b74a7d881c7da4afdd7b29353a90c445a8ab.zip qemu-c746b74a7d881c7da4afdd7b29353a90c445a8ab.tar.gz qemu-c746b74a7d881c7da4afdd7b29353a90c445a8ab.tar.bz2 |
multi-process: Synchronize remote memory
Add ProxyMemoryListener object which is used to keep the view of the RAM
in sync between QEMU and remote process.
A MemoryListener is registered for system-memory AddressSpace. The
listener sends SYNC_SYSMEM message to the remote process when memory
listener commits the changes to memory, the remote process receives
the message and processes it in the handler for SYNC_SYSMEM message.
Signed-off-by: Jagannathan Raman <jag.raman@oracle.com>
Signed-off-by: John G Johnson <john.g.johnson@oracle.com>
Signed-off-by: Elena Ufimtseva <elena.ufimtseva@oracle.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Message-id: 04fe4e6a9ca90d4f11ab6f59be7652f5b086a071.1611938319.git.jag.raman@oracle.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'hw/remote/message.c')
-rw-r--r-- | hw/remote/message.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/hw/remote/message.c b/hw/remote/message.c index f2e8445..25341d8 100644 --- a/hw/remote/message.c +++ b/hw/remote/message.c @@ -17,6 +17,7 @@ #include "sysemu/runstate.h" #include "hw/pci/pci.h" #include "exec/memattrs.h" +#include "hw/remote/memory.h" static void process_config_write(QIOChannel *ioc, PCIDevice *dev, MPQemuMsg *msg, Error **errp); @@ -61,6 +62,9 @@ void coroutine_fn mpqemu_remote_msg_loop_co(void *data) case MPQEMU_CMD_BAR_READ: process_bar_read(com->ioc, &msg, &local_err); break; + case MPQEMU_CMD_SYNC_SYSMEM: + remote_sysmem_reconfig(&msg, &local_err); + break; default: error_setg(&local_err, "Unknown command (%d) received for device %s" |