[RFC v4 PATCH 42/49] multi-process/mig: Send VMSD of remote to the Proxy object

2019-10-24 Thread Jagannathan Raman
The remote process sends the VMSD to the Proxy object, on the source side Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- New patch in v4 migration/savevm.c | 27 +++ migration/savevm.h | 2 ++ remote/remote

[RFC v4 PATCH 12/49] multi-process: remote process initialization

2019-10-24 Thread Jagannathan Raman
Adds the handler to process message from QEMU, Initialize remote process main loop, handles SYNC_SYSMEM message by updating its "system_memory" container using shared file descriptors received from QEMU. Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva Signed-off-by: J

[RFC v4 PATCH 49/49] multi-process: add configure and usage information

2019-10-24 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- docs/qemu-multiprocess.txt | 86 ++ 1 file changed, 86 insertions(+) create mode 100644 docs/qemu-multiprocess.txt diff --git

[RFC v4 PATCH 46/49] multi-process/mig: Restore the VMSD in remote process

2019-10-24 Thread Jagannathan Raman
From: Elena Ufimtseva The remote process accepts the VMSD from Proxy object and restores it Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- New patch in v4 migration/savevm.c | 36 migration/savevm.h

[RFC v4 PATCH 43/49] multi-process/mig: Load VMSD in the proxy object

2019-10-24 Thread Jagannathan Raman
From: Elena Ufimtseva The Proxy object loads the VMSD of remote process in source and send it to the remote process in the destination Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- New patch in v4 hw/proxy/qemu-proxy.c| 50

[RFC v4 PATCH 38/49] multi-process/mon: Initialize QMP module for remote processes

2019-10-24 Thread Jagannathan Raman
Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- New patch in v3 remote/remote-main.c | 11 +++ remote/remote-opts.c | 10 ++ 2 files changed, 21 insertions(+) diff --git a/remote/remote-main.c b/remote/remote-main.c index

[RFC v4 PATCH 27/49] multi-process: add remote option

2019-10-24 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- New patch in v3 qemu-options.hx | 21 + 1 file changed, 21 insertions(+) diff --git a/qemu-options.hx b/qemu-options.hx index 996b6fb..4734e8e 100644

[PATCH v5 28/50] multi-process: add remote options parser

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- include/monitor/qdev.h | 1 + softmmu/vl.c | 105 + vl-parse.c | 31 +++ vl.h

[PATCH v5 42/50] multi-process/mig: Send VMSD of remote to the Proxy object

2020-02-24 Thread Jagannathan Raman
The remote process sends the VMSD to the Proxy object, on the source side Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- migration/savevm.c | 27 +++ migration/savevm.h | 2 ++ remote/remote-main.c | 43

[PATCH v5 41/50] multi-process/mig: Enable VMSD save in the Proxy object

2020-02-24 Thread Jagannathan Raman
Collect the VMSD from remote process on the source and save it to the channel leading to the destination Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- v4 -> v5: - Using qemu_file_shutdown() instead of qemu_thread_cancel(). Removed pa

[PATCH v5 27/50] multi-process: add remote option

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- qemu-options.hx | 21 + 1 file changed, 21 insertions(+) diff --git a/qemu-options.hx b/qemu-options.hx index ac315c1..2c5e97f 100644 --- a/qemu

[PATCH v5 35/50] multi-process/mon: stub functions to enable QMP module for remote process

2020-02-24 Thread Jagannathan Raman
Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- accel/stubs/tcg-stub.c | 10 +++ configure | 4 ++ include/qemu-common.h | 8 +++ stubs/gdbstub.c| 23 +++ stubs/migration.c | 162 + stubs

[PATCH v5 16/50] multi-process: Synchronize remote memory

2020-02-24 Thread Jagannathan Raman
process receives the message and processes it in the handler for SYNC_SYSMEM message. TODO: No need to create object for remote memory listener. Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- Makefile.target| 3 + hw/proxy

