From: Kostiantyn Kostiuk Date: Mon, 25 Aug 2025 14:05:49 +0000 (+0300) Subject: qga: ignore channel_init() fail if 'retry_path' is set X-Git-Tag: v10.2.0-rc1~113^2~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b44c8a6d837ed4e082dd03d79095a4e9141eff5b;p=thirdparty%2Fqemu.git qga: ignore channel_init() fail if 'retry_path' is set On Windows, we run QGA with `-d --retry-path` options by default, and expect that QGA will start even without the vioserial driver and will wait for communication forever. Reviewed-by: Yan Vugenfirer Reviewed-by: Michal Privoznik Link: https://lore.kernel.org/qemu-devel/20250825140549.146617-3-kkostiuk@redhat.com Signed-off-by: Kostiantyn Kostiuk --- diff --git a/qga/main.c b/qga/main.c index a1bf8f53acb..dd1c216f9a1 100644 --- a/qga/main.c +++ b/qga/main.c @@ -1512,8 +1512,12 @@ static GAState *initialize_agent(GAConfig *config, int socket_activation) if (!channel_init(s, s->config->method, s->config->channel_path, s->socket_activation ? FIRST_SOCKET_ACTIVATION_FD : -1)) { - g_critical("failed to initialize guest agent channel"); - return NULL; + if (s->config->retry_path) { + g_info("failed to initialize guest agent channel, will retry"); + } else { + g_critical("failed to initialize guest agent channel"); + return NULL; + } } if (config->daemonize) {