From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=56017 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PwtE2-0002sl-5o for qemu-devel@nongnu.org; Tue, 08 Mar 2011 04:29:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PwtE1-0004GU-0M for qemu-devel@nongnu.org; Tue, 08 Mar 2011 04:29:05 -0500 Received: from mx1.redhat.com ([209.132.183.28]:47517) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PwtE0-0004FY-NI for qemu-devel@nongnu.org; Tue, 08 Mar 2011 04:29:04 -0500 Message-ID: <4D75F6D6.1000600@redhat.com> Date: Tue, 08 Mar 2011 10:28:54 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <4D68F20D.2020401@web.de> <20110305163558.GA4607@amt.cnet> <4D736434.1030704@redhat.com> <20110307161305.GB10021@amt.cnet> <4D75F440.6010401@redhat.com> In-Reply-To: <4D75F440.6010401@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: kvm crashes with spice while loading qxl List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Avi Kivity Cc: kvm@vger.kernel.org, Marcelo Tosatti , qemu-devel , xming , Jan Kiszka , Gerd Hoffmann On 03/08/2011 10:17 AM, Avi Kivity wrote: >> Memory map can be protected by a read-write lock initially, so that vcpu >> thread holds it for read. Later can be converted to URCU. > > rwlock is insufficient, need a way to force the vcpu off so a writer can > actually do something. > > So we need some kind of priority rwlock where a reader lets the lock > know how it can force it off in case a writer comes along. If the reader is the VCPU thread, the VCPU thread can always be bounced via qemu_cpu_kick. Paolo