[PATCH v5 36/50] multi-process/mon: enable QMP module support in the remote process

2020-02-24 Thread Jagannathan Raman
Build system changes to enable QMP module in the remote process Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- Makefile.objs | 9 + Makefile.target| 35 +-- hmp-commands.hx| 5 +-- hw

[PATCH v5 33/50] multi-process: perform device reset in the remote process

2020-02-24 Thread Jagannathan Raman
Perform device reset in the remote process when QEMU performs device reset. This is required to reset the internal state (like registers, etc...) of emulated devices Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- V4 -> v5: - Device re

[PATCH v5 29/50] multi-process: add parse_cmdline in remote process

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- remote/Makefile.objs | 1 + remote/remote-main.c | 11 ++ remote/remote-opts.c | 99 remote/remote-opts.h | 15

[PATCH v5 05/50] multi-process: Add config option for multi-process QEMU

2020-02-24 Thread Jagannathan Raman
Add a configuration option to separate multi-process code Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva --- configure | 11 +++ 1 file changed, 11 insertions(+) diff --git a/configure b/configure index 48d6f89..ab1e344 100755

[PATCH v5 03/50] multi-process: add a command line option for debug file

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Can be used with -d rdebug command options when starting qemu. Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Reviewed-by: Stefan Hajnoczi --- include/qemu/log.h | 1 + util/log.c | 2 ++ 2 files changed, 3

[PATCH v5 13/50] multi-process: introduce proxy object

2020-02-24 Thread Jagannathan Raman
. In case of pci config write it forwards it to the remote device using communication channel set by proxy-link object. Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- v4 -> v5: - Switched to execv hw/Makefile.objs | 2 + hw/pr

[PATCH v5 21/50] multi-process: remote: add setup_devices msg processing

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Receive by remote side the configuration messages and build the device object from JSON device descriptions. Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- include/hw/qdev-core.h | 2 + qdev-monitor.c | 2

[PATCH v5 10/50] multi-process: setup a machine object for remote device process

2020-02-24 Thread Jagannathan Raman
remote-machine object sets up various subsystems of the remote device process. Instantiate PCI host bridge object and initialize RAM, IO & PCI memory regions. Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva --- v4 -> v5: - Refactor notifi

[PATCH v5 09/50] multi-process: setup PCI host bridge for remote device

2020-02-24 Thread Jagannathan Raman
PCI host bridge is setup for the remote device process. It is implemented using remote-pcihost object. It is an extension of the PCI host bridge setup by QEMU. Remote-pcihost configures a PCI bus which could be used by the remote PCI device to latch on to. Signed-off-by: Jagannathan Raman

[PATCH v5 02/50] multi-process: Refactor machine_init and exit notifiers

2020-02-24 Thread Jagannathan Raman
Relocate machine_int and exit notifiers into common code Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- include/sysemu/sysemu.h | 2 ++ softmmu/vl.c| 42 -- util/notify.c | 43

[PATCH v5 00/50] Initial support for multi-process qemu

2020-02-24 Thread Jagannathan Raman
ived to improve this patchset. We also received valuable feedback and direction on future improvements from the bi-weekly KVM community conference. We have incorporated all the feedback in the current version of the series, v5. Following people contributed to this patchset: John G Johnson Jagannathan R

[PATCH v5 08/50] multi-process: add functions to synchronize proxy and remote endpoints

2020-02-24 Thread Jagannathan Raman
In some cases, for example MMIO read, QEMU has to wait for the remote to complete a command before proceeding. An eventfd based mechanism is added to synchronize QEMU & remote process. Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva --- includ

[PATCH v5 30/50] multi-process: send heartbeat messages to remote

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva In order to detect remote processes which are hung, the proxy periodically sends heartbeat messages to confirm if the remote process is alive Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- v4 -> v5: - Heart b

[PATCH v5 26/50] multi-process: refractor vl.c code

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva To re-use for device initialization for remote emulated devices and parsing options for remote process. Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- Makefile.objs| 5 ++ remote/Makefile.objs | 1

