From nobody Sun Feb 8 10:50:22 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) client-ip=170.10.129.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail(p=none dis=none) header.from=gmail.com Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.zohomail.com with SMTPS id 1636555186241292.1163982185128; Wed, 10 Nov 2021 06:39:46 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-323-_Ltje8CfM1GekWnhatt__A-1; Wed, 10 Nov 2021 09:39:43 -0500 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 9B7D98B428F; Wed, 10 Nov 2021 14:39:14 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id BF6521700F; Wed, 10 Nov 2021 14:39:12 +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 4F7725533F; Wed, 10 Nov 2021 14:39:11 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 1AAEOuZL020146 for ; Wed, 10 Nov 2021 09:24:56 -0500 Received: by smtp.corp.redhat.com (Postfix) id 737212026D48; Wed, 10 Nov 2021 14:24:56 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast06.extmail.prod.ext.rdu2.redhat.com [10.11.55.22]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 6DA512026D65 for ; Wed, 10 Nov 2021 14:24:56 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 10006185A7B2 for ; Wed, 10 Nov 2021 14:24:56 +0000 (UTC) Received: from mail-pf1-f178.google.com (mail-pf1-f178.google.com [209.85.210.178]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-32-2Ifk7l3rMWCcAYO5UuZPKg-1; Wed, 10 Nov 2021 09:24:54 -0500 Received: by mail-pf1-f178.google.com with SMTP id c126so2855995pfb.0 for ; Wed, 10 Nov 2021 06:24:54 -0800 (PST) Received: from localhost ([2400:ddc0:1000::b373:390c]) by smtp.gmail.com with ESMTPSA id p25sm22990935pfh.86.2021.11.10.06.24.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Nov 2021 06:24:52 -0800 (PST) X-MC-Unique: _Ltje8CfM1GekWnhatt__A-1 X-MC-Unique: 2Ifk7l3rMWCcAYO5UuZPKg-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=TE4EUMHchfU7MrbIDSoBZs3NrEqTAg+OlO1shhtgri0=; b=x137ND3K1X2Jmyl/2evusnKreIQGTroEH7UekokBzj9mQp9YaApxqSlDgdJmoU+ASY 0eGfjoHiu++lxCtAggNfEwmrnx2OcPeNgi/CJJH6ekLmdl1ZxJb1mBT5lk+vz2vC5kCb SM25MUhquOaGQmD8vZwBtGQ+zqxwGkfUfmuSXtjaslywO567CImZjW5qrvRIuxKf2VlE Vn/zbizVl/RvOir13+1JO4DvRlOwLcpV3WVJ0aLpJnnGVrSAUpYE6KvRj7x5ToEBYe1S X8aw20Ze6ZH6ZyigR7yiFzIgYqQ8gNkCGU6Q1IqbqqUqC6DhTVe1N6GK95HV19C3ZjAz pWGA== X-Gm-Message-State: AOAM531BwBtrFrCvAjfRerK1EhET8aSc85LAaaWq6YC7IozsJwkFYngA jWKOUMXuFd/hlnqhI1QfWLbcet6GJRfoXrQR X-Google-Smtp-Source: ABdhPJxzqho1UIT2auV4WEsFX5nGeOoO98zJmiPOaQ8c5m8Vv/uwqHmEKhtn+qw/JOxNyLLr/MdfuQ== X-Received: by 2002:a63:8f02:: with SMTP id n2mr170304pgd.270.1636554292954; Wed, 10 Nov 2021 06:24:52 -0800 (PST) From: Luke Yue To: libvir-list@redhat.com Subject: [PATCH v3 04/12] test_driver: Implement virDomainDetachDeviceAlias Date: Wed, 10 Nov 2021 22:24:23 +0800 Message-Id: <20211110142431.10622-5-lukedyue@gmail.com> In-Reply-To: <20211110142431.10622-1-lukedyue@gmail.com> References: <20211110142431.10622-1-lukedyue@gmail.com> MIME-Version: 1.0 X-Mimecast-Impersonation-Protect: Policy=CLT - Impersonation Protection Definition; Similar Internal Domain=false; Similar Monitored External Domain=false; Custom External Domain=false; Mimecast External Domain=false; Newly Observed Domain=false; Internal User Name=false; Custom Display Name List=false; Reply-to Address Mismatch=false; Targeted Threat Dictionary=false; Mimecast Threat Dictionary=false; Custom Threat Dictionary=false X-Scanned-By: MIMEDefang 2.78 on 10.11.54.4 X-loop: libvir-list@redhat.com 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: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZM-MESSAGEID: 1636555187687100001 Content-Type: text/plain; charset="utf-8" As we already implement testDomainChgDevice for both DetachDeviceFlags and DetachDeviceAlias, so it's simple to implement this API by changing the parameter. Signed-off-by: Luke Yue --- src/test/test_driver.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/test/test_driver.c b/src/test/test_driver.c index 6a7eb12f77..9843340fec 100644 --- a/src/test/test_driver.c +++ b/src/test/test_driver.c @@ -10252,6 +10252,15 @@ testDomainDetachDeviceFlags(virDomainPtr dom, xml, NULL, flags); } =20 +static int +testDomainDetachDeviceAlias(virDomainPtr dom, + const char *alias, + unsigned int flags) +{ + return testDomainChgDevice(dom, VIR_DOMAIN_DEVICE_ACTION_DETACH, + NULL, alias, flags); +} + /* * Test driver */ @@ -10349,6 +10358,7 @@ static virHypervisorDriver testHypervisorDriver =3D= { .domainFSFreeze =3D testDomainFSFreeze, /* 5.7.0 */ .domainFSThaw =3D testDomainFSThaw, /* 5.7.0 */ .domainFSTrim =3D testDomainFSTrim, /* 5.7.0 */ + .domainDetachDeviceAlias =3D testDomainDetachDeviceAlias, /* 7.10.0 */ .domainDetachDeviceFlags =3D testDomainDetachDeviceFlags, /* 7.10.0 */ .domainGetAutostart =3D testDomainGetAutostart, /* 0.3.2 */ .domainSetAutostart =3D testDomainSetAutostart, /* 0.3.2 */ --=20 2.33.1