From 3d23c90a8e7788b3230958992bbacd82ad852fd8 Mon Sep 17 00:00:00 2001 From: Minggui Cao Date: Mon, 9 Sep 2019 15:31:29 +0800 Subject: [PATCH] DM: to avoid RTVM shutdown forcely by acrn-dm if RTVM, now we assume it can't be shutdown forcely by SOS, so add check condition to avoid that. Tracked-On: #3564 Signed-off-by: Minggui Cao Acked-by: Yin Fengwei --- devicemodel/core/monitor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devicemodel/core/monitor.c b/devicemodel/core/monitor.c index f924249df..b13c43ef1 100644 --- a/devicemodel/core/monitor.c +++ b/devicemodel/core/monitor.c @@ -352,7 +352,7 @@ static void handle_stop(struct mngr_msg *msg, int client_fd, void *param) ack.msgid = msg->msgid; ack.timestamp = msg->timestamp; - if (msg->data.acrnd_stop.force) { + if (msg->data.acrnd_stop.force && !is_rtvm) { vm_set_suspend_mode(VM_SUSPEND_POWEROFF); ack.data.err = 0; } else {