[PATCH v5 23/50] multi-process: remote: add create_done condition

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Do not allow BAR,MMIO handlers and irq setup to run before the configuration of the devices completes. Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- remote/remote-main.c | 27 ++- 1 file

[PATCH v5 15/50] multi-process: PCI BAR read/write handling for proxy & remote endpoints

2020-02-24 Thread Jagannathan Raman
-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson --- hw/proxy/qemu-proxy.c | 65 ++ include/hw/proxy/qemu-proxy.h | 22 +++-- include/io/mpqemu-link.h | 12 +++ remote/remote-main.c | 73

[PATCH v5 46/50] multi-process/mig: Restore the VMSD in remote process

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva The remote process accepts the VMSD from Proxy object and restores it Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- migration/savevm.c | 36 migration/savevm.h | 1 + remote

[PATCH v5 19/50] multi-process: Retrieve PCI info from remote process

2020-02-24 Thread Jagannathan Raman
Retrieve PCI configuration info about the remote device and configure the Proxy PCI object based on the returned information Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- New Patch in v5. Removes per-device proxy and adds support

[PATCH v5 24/50] multi-process: add processing of remote device command line

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Add processing of command line options for devices emulated in the remote process. After remote devices are created along with their proxies, signal the proxies to finish the configuration steps. Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off

[PATCH v5 11/50] multi-process: setup memory manager for remote device

2020-02-24 Thread Jagannathan Raman
-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- v4 -> v5: - Refactored remote_ram_init_from_fd into common code Makefile.target | 2 ++ exec.c | 17 + include/exec/ram_addr.h | 2 ++ include/io/mpqemu-link.h |

[PATCH v5 18/50] multi-process: configure remote side devices

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Add functions to configure remote devices. Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- v4 -> v5: - Fixed qstr leak issue hw/proxy/qemu-proxy.c | 56 ++- include

[PATCH v5 14/50] mutli-process: build remote command line args

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- v4 -> v5: - Added "exec" suboption to get the executable's name - Addressed feedback about variable names - Removed redundant check for spawning a proce

[PATCH v5 20/50] multi-process: add qdev_proxy_add to create proxy devices

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva This is handled while parsing the command line options. The parsed options are being sent to remote process as the messgaes containing JSON strings. Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- v4 -> v5: - Remo

[PATCH v5 37/50] multi-process/mon: Refactor monitor/chardev functions out of vl.c

2020-02-24 Thread Jagannathan Raman
gned-off-by: Jagannathan Raman --- chardev/char.c| 14 ++ include/chardev/char.h| 1 + include/monitor/monitor.h | 2 ++ monitor/monitor.c | 40 ++- remote/remote-main.c | 1 + remote/remote-opts.c | 1 + soft

[PATCH v5 32/50] multi-process: Use separate MMIO communication channel

2020-02-24 Thread Jagannathan Raman
Using a separate communication channel for MMIO helps with improving Performance Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- hw/proxy/qemu-proxy.c | 51 --- include/hw/proxy/qemu-proxy.h | 1

[PATCH v5 34/50] multi-process/mon: choose HMP commands based on target

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Add "targets" field to HMP command definition to select the targets which would be supported by each command Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- hmp-commands-info.hx | 10 ++ hmp-c

[PATCH v5 01/50] multi-process: memory: alloc RAM from file at offset

2020-02-24 Thread Jagannathan Raman
Allow RAM MemoryRegion to be created from an offset in a file, instead of allocating at offset of 0 by default. This is needed to synchronize RAM between QEMU & remote process. This will be needed for the following patches. Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Si

[PATCH v5 06/50] multi-process: build system for remote device process

2020-02-24 Thread Jagannathan Raman
Modify Makefile to support the building of the remote device process. Implements main() function of remote device process. Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva --- Makefile| 2 ++ Makefile.objs | 26

