From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40852) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UzP3j-00036B-7e for qemu-devel@nongnu.org; Wed, 17 Jul 2013 06:34:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UzP3h-0000d9-8p for qemu-devel@nongnu.org; Wed, 17 Jul 2013 06:34:11 -0400 Received: from mx1.redhat.com ([209.132.183.28]:16829) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UzP3h-0000cs-27 for qemu-devel@nongnu.org; Wed, 17 Jul 2013 06:34:09 -0400 Date: Wed, 17 Jul 2013 16:04:06 +0530 From: Amit Shah Message-ID: <20130717103405.GA5143@amit-x200.redhat.com> References: <1373998781-29561-1-git-send-email-lersek@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1373998781-29561-1-git-send-email-lersek@redhat.com> Subject: Re: [Qemu-devel] [PATCH 0/2] changes related to monitor flow control List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Laszlo Ersek Cc: Anthony Liguori , qemu-devel@nongnu.org, Luiz Capitulino On (Tue) 16 Jul 2013 [20:19:39], Laszlo Ersek wrote: > When the IO thread calls monitor_flush() repeatedly & quickly in > succession, outside of callback context, many redundant G_IO_OUT watches > are installed. (One such caller is the "info tlb" / tlb_info() HMP > command which produces a lot of monitor output.) > > While this redundancy is no problem in itself, it can trigger -1/EINVAL > in poll() by growing "gpollfds" beyond limits. This is a persistent > condition, causing qemu to spin in the main loop. > > Patch #2 corrects this. > > My first stab at a fix was patch #1. Although in retrospect probably > unrelated to the main problem, I'm including it because it should > qualify as an improvement / cleanup in its own right. > > See for more > details. Reviewed-by: Amit Shah Amit