From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paolo Bonzini Subject: Re: segmentation fault in qemu-kvm-0.14.0 Date: Wed, 09 Mar 2011 12:20:58 +0100 Message-ID: <4D77629A.204@redhat.com> References: <2640D58E-2101-47FA-99B6-28815666651E@dlh.net> <4D772E4C.6020604@web.de> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Peter Lieven , qemu-devel , kvm@vger.kernel.org To: Jan Kiszka Return-path: Received: from mail-qw0-f46.google.com ([209.85.216.46]:39071 "EHLO mail-qw0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751758Ab1CILVJ (ORCPT ); Wed, 9 Mar 2011 06:21:09 -0500 Received: by qwd7 with SMTP id 7so277525qwd.19 for ; Wed, 09 Mar 2011 03:21:08 -0800 (PST) In-Reply-To: <4D772E4C.6020604@web.de> Sender: kvm-owner@vger.kernel.org List-ID: On 03/09/2011 08:37 AM, Jan Kiszka wrote: > It's probably worth validating that the iothread lock is > always held when qemu_set_fd_handler2 is invoked to confirm this race > theory, adding something like > > assert(pthread_mutex_trylock(&qemu_mutex) != 0); > (that's for qemu-kvm only) Alternatively, iohandlers could be a(nother) good place to start introducing fine-grained locks or rwlocks. Paolo