[PATCH v5 25/50] multi-process: Introduce build flags to separate remote process code

2020-02-24 Thread Jagannathan Raman
Introduce SCSI_PROCESS & REMOTE_PROCESS build flags to separate code that applies only to remote processes. Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- Makefile.target | 4 rules.mak | 2 +- 2 files changed, 5 insertions(+

[PATCH v5 43/50] multi-process/mig: Load VMSD in the proxy object

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva The Proxy object loads the VMSD of remote process in source and send it to the remote process in the destination Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- hw/proxy/qemu-proxy.c| 50

[PATCH v5 07/50] multi-process: define mpqemu-link object

2020-02-24 Thread Jagannathan Raman
ived on the communication channel. Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- v4 -> v5: - Cleaned up included header files include/io/mpqemu-link.h | 138 ++ io/Makefile.objs | 2 + io/mpqemu-link.c

[PATCH v5 22/50] multi-process: remote: use fd for socket from parent process

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- remote/remote-main.c | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/remote/remote-main.c b/remote/remote-main.c index 3a67cb9..455cfb6 100644

[PATCH v5 17/50] multi-process: create IOHUB object to handle irq

2020-02-24 Thread Jagannathan Raman
Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva --- v4 -> v5: - Using event_notifier_test_and_clear - Using event_notifier_cleanup() - The token is not malloced Makefile.target | 1 + hw/Makefile.objs | 2 - hw/proxy/Makefile.objs|

[PATCH v5 12/50] multi-process: remote process initialization

2020-02-24 Thread Jagannathan Raman
Adds the handler to process message from QEMU, Initialize remote process main loop, handles SYNC_SYSMEM message by updating its "system_memory" container using shared file descriptors received from QEMU. Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva Signed-off-by: J

[PATCH v5 39/50] multi-process: prevent duplicate memory initialization in remote

2020-02-24 Thread Jagannathan Raman
G Johnson Signed-off-by: Jagannathan Raman --- hw/proxy/qemu-proxy.c | 13 - include/hw/proxy/qemu-proxy.h | 1 + qdev-monitor.c| 2 +- 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/hw/proxy/qemu-proxy.c b/hw/proxy/qemu-proxy.c index 741f02

[PATCH v5 31/50] multi-process: handle heartbeat messages in remote process

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva If the remote process is alive, it responds to proxy's heartbeat messages Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- remote/remote-main.c | 5 + 1 file changed, 5 insertions(+) diff --git a/remote/remote

[PATCH v5 45/50] multi-process/mig: Synchronize runstate of remote process

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Synchronize the runstate of the remote process with that of QEMU Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- hw/proxy/qemu-proxy.c | 26 ++ include/hw/proxy/qemu-proxy.h | 2

[PATCH v5 40/50] multi-process/mig: build migration module in the remote process

2020-02-24 Thread Jagannathan Raman
Add Makefile support to enable migration in remote process Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- Makefile.objs | 4 +++- Makefile.target | 1 + migration/Makefile.objs | 13 - net/Makefile.objs

[PATCH v5 38/50] multi-process/mon: Initialize QMP module for remote processes

2020-02-24 Thread Jagannathan Raman
Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- remote/remote-main.c | 11 +++ remote/remote-opts.c | 10 ++ 2 files changed, 21 insertions(+) diff --git a/remote/remote-main.c b/remote/remote-main.c index 23fc0df..58d9905

[PATCH v5 50/50] multi-process: add configure and usage information

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- docs/qemu-multiprocess.txt | 86 ++ 1 file changed, 86 insertions(+) create mode 100644 docs/qemu-multiprocess.txt diff --git

[PATCH v5 47/50] multi-process: Enable support for multiple devices in remote

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Add support to allow multiple devices to be configured in the remote process Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- hw/proxy/qemu-proxy.c | 4 ++- include/hw/proxy/qemu-proxy.h | 3 +++ include/io

[PATCH v5 04/50] multi-process: Add stub functions to facilate build of multi-process

2020-02-24 Thread Jagannathan Raman
Add stub functions that are needed during compile time but not in runtime. Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva --- accel/stubs/kvm-stub.c| 5 +++ accel/stubs/tcg-stub.c| 97

[PATCH v5 48/50] multi-process: Validate incoming commands from Proxy

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva Validate the incoming commands to confirm that they would not cause any errors in the remote process. Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- hw/proxy/qemu-proxy.c| 6 +++- include/io/mpqemu-link.h | 2

[PATCH v5 44/50] multi-process/mig: refactor runstate_check into common file

2020-02-24 Thread Jagannathan Raman
From: Elena Ufimtseva runstate_check file is refactored into vl-parse.c Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- Makefile.objs | 2 ++ include/sysemu/runstate.h | 2 ++ runstate.c| 36

[PATCH v5 49/50] multi-process: add the concept description to docs/devel/qemu-multiprocess

2020-02-24 Thread Jagannathan Raman
From: John G Johnson Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman --- docs/devel/index.rst |1 + docs/devel/qemu-multiprocess.rst | 1102 ++ 2 files changed, 1103 insertions(+) create mode

[PATCH v11 01/19] memory: alloc RAM from file at offset

2020-10-15 Thread Jagannathan Raman
Allow RAM MemoryRegion to be created from an offset in a file, instead of allocating at offset of 0 by default. This is needed to synchronize RAM between QEMU & remote process. Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva Reviewed-by: St

[PATCH v11 11/19] multi-process: add proxy communication functions

2020-10-15 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Reviewed-by: Stefan Hajnoczi --- include/io/mpqemu-link.h | 4 io/mpqemu-link.c | 38 ++ 2 files changed, 42 insertions

[PATCH v11 10/19] multi-process: introduce proxy object

2020-10-15 Thread Jagannathan Raman
From: Elena Ufimtseva Defines a PCI Device proxy object as a child of TYPE_PCI_DEVICE. Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- MAINTAINERS| 2 ++ hw/pci/meson.build | 1 + hw/pci/proxy.c | 98

[PATCH v11 17/19] multi-process: perform device reset in the remote process

2020-10-15 Thread Jagannathan Raman
From: Elena Ufimtseva Perform device reset in the remote process when QEMU performs device reset. This is required to reset the internal state (like registers, etc...) of emulated devices Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Reviewed

[PATCH v11 15/19] multi-process: create IOHUB object to handle irq

2020-10-15 Thread Jagannathan Raman
Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva Reviewed-by: Stefan Hajnoczi --- MAINTAINERS| 2 + hw/i386/meson.build| 1 + hw/i386/remote-iohub.c | 123 + hw/i386/remote-msg.c | 4

[PATCH v11 04/19] multi-process: setup a machine object for remote device process

2020-10-15 Thread Jagannathan Raman
remote-machine object sets up various subsystems of the remote device process. Instantiate PCI host bridge object and initialize RAM, IO & PCI memory regions. Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva Reviewed-by: Stefan Hajn

[PATCH v11 16/19] multi-process: Retrieve PCI info from remote process

2020-10-15 Thread Jagannathan Raman
Retrieve PCI configuration info about the remote device and configure the Proxy PCI object based on the returned information Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Reviewed-by: Stefan Hajnoczi --- hw/pci/proxy.c | 85

[PATCH v11 12/19] multi-process: Forward PCI config space acceses to the remote process

2020-10-15 Thread Jagannathan Raman
times out on the probing. We have tried to only refer to the remote for the PCI config writes, but the driver timeout in the guest forced as to left this as it is (removing local PCI config only). Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson

[PATCH v11 13/19] multi-process: PCI BAR read/write handling for proxy & remote endpoints

2020-10-15 Thread Jagannathan Raman
Proxy device object implements handler for PCI BAR writes and reads. The handler uses BAR_WRITE/BAR_READ message to communicate to the remote process with the BAR address and value to be written/read. The remote process implements handler for BAR_WRITE/BAR_READ message. Signed-off-by: Jagannathan

[PATCH v11 05/19] multi-process: add qio channel function to transmit

2020-10-15 Thread Jagannathan Raman
From: Elena Ufimtseva The entire array of the memory regions and file handlers. Will be used in the next patch. Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Reviewed-by: Stefan Hajnoczi --- include/io/channel.h | 24

[PATCH v11 07/19] multi-process: Initialize message handler in remote device

2020-10-15 Thread Jagannathan Raman
Initializes the message handler function in the remote process. It is called whenever there's an event pending on QIOChannel that registers this function. Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Reviewed-by: Stefan Hajnoczi

[PATCH v11 19/19] multi-process: add configure and usage information

2020-10-15 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Reviewed-by: Stefan Hajnoczi --- MAINTAINERS| 2 ++ docs/multi-process.rst | 67 ++ scripts/mpqemu-launcher.py

[PATCH v11 03/19] multi-process: setup PCI host bridge for remote device

2020-10-15 Thread Jagannathan Raman
PCI host bridge is setup for the remote device process. It is implemented using remote-pcihost object. It is an extension of the PCI host bridge setup by QEMU. Remote-pcihost configures a PCI bus which could be used by the remote PCI device to latch on to. Signed-off-by: Jagannathan Raman Signed

[PATCH v11 00/19] Initial support for multi-process Qemu

2020-10-15 Thread Jagannathan Raman
on the qemu-devel mailist. You can find them by following the links below ([1] - [9]). Following people contributed to the design and implementation of this project: Jagannathan Raman Elena Ufimtseva John G Johnson Stefan Hajnoczi Konrad Wilk Kanth Ghatraju We would like to thank QEMU community

[PATCH v11 08/19] multi-process: Associate fd of a PCIDevice with its object

2020-10-15 Thread Jagannathan Raman
Associate the file descriptor for a PCIDevice in remote process with DeviceState object. Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- MAINTAINERS | 2 + hw/i386/meson.build | 1 + hw/i386/remote-msg.c

[PATCH v11 14/19] multi-process: Synchronize remote memory

2020-10-15 Thread Jagannathan Raman
process receives the message and processes it in the handler for SYNC_SYSMEM message. Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva Reviewed-by: Stefan Hajnoczi --- MAINTAINERS | 2 + hw/i386/remote-msg.c | 5 ++ hw

[PATCH v11 06/19] multi-process: define MPQemuMsg format and transmission functions

2020-10-15 Thread Jagannathan Raman
, outside of co-routine context will block IOThread; Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- MAINTAINERS | 2 + include/io/mpqemu-link.h | 60 io/meson.build | 2 + io/mpqemu-link.c | 237

[PATCH v11 02/19] multi-process: Add config option for multi-process QEMU

2020-10-15 Thread Jagannathan Raman
Add a configuration option to separate multi-process code Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva Reviewed-by: Stefan Hajnoczi --- configure | 10 ++ meson.build | 1 + 2 files changed, 11 insertions(+) diff --git a/configure

[PATCH v11 09/19] multi-process: setup memory manager for remote device

2020-10-15 Thread Jagannathan Raman
SyncSysMemMsg message format is defined. It is used to send file descriptors of the RAM regions to remote device. RAM on the remote device is configured with a set of file descriptors. Old RAM regions are deleted and new regions, each with an fd, is added to the RAM. Signed-off-by: Jagannathan

[PATCH v11 18/19] multi-process: add the concept description to docs/devel/qemu-multiprocess

2020-10-15 Thread Jagannathan Raman
From: John G Johnson Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Reviewed-by: Stefan Hajnoczi --- MAINTAINERS | 1 + docs/devel/index.rst | 1 + docs/devel/multi-process.rst | 966

[PATCH v8 00/20] Initial support for multi-process qemu

2020-07-31 Thread Jagannathan Raman
. Subsequently, we posted RFC v1 [1], RFC v2 [2], RFC v3 [3], RFC v4 [4], v5 [5], v6 [6] and v7 [7] of the patch series. Following people contributed to the design and implementation of this project: Stefan Hajnoczi Konrad Wilk Kanth Ghatraju John G Johnson Elena Ufimtseva Jagannathan Raman

[PATCH v8 16/20] multi-process: Retrieve PCI info from remote process

2020-07-31 Thread Jagannathan Raman
Retrieve PCI configuration info about the remote device and configure the Proxy PCI object based on the returned information Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- hw/pci/proxy.c | 85

[PATCH v8 01/20] memory: alloc RAM from file at offset

2020-07-31 Thread Jagannathan Raman
Allow RAM MemoryRegion to be created from an offset in a file, instead of allocating at offset of 0 by default. This is needed to synchronize RAM between QEMU & remote process. Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva Reviewed-by: St

[PATCH v8 03/20] multi-process: setup PCI host bridge for remote device

2020-07-31 Thread Jagannathan Raman
PCI host bridge is setup for the remote device process. It is implemented using remote-pcihost object. It is an extension of the PCI host bridge setup by QEMU. Remote-pcihost configures a PCI bus which could be used by the remote PCI device to latch on to. Signed-off-by: Jagannathan Raman Signed

[PATCH v8 05/20] multi-process: add qio channel function to transmit

2020-07-31 Thread Jagannathan Raman
From: Elena Ufimtseva The entire array of the memory regions and file handlers. Will be used in the next patch. Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Reviewed-by: Stefan Hajnoczi --- include/io/channel.h | 24

[PATCH v8 08/20] multi-process: Initialize message handler in remote device

2020-07-31 Thread Jagannathan Raman
Initializes the message handler function in the remote process. It is called whenever there's an event pending on QIOChannel that registers this function. Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- MAINTAINERS | 1 + hw/i386

[PATCH v8 02/20] multi-process: Add config option for multi-process QEMU

2020-07-31 Thread Jagannathan Raman
Add a configuration option to separate multi-process code Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva Reviewed-by: Stefan Hajnoczi --- configure | 11 +++ 1 file changed, 11 insertions(+) diff --git a/configure b/configure index

[PATCH v8 13/20] multi-process: PCI BAR read/write handling for proxy & remote endpoints

2020-07-31 Thread Jagannathan Raman
Proxy device object implements handler for PCI BAR writes and reads. The handler uses BAR_WRITE/BAR_READ message to communicate to the remote process with the BAR address and value to be written/read. The remote process implements handler for BAR_WRITE/BAR_READ message. Signed-off-by: Jagannathan

[PATCH v8 14/20] multi-process: Synchronize remote memory

2020-07-31 Thread Jagannathan Raman
process receives the message and processes it in the handler for SYNC_SYSMEM message. Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- MAINTAINERS | 2 + hw/i386/remote-msg.c | 4 + hw/pci/Makefile.objs | 1

[PATCH v8 07/20] multi-process: add co-routines to communicate with remote

2020-07-31 Thread Jagannathan Raman
From: Elena Ufimtseva process to avoid blocking the main loop during the message exchanges. To be used by proxy device. Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- include/io/mpqemu-link.h | 15 + io/mpqemu-link.c | 82

[PATCH v8 09/20] multi-process: Associate fd of a PCIDevice with its object

2020-07-31 Thread Jagannathan Raman
Associate the file descriptor for a PCIDevice in remote process with DeviceState object. Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- MAINTAINERS | 2 + hw/i386/Makefile.objs| 1 + hw/i386/remote-obj.c

[PATCH v8 04/20] multi-process: setup a machine object for remote device process

2020-07-31 Thread Jagannathan Raman
remote-machine object sets up various subsystems of the remote device process. Instantiate PCI host bridge object and initialize RAM, IO & PCI memory regions. Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva --- MAINTAINERS

[PATCH v8 17/20] multi-process: heartbeat messages to remote

2020-07-31 Thread Jagannathan Raman
From: Elena Ufimtseva In order to detect remote processes which are hung, the proxy periodically sends heartbeat messages to confirm if the remote process is alive. The remote process responds to this heartbeat message to confirm it is alive. Signed-off-by: Jagannathan Raman Signed-off

[PATCH v8 10/20] multi-process: setup memory manager for remote device

2020-07-31 Thread Jagannathan Raman
SyncSysMemMsg message format is defined. It is used to send file descriptors of the RAM regions to remote device. RAM on the remote device is configured with a set of file descriptors. Old RAM regions are deleted and new regions, each with an fd, is added to the RAM. Signed-off-by: Jagannathan

[PATCH v8 11/20] multi-process: introduce proxy object

2020-07-31 Thread Jagannathan Raman
From: Elena Ufimtseva Defines a PCI Device proxy object as a child of TYPE_PCI_DEVICE. Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- MAINTAINERS| 2 ++ hw/pci/Makefile.objs | 1 + hw/pci/proxy.c | 80

[PATCH v8 19/20] multi-process: add the concept description to docs/devel/qemu-multiprocess

2020-07-31 Thread Jagannathan Raman
From: John G Johnson Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman --- MAINTAINERS | 1 + docs/devel/index.rst | 1 + docs/devel/multi-process.rst | 966 +++ 3 files changed

[PATCH v8 18/20] multi-process: perform device reset in the remote process

2020-07-31 Thread Jagannathan Raman
From: Elena Ufimtseva Perform device reset in the remote process when QEMU performs device reset. This is required to reset the internal state (like registers, etc...) of emulated devices Signed-off-by: Elena Ufimtseva Signed-off-by: John G Johnson Signed-off-by: Jagannathan Raman --- hw

[PATCH v8 15/20] multi-process: create IOHUB object to handle irq

2020-07-31 Thread Jagannathan Raman
Signed-off-by: Jagannathan Raman Signed-off-by: Elena Ufimtseva --- MAINTAINERS | 2 + hw/Makefile.objs | 1 + hw/i386/remote-msg.c | 4 ++ hw/i386/remote.c | 10 hw/pci/proxy.c| 58 ++ hw/remote/Makefile.objs

[PATCH v8 06/20] multi-process: define MPQemuMsg format and transmission functions

2020-07-31 Thread Jagannathan Raman
-off-by: Jagannathan Raman Signed-off-by: John G Johnson Signed-off-by: Elena Ufimtseva --- MAINTAINERS | 2 + include/io/mpqemu-link.h | 73 io/Makefile.objs | 2 + io/mpqemu-link.c | 175 +++ 4

[PATCH v8 20/20] multi-process: add configure and usage information

2020-07-31 Thread Jagannathan Raman
From: Elena Ufimtseva Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- MAINTAINERS| 2 ++ docs/multi-process.rst | 67 ++ scripts/mpqemu-launcher.py | 49

[PATCH v8 12/20] multi-process: Forward PCI config space acceses to the remote process

2020-07-31 Thread Jagannathan Raman
times out on the probing. We have tried to only refer to the remote for the PCI config writes, but the driver timeout in the guest forced as to left this as it is (removing local PCI config only). Signed-off-by: Elena Ufimtseva Signed-off-by: Jagannathan Raman Signed-off-by: John G Johnson --- hw

Re: [PATCH v12 00/19] Initial support for multi-process Qemu

2020-12-03 Thread Jagannathan Raman
 > On Dec 3, 2020, at 4:53 AM, Stefan Hajnoczi wrote: > > On Tue, Dec 01, 2020 at 03:22:35PM -0500, Jagannathan Raman wrote: >> This is the v12 of the patchset. Thank you very much for the >> review of the v11 of the series. > > I'm in favor of merging this for

<    1   2   3   4   5   6   >