Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756266Ab2HFNL6 (ORCPT ); Mon, 6 Aug 2012 09:11:58 -0400 Received: from mail.profihost.ag ([85.158.179.208]:46780 "EHLO mail.profihost.ag" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755955Ab2HFNL4 (ORCPT ); Mon, 6 Aug 2012 09:11:56 -0400 Message-ID: <501FC299.1050408@profihost.ag> Date: Mon, 06 Aug 2012 15:11:53 +0200 From: Stefan Priebe - Profihost AG User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:14.0) Gecko/20120714 Thunderbird/14.0 MIME-Version: 1.0 To: Avi Kivity CC: mtosatti@redhat.com, kvm@vger.kernel.org, qemu-devel , linux-kernel , Kevin Wolf , Stefan Hajnoczi Subject: Re: KVM segfaults with 3.5 while installing ubuntu 12.04 References: <5017C8A0.60506@profihost.ag> <5017F19E.4070308@redhat.com> <501817C9.6090405@profihost.ag> <5018EC7D.9090702@redhat.com> <5018F5BB.9070500@profihost.ag> <5018F7E6.4020909@redhat.com> <5018F9F6.70307@profihost.ag> <5018FC9B.8040808@redhat.com> <501E4615.7060801@profihost.ag> <501E4AFD.3020806@redhat.com> <501E96BB.5060702@profihost.ag> <501EC2E2.8010802@profihost.ag> <501F8226.9090500@redhat.com> <501F846C.50903@profihost.ag> <501FB4A8.6080609@redhat.com> <501FBAA2.6050205@redhat.com> In-Reply-To: <501FBAA2.6050205@redhat.com> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-User-Auth: Auth by hostmaster@profihost.com through 85.158.179.66 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1714 Lines: 52 can confirm - this fixed it! Am 06.08.2012 14:37, schrieb Avi Kivity: > On 08/06/2012 03:12 PM, Avi Kivity wrote: >> On 08/06/2012 11:46 AM, Stefan Priebe - Profihost AG wrote: >> >>> But still i got the segfault and core dump - this is my main problem? I >>> mean qemu-kvm master isn't declared as stable. So i don't care about the >>> slowness here. >>> >>> What can we do about the core dump and crash? >> >> Okay, I reproduced it; it seems aio=native is the culprit. You can try >> aio=threads as a workaround. >> >> Copying some relevant people (context: aio=native on qemu-kvm-1.1.1 >> segfaults pretty early during guest install) >> > > The following ought to fix it: > > > From: Avi Kivity > Date: Mon, 6 Aug 2012 15:35:02 +0300 > Subject: [PATCH] virtio-mlk: fix use-after-free while handling scsi commands > > The scsi passthrough handler falls through after completing a > request into the failure path, resulting in a use after free. > > Reprducible by running a guest with aio=native on a block device. > > Reported-by: Stefan Priebe > Signed-off-by: Avi Kivity > > diff --git a/hw/virtio-blk.c b/hw/virtio-blk.c > index f21757e..552b3b6 100644 > --- a/hw/virtio-blk.c > +++ b/hw/virtio-blk.c > @@ -254,6 +254,7 @@ static void virtio_blk_handle_scsi(VirtIOBlockReq *req) > > virtio_blk_req_complete(req, status); > g_free(req); > + return; > #else > abort(); > #endif > > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/