From nobody Sat Nov 23 17:58:26 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) client-ip=8.43.85.245; envelope-from=devel-bounces@lists.libvirt.org; helo=lists.libvirt.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass(p=reject dis=none) header.from=lists.libvirt.org ARC-Seal: i=1; a=rsa-sha256; t=1723160879; cv=none; d=zohomail.com; s=zohoarc; b=nDjK65v1nvVLY44Tq8fZTcZxLDtO0OTvDuxwSpIqAKpE0vU/h11Q0IVRQuTAwW5wuW9i9I7JEFBnhDlwY3Q05E06+Vs3gplxjR741CwojSwC20x+S6B741QQ3LjnUANb0JJDKcouL3pPZc7vnR4fAaQSTzcbIuiSGso4VspGY7U= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1723160879; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Reply-To:References:Subject:Subject:To:To:Message-Id; bh=GUAJqWJHcb8RTjqH/VbT1h9/95GdQy01x/35e1eGOts=; b=AEnq1xZTjSR8V8Fap+1aX0Qik49YmPLOvxNvch9GIOzJchGjE1MPZaqVG+sV6LoCePUB82GZA3vG66zaUC0WUQ5MPxbrSD7N5XgpAVovBhNy6MRJPSf39vOz5Kc36yDS8UQNXL4vZxbSpkqH2OparB5z1mtRkf6NYBegRQ0lBNA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1723160879129664.9291595309813; Thu, 8 Aug 2024 16:47:59 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 10C6914C5; Thu, 8 Aug 2024 19:47:58 -0400 (EDT) Received: from lists.libvirt.org (localhost [IPv6:::1]) by lists.libvirt.org (Postfix) with ESMTP id 7F3931428; Thu, 8 Aug 2024 19:39:25 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 996) id D10BA14B5; Thu, 8 Aug 2024 19:39:20 -0400 (EDT) Received: from mail-lj1-f182.google.com (mail-lj1-f182.google.com [209.85.208.182]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id 4933D145C for ; Thu, 8 Aug 2024 19:38:54 -0400 (EDT) Received: by mail-lj1-f182.google.com with SMTP id 38308e7fff4ca-2ef1c12ae23so14724121fa.0 for ; Thu, 08 Aug 2024 16:38:54 -0700 (PDT) Received: from localhost ([69.51.98.127]) by smtp.gmail.com with ESMTPSA id 8926c6da1cb9f-4ca6be646b5sm74717173.146.2024.08.08.16.38.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Aug 2024 16:38:52 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1723160333; x=1723765133; darn=lists.libvirt.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=J1ySj5eOlzAYsT0uO6m7DkpPF81TpXINE7puuNkCK0U=; b=UmYUhOTO3vSMSzF52VxBJR9Ff6+shLyRYWSuD28rota4uVkhccgE7hUSLusFrSvrzr MtSkhrW+QuBAho9ByEngzPT9pD9cvYrE7+IyF27M05wsKXgSt6hqJta2B4q9i82mIOO6 PZbbePKELIIXXqnUX/jO8gTBUlmJvVrObPm2li6FpAmrVXhk4wbFsIka864qm2Xvnv7o bAWsQzAHG5BGQKFb8nl3H16V5MRtBbZcYQcXv9KtgkJ81Ju/fSOe+FTY0yJYSVVQ6MaY jHJakv5hWFKqu3sM0/jPfA4Fqj+fRehJZDGfjt68Q6pEo27pCmBMikgLb1d6Uh3XmRVm MRIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723160333; x=1723765133; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=J1ySj5eOlzAYsT0uO6m7DkpPF81TpXINE7puuNkCK0U=; b=ecEj4DbRZOO+d/KJXvIyc4c6l3UlmEJSd1CkeuJCkMrwcAlTWcNTXLndI3FcgdKk2F VHFuE8vWYNa2dwAr13XxFdmxStCiEwcpurTHsFfWZxQCQ0j7pCjzjciAspY/i85TptdW deX0WCgonSLJ1SiqCQkrp5ij6y1SbWnTqo3gkCTkekl0jkePE8mTom5KMwuNmtBeZJS6 ao1797W9JUR2AwVoGla6LFA1i2y0/vYqjJsIoFw0+5sADJcgQde0zlcRGEW2fQ4roS3A bsXtNrQougHHbghNG8DHNs5SXF3j0Wr2/asDJ/XjeFjLpZLdTSKWiWC13a9NpyhVDfyZ SfRA== X-Gm-Message-State: AOJu0YzissOuPG6YS8+wQMMdAH7YqAsAIajqOD4RlzJsCk74tndmyjdB YXdj0+Isc3tDkK5WYUfw4RFJIBadOYabcpDJ3Hm09pQaORwbFSVHIdKBhfW0BznL+v+ngUAF4Vb l X-Google-Smtp-Source: AGHT+IFZ9Sy319CjhI45/V5IZKkOlNhH8U2rJ88uswsymdU6IatcsKesj+kb+i06BUYRJNfWCzBv3g== X-Received: by 2002:a2e:9e4f:0:b0:2f0:29e4:dc52 with SMTP id 38308e7fff4ca-2f19de48a8fmr22169031fa.27.1723160332807; Thu, 08 Aug 2024 16:38:52 -0700 (PDT) To: devel@lists.libvirt.org Subject: [PATCH 17/20] include: Define constants for parallel save/restore Date: Thu, 8 Aug 2024 17:38:10 -0600 Message-Id: <20240808233813.22905-18-jfehlig@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20240808233813.22905-1-jfehlig@suse.com> References: <20240808233813.22905-1-jfehlig@suse.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-ID-Hash: J6RIILVTTWRUQCMGNBKVFK5BMT2Y6ONR X-Message-ID-Hash: J6RIILVTTWRUQCMGNBKVFK5BMT2Y6ONR X-MailFrom: jfehlig@suse.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-config-1; header-match-config-2; header-match-config-3; header-match-devel.lists.libvirt.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header CC: farosas@suse.de, Claudio Fontana X-Mailman-Version: 3.2.2 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Post: List-Subscribe: List-Unsubscribe: From: Jim Fehlig via Devel Reply-To: Jim Fehlig X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZM-MESSAGEID: 1723160880474116600 Content-Type: text/plain; charset="utf-8" From: Claudio Fontana Add a new VIR_DOMAIN_SAVE_PARALLEL flag to the save and restore APIs, which can be used to specify the use of multiple, parallel channels for saving a domain. The number of parallel channels can be set using the VIR_DOMAIN_SAVE_PARAM_PARALLEL_CONNECTIONS typed parameter. Signed-off-by: Claudio Fontana Signed-off-by: Jim Fehlig --- include/libvirt/libvirt-domain.h | 13 +++++++++++++ src/libvirt-domain.c | 6 ++++++ 2 files changed, 19 insertions(+) diff --git a/include/libvirt/libvirt-domain.h b/include/libvirt/libvirt-dom= ain.h index 4266237abe..f4bf9c3cdb 100644 --- a/include/libvirt/libvirt-domain.h +++ b/include/libvirt/libvirt-domain.h @@ -1596,6 +1596,7 @@ typedef enum { VIR_DOMAIN_SAVE_RUNNING =3D 1 << 1, /* Favor running over paused = (Since: 0.9.5) */ VIR_DOMAIN_SAVE_PAUSED =3D 1 << 2, /* Favor paused over running = (Since: 0.9.5) */ VIR_DOMAIN_SAVE_RESET_NVRAM =3D 1 << 3, /* Re-initialize NVRAM from t= emplate (Since: 8.1.0) */ + VIR_DOMAIN_SAVE_PARALLEL =3D 1 << 4, /* Save and restore using par= allel channels (Since: 10.6.0) */ } virDomainSaveRestoreFlags; =20 int virDomainSave (virDomainPtr domain, @@ -1641,6 +1642,18 @@ int virDomainRestoreParams (vir= ConnectPtr conn, */ # define VIR_DOMAIN_SAVE_PARAM_DXML "dxml" =20 +/** + * VIR_DOMAIN_SAVE_PARAM_PARALLEL_CONNECTIONS: + * + * this optional parameter mirrors the migration parameter + * VIR_MIGRATE_PARAM_PARALLEL_CONNECTIONS. + * + * It specifies the number of extra connections to use when transfering st= ate. + * + * Since: 10.6.0 + */ +# define VIR_DOMAIN_SAVE_PARAM_PARALLEL_CONNECTIONS "parallel.connecti= ons" + /* See below for virDomainSaveImageXMLFlags */ char * virDomainSaveImageGetXMLDesc (virConnectPtr conn, const char *file, diff --git a/src/libvirt-domain.c b/src/libvirt-domain.c index 5aedae1b49..32508a4ede 100644 --- a/src/libvirt-domain.c +++ b/src/libvirt-domain.c @@ -1010,6 +1010,9 @@ virDomainSaveFlags(virDomainPtr domain, const char *t= o, * If VIR_DOMAIN_SAVE_PARAM_FILE is not provided then a managed save is * performed (see virDomainManagedSave). * + * See VIR_DOMAIN_SAVE_PARAM_* for detailed description of accepted save + * parameters. + * * Returns 0 in case of success and -1 in case of failure. * * Since: 8.4.0 @@ -1222,6 +1225,9 @@ virDomainRestoreFlags(virConnectPtr conn, const char = *from, const char *dxml, * now, VIR_DOMAIN_SAVE_PARAM_FILE is required but this requirement may * be lifted in the future. * + * See VIR_DOMAIN_SAVE_PARAM_* for detailed description of accepted + * restore parameters. + * * Returns 0 in case of success and -1 in case of failure. * * Since: 8.4.0 --=20 2.35.3