From nobody Mon Dec 15 13:39:33 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623227579; cv=none; d=zohomail.com; s=zohoarc; b=jh1G+goxMW91o+ATv/9DAccGm7H6wcn3pvc+bPQSjBIu0ZWIInTMelCL9VVnSkxdWLHMKk+pXyA7rJwqIEN+IEKNnvb82K5rKc3FddbxiuGGcfNWWIemMRdJ7ecqgQlet78dsZjinT6luAs/YMQhsQwOHDKnEUYnkngQ1vWvsxM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623227579; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=9R6SvtOpBZWgf7Qa1D1Ot8H4l7GbQMCnxcN4HSYdlko=; b=DvUXSzH+gimItTuB8qYwgK+pQ1YDmy7Shqmz16BoYFNajmr2xZ0FBajhhES+lbiB1vzL5+P9fbrO+VXUqaIuhMq0OWKq8pERUPYsdubA+NY+oXgYTdCuc6ueA0IJscVl34K04y1baPSHfGJQd6VnWHVcSSUKSWwM4DZtHOaWpDk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1623227579201727.9593314132944; Wed, 9 Jun 2021 01:32:59 -0700 (PDT) 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-39-oo_GbZV2MBmVXpgKlJMJvQ-1; Wed, 09 Jun 2021 04:32:56 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id DDD2580ED8B; Wed, 9 Jun 2021 08:32:50 +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 BDC2D60853; Wed, 9 Jun 2021 08:32:50 +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 846A31801266; Wed, 9 Jun 2021 08:32:50 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 1598WmOL022944 for ; Wed, 9 Jun 2021 04:32:48 -0400 Received: by smtp.corp.redhat.com (Postfix) id B90FC60917; Wed, 9 Jun 2021 08:32:48 +0000 (UTC) Received: from localhost.localdomain.com (ovpn-12-36.pek2.redhat.com [10.72.12.36]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6E3A260853; Wed, 9 Jun 2021 08:32:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1623227578; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=9R6SvtOpBZWgf7Qa1D1Ot8H4l7GbQMCnxcN4HSYdlko=; b=LaQutrSxHNtkh1zATa2ZZiN7jY5qCeRZl3vCYtCQDW8rLeWYSM7kQ4cWHXJHhtXniRv7zt PVjGUymM1GTi6Cyk7LZygSqoWYkT8EmfFs7VRhzlJtUlQiIooqw0YKMFF342iFZnyiU+tQ 0Q2qBMg96oAG4bQk5K88Jj8f/GZKens= X-MC-Unique: oo_GbZV2MBmVXpgKlJMJvQ-1 From: Han Han To: libvir-list@redhat.com Subject: [PATCH v2 3/6] qemu_validate: Validate virtio*gl* devices for 3d accerlation Date: Wed, 9 Jun 2021 16:32:24 +0800 Message-Id: <20210609083227.404563-4-hhan@redhat.com> In-Reply-To: <20210609083227.404563-1-hhan@redhat.com> References: <20210609083227.404563-1-hhan@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-loop: libvir-list@redhat.com Cc: Han Han 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.79 on 10.5.11.13 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-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" The devices virtio-gpu-gl-pci and virtio-vga-gl, aimed to replace the virgl property, are valid for 3d accerlation as well. Signed-off-by: Han Han --- src/qemu/qemu_validate.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/qemu/qemu_validate.c b/src/qemu/qemu_validate.c index 669c45b3c5..75e3db6ca9 100644 --- a/src/qemu/qemu_validate.c +++ b/src/qemu/qemu_validate.c @@ -2364,7 +2364,9 @@ qemuValidateDomainDeviceDefVideo(const virDomainVideo= Def *video, } else if (video->accel) { if (video->accel->accel3d =3D=3D VIR_TRISTATE_SWITCH_ON && (video->type !=3D VIR_DOMAIN_VIDEO_TYPE_VIRTIO || - !virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_GPU_VIRGL))) { + !(virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_GPU_VIRGL) || + virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_GPU_GL_PCI) || + virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_VGA_GL)))) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, _("%s 3d acceleration is not supported"), virDomainVideoTypeToString(video->type)); --=20 2.31.1