From nobody Sun Oct 5 01:49:59 2025 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=1758826717; cv=none; d=zohomail.com; s=zohoarc; b=YnaTlBGvkRaWN9AE63a1GnL0AhhYKc+TMDBz59RDEYj4B53Td8X1ZqGqfAzxcu4BNk3AT3J5eg18yrBiOkWyT24I8069ED6X7/Lb0IM64ZKqIDZwOhodr0rlKa+gQd2FFiQyTpbtNY6cWdYt8bg4W3iL7e7C/ctCPJZO4uxvsB8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1758826717; h=Content-Type:Content-Transfer-Encoding:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Owner:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Reply-To:References:Subject:Subject:To:To:Message-Id:Cc; bh=i8unUhPG9iwgBPWLjFBiCPq8tngnUyB7GCCaJZgy6jk=; b=cV4sNNcizA6/WCzV85BnZyDtGqldvE1cqRziLzZhP7zUBxEmGFHE3CujhnrMhtMDPICw82hbqAh6BIzcNf8f42Rz7srGg1qVyCTW6GUvPXABscTJGQ38L6++qDlurCtoT7wDP3Fyuxw40xAXrujq0JepHSl9K3UnnB8IJfl0E94= 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 1758826717675981.5141909813; Thu, 25 Sep 2025 11:58:37 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 993) id B2255440E1; Thu, 25 Sep 2025 14:58:36 -0400 (EDT) Received: from [172.19.199.14] (lists.libvirt.org [8.43.85.245]) by lists.libvirt.org (Postfix) with ESMTP id 3B7C343F8A; Thu, 25 Sep 2025 14:20:43 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 993) id EF27841BE3; Thu, 25 Sep 2025 14:16:39 -0400 (EDT) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (3072 bits) server-digest SHA256) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id 3219844103 for ; Thu, 25 Sep 2025 14:08:00 -0400 (EDT) Received: from mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-345-I88wPKBYM3uivshT_gfySw-1; Thu, 25 Sep 2025 14:07:57 -0400 Received: from mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 2A97A19560B5 for ; Thu, 25 Sep 2025 18:07:57 +0000 (UTC) Received: from harajuku.usersys.redhat.com.homenet.telecomitalia.it (unknown [10.45.225.196]) by mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 57DF030002D2 for ; Thu, 25 Sep 2025 18:07:56 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-3.1 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED,RCVD_IN_VALIDITY_RPBL_BLOCKED, RCVD_IN_VALIDITY_SAFE_BLOCKED,SPF_PASS autolearn=unavailable autolearn_force=no version=4.0.1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1758823679; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=i8unUhPG9iwgBPWLjFBiCPq8tngnUyB7GCCaJZgy6jk=; b=GM2amZdr59xDCJ7WhyXqknt5Ff65P8FLt/b/turUGtE8MXaHdVRepL0bqqnH8+aW0hdIjc 87LiAil6MKARbqChpEEIjX9TiAzlzlK/jUkmu51ZovJuGWUu3EPgRgS2usWmOecCALP9qu ysNNeFhvl5XZvmvlGz9Siafz/YprBMg= X-MC-Unique: I88wPKBYM3uivshT_gfySw-1 X-Mimecast-MFC-AGG-ID: I88wPKBYM3uivshT_gfySw_1758823677 To: devel@lists.libvirt.org Subject: [PATCH v2 21/38] qemu: Don't generate alias for model=none USB controllers Date: Thu, 25 Sep 2025 20:07:07 +0200 Message-ID: <20250925180724.500758-22-abologna@redhat.com> In-Reply-To: <20250925180724.500758-1-abologna@redhat.com> References: <20250925180724.500758-1-abologna@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.4 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: NqLJCG14uj-0WVYFA1ZNqscFthtlPheTiuEGATydMjU_1758823677 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Message-ID-Hash: 2C3KIJM4B7LFOZEGOOFJKTVPZIS7LZN5 X-Message-ID-Hash: 2C3KIJM4B7LFOZEGOOFJKTVPZIS7LZN5 X-MailFrom: abologna@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; header-match-devel.lists.libvirt.org-0; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Andrea Bolognani via Devel Reply-To: Andrea Bolognani X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZM-MESSAGEID: 1758826719440116600 Content-Type: text/plain; charset="utf-8"; x-default="true" That obviously doesn't make sense, since the value is used to indicate the absence of a USB controller. Signed-off-by: Andrea Bolognani Reviewed-by: Peter Krempa --- src/qemu/qemu_alias.c | 3 +++ .../qemuhotplug-base-ccw-live+ccw-virtio.xml | 4 +--- ...g-base-ccw-live-with-2-ccw-virtio+ccw-virtio-1-reverse.xml | 4 +--- .../qemuhotplug-base-ccw-live-with-2-ccw-virtio.xml | 4 +--- ...ug-base-ccw-live-with-ccw-virtio+ccw-virtio-2-explicit.xml | 4 +--- ...qemuhotplug-base-ccw-live-with-ccw-virtio+ccw-virtio-2.xml | 4 +--- .../qemuhotplug-base-ccw-live-with-ccw-virtio.xml | 4 +--- tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live.xml | 4 +--- 8 files changed, 10 insertions(+), 21 deletions(-) diff --git a/src/qemu/qemu_alias.c b/src/qemu/qemu_alias.c index a27c688d79..b0bc057bd1 100644 --- a/src/qemu/qemu_alias.c +++ b/src/qemu/qemu_alias.c @@ -184,6 +184,9 @@ qemuAssignDeviceControllerAlias(virDomainDef *domainDef, return; } } else if (controller->type =3D=3D VIR_DOMAIN_CONTROLLER_TYPE_USB) { + if (controller->model =3D=3D VIR_DOMAIN_CONTROLLER_MODEL_USB_NONE) + return; + /* first USB device is "usb", others are normal "usb%d" */ if (controller->idx =3D=3D 0) { controller->info.alias =3D g_strdup("usb"); diff --git a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live+ccw-vir= tio.xml b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live+ccw-virtio= .xml index 300dea1382..4b1c7ca6b4 100644 --- a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live+ccw-virtio.xml +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live+ccw-virtio.xml @@ -29,9 +29,7 @@
- - - +
diff --git a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-2-= ccw-virtio+ccw-virtio-1-reverse.xml b/tests/qemuhotplugtestdomains/qemuhotp= lug-base-ccw-live-with-2-ccw-virtio+ccw-virtio-1-reverse.xml index 882a509eeb..ae4b1e48a7 100644 --- a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-2-ccw-vir= tio+ccw-virtio-1-reverse.xml +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-2-ccw-vir= tio+ccw-virtio-1-reverse.xml @@ -39,9 +39,7 @@
- - - +
diff --git a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-2-= ccw-virtio.xml b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-wit= h-2-ccw-virtio.xml index 6167d54bd2..428b8a41fa 100644 --- a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-2-ccw-vir= tio.xml +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-2-ccw-vir= tio.xml @@ -29,9 +29,7 @@
- - - +
diff --git a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-cc= w-virtio+ccw-virtio-2-explicit.xml b/tests/qemuhotplugtestdomains/qemuhotpl= ug-base-ccw-live-with-ccw-virtio+ccw-virtio-2-explicit.xml index 67a5c84a6c..ca6faf615a 100644 --- a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-ccw-virti= o+ccw-virtio-2-explicit.xml +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-ccw-virti= o+ccw-virtio-2-explicit.xml @@ -38,9 +38,7 @@
- - - +
diff --git a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-cc= w-virtio+ccw-virtio-2.xml b/tests/qemuhotplugtestdomains/qemuhotplug-base-c= cw-live-with-ccw-virtio+ccw-virtio-2.xml index 67a5c84a6c..ca6faf615a 100644 --- a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-ccw-virti= o+ccw-virtio-2.xml +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-ccw-virti= o+ccw-virtio-2.xml @@ -38,9 +38,7 @@
- - - +
diff --git a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-cc= w-virtio.xml b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-= ccw-virtio.xml index 07bbfa24a2..a2ec796490 100644 --- a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-ccw-virti= o.xml +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live-with-ccw-virti= o.xml @@ -28,9 +28,7 @@
- - - +
diff --git a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live.xml b/t= ests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live.xml index 4869103a06..1d1e5eb142 100644 --- a/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live.xml +++ b/tests/qemuhotplugtestdomains/qemuhotplug-base-ccw-live.xml @@ -19,9 +19,7 @@ restart /usr/bin/qemu-system-s390x - - - +
--=20 2.51.0