From nobody Sun Feb 8 13:45:00 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=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1550845926031555.3027069533166; Fri, 22 Feb 2019 06:32:06 -0800 (PST) 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 mx1.redhat.com (Postfix) with ESMTPS id 5E1E5C057F48; Fri, 22 Feb 2019 14:32:04 +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 229521A92D; Fri, 22 Feb 2019 14:32:04 +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 D75FE181A048; Fri, 22 Feb 2019 14:32:03 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id x1LFgau2008261 for ; Thu, 21 Feb 2019 10:42:36 -0500 Received: by smtp.corp.redhat.com (Postfix) id 00B2127CCF; Thu, 21 Feb 2019 15:42:36 +0000 (UTC) Received: from icr.brq.redhat.com (unknown [10.43.2.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7CD5927BC2 for ; Thu, 21 Feb 2019 15:42:35 +0000 (UTC) From: =?UTF-8?q?J=C3=A1n=20Tomko?= To: libvir-list@redhat.com Date: Thu, 21 Feb 2019 16:42:23 +0100 Message-Id: <5eeee88b20f0228654d9feb6f7e7982b3aa16b8d.1550763719.git.jtomko@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 1/8] DO NOT PUSH: allow skipping selected lines in group-qemu-caps.pl 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: , 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.23 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Fri, 22 Feb 2019 14:32:04 +0000 (UTC) Content-Type: text/plain; charset="utf-8" After running: tests/group-qemu-caps.pl the capabilities with numbers in the skip function will be dropped from qemu_capabilities.[ch] and printed into qemu_capabilities.[ch].dropped. --- tests/group-qemu-caps.pl | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/tests/group-qemu-caps.pl b/tests/group-qemu-caps.pl index 514764f47f..6b761520d8 100755 --- a/tests/group-qemu-caps.pl +++ b/tests/group-qemu-caps.pl @@ -55,6 +55,17 @@ if (®roup_caps($prefix . 'src/qemu/qemu_capabilities.= h', =20 exit $ret; =20 +sub skip { + my $num =3D shift; + + return 0; # coverity[dead_error_begin] + + foreach my $i (0 .. 12, 14 .. 32, 34 .. 45, 47 .. 49, 51 .. 53, 56, 57= , 59, 60, 65, 74 .. 76, 79, 81 .. 86, 90, 92 .. 94, 99, 100, 111, 112, 116,= 117, 126, 127, 133, 135 .. 137, 143 .. 145, 147, 150, 151, 164, 166, 221, = 226, 230) { + return 1 if ($i =3D=3D $num); + } + return 0; +} + sub regroup_caps { my $filename =3D shift; my $start_regex =3D shift; @@ -67,6 +78,10 @@ sub regroup_caps { my @original =3D ; close FILE; =20 + my $dropped =3D $filename . ".dropped"; + + open DROPPED, '>', $dropped or die "cannot open $dropped: $!"; + my @fixed; my $game_on =3D 0; my $counter =3D 0; @@ -74,6 +89,11 @@ sub regroup_caps { if ($game_on) { next if ($_ =3D~ '/\* [0-9]+ \*/'); next if (/^\s+$/); + if (skip($counter)) { + print DROPPED "$_"; + $counter++; + next; + } if ($counter % $step =3D=3D 0) { if ($counter !=3D 0) { push @fixed, "\n"; @@ -120,5 +140,6 @@ sub regroup_caps { print FILE $line; } close FILE; + close DROPPED; } } --=20 2.19.2 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list