From nobody Sat Feb 7 15:15:33 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail(p=none dis=none) header.from=linux.ibm.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1531306233203688.9324165456737; Wed, 11 Jul 2018 03:50:33 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.25]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id BD16F308626E; Wed, 11 Jul 2018 10:50:31 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 69E312010D64; Wed, 11 Jul 2018 10:50:31 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id DADE718037F7; Wed, 11 Jul 2018 10:50:30 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w6BAoTB4017855 for ; Wed, 11 Jul 2018 06:50:29 -0400 Received: by smtp.corp.redhat.com (Postfix) id 126D0308BDB0; Wed, 11 Jul 2018 10:50:29 +0000 (UTC) Received: from mx1.redhat.com (ext-mx04.extmail.prod.ext.phx2.redhat.com [10.5.110.28]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 0435C308BDAC for ; Wed, 11 Jul 2018 10:50:24 +0000 (UTC) Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id A1A078110D for ; Wed, 11 Jul 2018 10:50:23 +0000 (UTC) Received: from pps.filterd (m0098410.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w6BAoFo5001424 for ; Wed, 11 Jul 2018 06:50:23 -0400 Received: from e06smtp02.uk.ibm.com (e06smtp02.uk.ibm.com [195.75.94.98]) by mx0a-001b2d01.pphosted.com with ESMTP id 2k5db9fvs2-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 11 Jul 2018 06:50:21 -0400 Received: from localhost by e06smtp02.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 11 Jul 2018 11:49:40 +0100 Received: from b06cxnps4076.portsmouth.uk.ibm.com (9.149.109.198) by e06smtp02.uk.ibm.com (192.168.101.132) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Wed, 11 Jul 2018 11:49:39 +0100 Received: from d06av25.portsmouth.uk.ibm.com (d06av25.portsmouth.uk.ibm.com [9.149.105.61]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id w6BAnbR840501368 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Wed, 11 Jul 2018 10:49:37 GMT Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 6F38F11C054; Wed, 11 Jul 2018 13:49:59 +0100 (BST) Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 4EF3611C04C; Wed, 11 Jul 2018 13:49:59 +0100 (BST) Received: from s38lp19.boeblingen.de.ibm.com (unknown [9.152.161.19]) by d06av25.portsmouth.uk.ibm.com (Postfix) with ESMTP; Wed, 11 Jul 2018 13:49:59 +0100 (BST) From: Bjoern Walk To: libvir-list@redhat.com Date: Wed, 11 Jul 2018 12:49:17 +0200 In-Reply-To: <20180711104922.26783-1-bwalk@linux.ibm.com> References: <20180711104922.26783-1-bwalk@linux.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 18071110-0008-0000-0000-00000251E9CB X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18071110-0009-0000-0000-000021B81CED Message-Id: <20180711104922.26783-5-bwalk@linux.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2018-07-11_02:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=1 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1806210000 definitions=main-1807110116 X-Greylist: Sender passed SPF test, Sender IP whitelisted by DNSRBL, ACL 207 matched, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Wed, 11 Jul 2018 10:50:23 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Wed, 11 Jul 2018 10:50:23 +0000 (UTC) for IP:'148.163.156.1' DOMAIN:'mx0a-001b2d01.pphosted.com' HELO:'mx0a-001b2d01.pphosted.com' FROM:'bwalk@linux.ibm.com' RCPT:'' X-RedHat-Spam-Score: -0.701 (RCVD_IN_DNSWL_LOW, SPF_PASS) 148.163.156.1 mx0a-001b2d01.pphosted.com 148.163.156.1 mx0a-001b2d01.pphosted.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.28 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.24 X-loop: libvir-list@redhat.com Cc: Bjoern Walk Subject: [libvirt] [PATCH 4/9] remote: implement remoteDomainGetStateParams X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.25 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.49]); Wed, 11 Jul 2018 10:50:32 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Implement the API function virDomainGetStateParams for the remote driver and wire up the remote protocol. Reviewed-by: Stefan Zimmermann Reviewed-by: Boris Fiuczynski Signed-off-by: Bjoern Walk --- src/remote/remote_daemon_dispatch.c | 1 - src/remote/remote_driver.c | 1 + src/remote/remote_protocol.x | 20 +++++++++++++++++++- src/remote_protocol-structs | 11 +++++++++++ 4 files changed, 31 insertions(+), 2 deletions(-) diff --git a/src/remote/remote_daemon_dispatch.c b/src/remote/remote_daemon= _dispatch.c index 4a93f09a..57623b6d 100644 --- a/src/remote/remote_daemon_dispatch.c +++ b/src/remote/remote_daemon_dispatch.c @@ -4159,7 +4159,6 @@ remoteDispatchDomainGetState(virNetServerPtr server A= TTRIBUTE_UNUSED, return rv; } =20 - /* Due to back-compat reasons, two RPC calls map to the same libvirt * API of virConnectDomainEventRegisterAny. A client should only use * the new call if they have probed diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index 1d94c2e4..e2a79c48 100644 --- a/src/remote/remote_driver.c +++ b/src/remote/remote_driver.c @@ -8347,6 +8347,7 @@ static virHypervisorDriver hypervisor_driver =3D { .domainSetPerfEvents =3D remoteDomainSetPerfEvents, /* 1.3.3 */ .domainGetInfo =3D remoteDomainGetInfo, /* 0.3.0 */ .domainGetState =3D remoteDomainGetState, /* 0.9.2 */ + .domainGetStateParams =3D remoteDomainGetStateParams, /* 4.6.0 */ .domainGetControlInfo =3D remoteDomainGetControlInfo, /* 0.9.3 */ .domainSave =3D remoteDomainSave, /* 0.3.0 */ .domainSaveFlags =3D remoteDomainSaveFlags, /* 0.9.4 */ diff --git a/src/remote/remote_protocol.x b/src/remote/remote_protocol.x index 28c8feba..43d5db89 100644 --- a/src/remote/remote_protocol.x +++ b/src/remote/remote_protocol.x @@ -262,6 +262,9 @@ const REMOTE_NODE_SEV_INFO_MAX =3D 64; /* Upper limit on number of launch security information entries */ const REMOTE_DOMAIN_LAUNCH_SECURITY_INFO_PARAMS_MAX =3D 64; =20 +/* Upper limit on number of state parameter entries */ +const REMOTE_DOMAIN_STATE_PARAMETERS_MAX =3D 16; + /* UUID. VIR_UUID_BUFLEN definition comes from libvirt.h */ typedef opaque remote_uuid[VIR_UUID_BUFLEN]; =20 @@ -2781,6 +2784,15 @@ struct remote_domain_get_state_ret { int reason; }; =20 +struct remote_domain_get_state_params_args { + remote_nonnull_domain dom; + unsigned int flags; +}; + +struct remote_domain_get_state_params_ret { + remote_typed_param params; /* allo= c@1@int@2 */ +}; + struct remote_domain_migrate_begin3_args { remote_nonnull_domain dom; remote_string xmlin; @@ -6312,5 +6324,11 @@ enum remote_procedure { * @acl: connect:search_nwfilter_bindings * @aclfilter: nwfilter_binding:getattr */ - REMOTE_PROC_CONNECT_LIST_ALL_NWFILTER_BINDINGS =3D 401 + REMOTE_PROC_CONNECT_LIST_ALL_NWFILTER_BINDINGS =3D 401, + + /** + * @generate: both + * @acl: domain:read + */ + REMOTE_PROC_DOMAIN_GET_STATE_PARAMS =3D 402 }; diff --git a/src/remote_protocol-structs b/src/remote_protocol-structs index 6343e146..a19b9730 100644 --- a/src/remote_protocol-structs +++ b/src/remote_protocol-structs @@ -2153,6 +2153,16 @@ struct remote_domain_get_state_ret { int state; int reason; }; +struct remote_domain_get_state_params_args { + remote_nonnull_domain dom; + u_int flags; +}; +struct remote_domain_get_state_params_ret { + struct { + u_int params_len; + remote_typed_param * params_val; + } params; +}; struct remote_domain_migrate_begin3_args { remote_nonnull_domain dom; remote_string xmlin; @@ -3368,4 +3378,5 @@ enum remote_procedure { REMOTE_PROC_NWFILTER_BINDING_CREATE_XML =3D 399, REMOTE_PROC_NWFILTER_BINDING_DELETE =3D 400, REMOTE_PROC_CONNECT_LIST_ALL_NWFILTER_BINDINGS =3D 401, + REMOTE_PROC_DOMAIN_GET_STATE_PARAMS =3D 402, }; --=20 2.17.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list