From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51871) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a0vBu-00010I-I1 for qemu-devel@nongnu.org; Mon, 23 Nov 2015 12:46:15 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a0vBr-0000ky-4K for qemu-devel@nongnu.org; Mon, 23 Nov 2015 12:46:14 -0500 Received: from mx1.redhat.com ([209.132.183.28]:35347) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a0vBq-0000kq-Qr for qemu-devel@nongnu.org; Mon, 23 Nov 2015 12:46:11 -0500 Date: Mon, 23 Nov 2015 17:46:06 +0000 From: "Daniel P. Berrange" Message-ID: <20151123174606.GR18085@redhat.com> References: <1447694618-17177-3-git-send-email-marcandre.lureau@redhat.com> <1447837378-25222-1-git-send-email-marcandre.lureau@redhat.com> <20151118224821-mutt-send-email-mst@redhat.com> <56534FAA.4090101@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <56534FAA.4090101@redhat.com> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH] exec: silence hugetlbfs warning under qtest Reply-To: "Daniel P. Berrange" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Amit Shah , marcandre.lureau@redhat.com, qemu-devel@nongnu.org, Peter Maydell , "Michael S. Tsirkin" On Mon, Nov 23, 2015 at 06:40:58PM +0100, Paolo Bonzini wrote: >=20 >=20 > On 18/11/2015 21:49, Michael S. Tsirkin wrote: > > On Wed, Nov 18, 2015 at 10:02:58AM +0100, marcandre.lureau@redhat.com= wrote: > >> From: Marc-Andr=C3=A9 Lureau > >> > >> vhost-user-test prints a warning. A test should not need to run on > >> hugetlbfs, let's silence the warning under qtest. The > >> condition can't check on qtest_enabled() since vhost-user-test actua= lly > >> doesn't use qtest accel. However, qtest_driver() can be used, if > >> qtest_init() is called early enough. For that reason, move chardev a= nd > >> qtest initialization early. > >> > >> Signed-off-by: Marc-Andr=C3=A9 Lureau > >=20 > > Seems ok, and let us bring back the 2.4 test that was > > dropped in 2.5, but I'd like an ack on this from someone else. >=20 > I wonder if we need the warning at all, but this patch is okay. >=20 > Anyhow: >=20 >=20 >=20 > - if (qemu_opts_foreach(qemu_find_opts("object"), > - object_create, > - object_create_initial, NULL)) { > + if (qemu_opts_foreach(qemu_find_opts("chardev"), > + chardev_init_func, NULL, NULL)) { > exit(1); > } >=20 > - if (qemu_opts_foreach(qemu_find_opts("chardev"), > - chardev_init_func, NULL, NULL)) { > + if (qtest_chrdev) { > + Error *local_err =3D NULL; > + qtest_init(qtest_chrdev, qtest_log, &local_err); > + if (local_err) { > + error_report_err(local_err); > + exit(1); > + } > + } > + > + if (qemu_opts_foreach(qemu_find_opts("object"), > + object_create, > + object_create_initial, NULL)) { > exit(1); > } >=20 >=20 > Before: object-initial, chardev, qtest, object-late (not in the patch) >=20 > After: chardev, qtest, object-initial, object-late (not in the patch) >=20 > Objects must be initialized before chardev (except rng-egd) since in th= e > future chardev will need to use objects, in particular secret objects. > Was the swap intentional? Yeah, that is essentially reverting my patch to split up object creation: commit f08f9271bfe3f19a5eb3d7a2f48532065304d5c8 Author: Daniel P. Berrange Date: Wed May 13 17:14:04 2015 +0100 vl: Create (most) objects before creating chardev backends So I'd rather we did not do that. IMHO having the goal that all objects be created first is the right long term direction, if we view the future as being 100% object based. Hence most of the object types are created on object-initial, and only a few things in object-late. Regards, Daniel --=20 |: http://berrange.com -o- http://www.flickr.com/photos/dberrange= / :| |: http://libvirt.org -o- http://virt-manager.or= g :| |: http://autobuild.org -o- http://search.cpan.org/~danberr= / :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vn= c :|