From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Kiszka Subject: Re: [PATCH] qemu-kvm: Consolidate kvm_eat_signals Date: Mon, 12 May 2008 13:42:11 +0200 Message-ID: <48282D13.9060903@web.de> References: <482820DC.6030509@web.de> <48282B16.7050006@qumranet.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1013311266==" Cc: kvm-devel To: Avi Kivity Return-path: In-Reply-To: <48282B16.7050006@qumranet.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces@lists.sourceforge.net Errors-To: kvm-devel-bounces@lists.sourceforge.net List-Id: kvm.vger.kernel.org This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --===============1013311266== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig2C565CB5A382DB3908CC3648" This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig2C565CB5A382DB3908CC3648 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Avi Kivity wrote: > Jan Kiszka wrote: >> Having both kvm_eat_signal and kvm_eat_signals makes the code harder t= o >> read. Moreover, given the single caller of kvm_eat_signals, there is n= o >> real reason to keep it in a separate function. >> >> =20 >=20 > Given that with the iothread we spend very little time processing > signals in vcpu threads, maybe it's better to drop the loop completely.= =20 > The common case is zero or one pending signals. The uncommon case of > two or more pending signals will be handled by the KVM_RUN ioctl > returning immediately with -EINTR (i.e. in the outer loop). >=20 You mean static void kvm_main_loop_wait(CPUState *env, int timeout) { pthread_mutex_unlock(&qemu_mutex); kvm_eat_signal(env, timeout); pthread_mutex_lock(&qemu_mutex); cpu_single_env =3D env; vcpu_info[env->cpu_index].signalled =3D 0; } ? Jan --------------enig2C565CB5A382DB3908CC3648 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.4-svn0 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org iD8DBQFIKC0TniDOoMHTA+kRAhOXAJ9gOVAXzuAC1ukOpndstO5ETI3OzwCfR72x q1+PXeagVksdPQ8O8yWVdcA= =ug6R -----END PGP SIGNATURE----- --------------enig2C565CB5A382DB3908CC3648-- --===============1013311266== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------- This SF.net email is sponsored by the 2008 JavaOne(SM) Conference Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone --===============1013311266== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ kvm-devel mailing list kvm-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/kvm-devel --===============1013311266==--