From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jamie Lokier Subject: Re: [Qemu-devel] Re: [PATCH] Fix freezing bug in curses console Date: Sat, 28 Feb 2009 21:21:16 +0000 Message-ID: <20090228212116.GL20640@shareable.org> References: <49A843CA.2050500@us.ibm.com> <49A85541.7040805@codemonkey.ws> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: andrzej zaborowski , Matthew Bloch , kvm@vger.kernel.org To: qemu-devel@nongnu.org Return-path: Received: from mail2.shareable.org ([80.68.89.115]:53245 "EHLO mail2.shareable.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752868AbZB1VVU (ORCPT ); Sat, 28 Feb 2009 16:21:20 -0500 Content-Disposition: inline In-Reply-To: <49A85541.7040805@codemonkey.ws> Sender: kvm-owner@vger.kernel.org List-ID: Anthony Liguori wrote: > >>It's racy with select(). A better fix would be to create a pipe and write > >>to that pipe in the SIGWINCH handler. You should then register an io > >> > > > >Maybe a bottom half would work? The scheduling of a bh shouldn't > >constitute "real work". > > I think it still suffers from the same race condition so today it > wouldn't work. You could fix the bottom half scheduling though so that > you could safely schedule a bottom half from a signal handler (using > roughly the same trick). Fwiw, it's perfectly sensible to have a single pipe which is shared by all signal handlers, just used to say "check for work flags set". -- Jamie