[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RFC v4 PATCH 31/49] multi-process: handle heartbeat messages in remote
From: |
Jagannathan Raman |
Subject: |
[RFC v4 PATCH 31/49] multi-process: handle heartbeat messages in remote process |
Date: |
Thu, 24 Oct 2019 05:09:12 -0400 |
From: Elena Ufimtseva <address@hidden>
If the remote process is alive, it responds to proxy's heartbeat
messages
Signed-off-by: Jagannathan Raman <address@hidden>
Signed-off-by: John G Johnson <address@hidden>
Signed-off-by: Elena Ufimtseva <address@hidden>
---
remote/remote-main.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/remote/remote-main.c b/remote/remote-main.c
index 729f7e9..27e4492 100644
--- a/remote/remote-main.c
+++ b/remote/remote-main.c
@@ -355,6 +355,7 @@ static void process_msg(GIOCondition cond, MPQemuChannel
*chan)
{
MPQemuMsg *msg = NULL;
Error *err = NULL;
+ int wait;
if ((cond & G_IO_HUP) || (cond & G_IO_ERR)) {
error_setg(&err, "socket closed, cond is %d", cond);
@@ -434,6 +435,11 @@ static void process_msg(GIOCondition cond, MPQemuChannel
*chan)
case DEVICE_DEL:
process_device_del_msg(msg);
break;
+ case PROXY_PING:
+ wait = msg->fds[0];
+ notify_proxy(wait, (uint32_t)getpid());
+ PUT_REMOTE_WAIT(wait);
+ break;
default:
error_setg(&err, "Unknown command");
goto finalize_loop;
--
1.8.3.1
- [RFC v4 PATCH 18/49] multi-process: create IOHUB object to handle irq, (continued)
- [RFC v4 PATCH 18/49] multi-process: create IOHUB object to handle irq, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 20/49] multi-process: add qdev_proxy_add to create proxy devices, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 21/49] multi-process: remote: add setup_devices and setup_drive msg processing, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 22/49] multi-process: remote: use fd for socket from parent process, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 23/49] multi-process: remote: add create_done condition, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 24/49] multi-process: add processing of remote drive and device command line, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 26/49] multi-process: refractor vl.c code to re-use in remote, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 27/49] multi-process: add remote option, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 28/49] multi-process: add remote options parser, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 30/49] multi-process: send heartbeat messages to remote, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 31/49] multi-process: handle heartbeat messages in remote process,
Jagannathan Raman <=
- [RFC v4 PATCH 32/49] multi-process: Use separate MMIO communication channel, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 34/49] multi-process/mon: choose HMP commands based on target, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 35/49] multi-process/mon: stub functions to enable QMP module for remote process, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 36/49] multi-process/mon: enable QMP module support in the remote process, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 38/49] multi-process/mon: Initialize QMP module for remote processes, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 37/49] multi-process/mon: Refactor monitor/chardev functions out of vl.c, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 39/49] multi-process: prevent duplicate memory initialization in remote, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 40/49] multi-process/mig: build migration module in the remote process, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 41/49] multi-process/mig: Enable VMSD save in the Proxy object, Jagannathan Raman, 2019/10/24
- [RFC v4 PATCH 42/49] multi-process/mig: Send VMSD of remote to the Proxy object, Jagannathan Raman, 2019/10/24