From owner-freebsd-current@FreeBSD.ORG Wed Dec 7 16:27:09 2011 Return-Path: Delivered-To: freebsd-current@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DC51E1065670; Wed, 7 Dec 2011 16:27:09 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 8F2128FC0C; Wed, 7 Dec 2011 16:27:08 +0000 (UTC) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id SAA00337; Wed, 07 Dec 2011 18:27:06 +0200 (EET) (envelope-from avg@FreeBSD.org) Message-ID: <4EDF93DA.3060301@FreeBSD.org> Date: Wed, 07 Dec 2011 18:27:06 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:8.0) Gecko/20111109 Thunderbird/8.0 MIME-Version: 1.0 To: Bernhard Froehlich References: <4ECF7440.4070300@entel.upc.edu> <20111126163343.GA9150@reks> "<4ED6AEFE.4010106@FreeBSD.org>" <201111301807.21351.jkim@FreeBSD.org> <60ea779052f025798cf65e18c24b7b31@bluelife.at> <47eb9f9b139dd8c59b050f1670a5f18d@bluelife.at> "<7c3c9505867f4528af276a571077b9ce@bluelife.at>" <4EDCC1C6.3040109@FreeBSD.org> <4EDCCDA2.5070006@FreeBSD.org> <4EDD0644.5030902@rice.edu> <4EDD3F60.8050601@FreeBSD.org> <4EDD442C.9030406@rice.edu> <4EDD47D3.5010803@FreeBSD.org> <4EDD5CEB.1020502@rice.edu> <4EDDDB7A.4050604@FreeBSD.org> <4EDDF91F.10308@FreeBSD.org> <5ca321038ae3f35c630aa29f5031d1d5@bluelife.at> <4EDE7977.7010800@FreeBSD.org> In-Reply-To: <4EDE7977.7010800@FreeBSD.org> X-Enigmail-Version: undefined Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-emulation@FreeBSD.org, FreeBSD current , vbox@FreeBSD.org Subject: Re: virtualbox r0 memory management update X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Dec 2011 16:27:10 -0000 on 06/12/2011 22:22 Andriy Gapon said the following: > > Could you please change that line as follows? > vm_page_t pPage = pPages +iPage; > Additionally the patch has another bug. Here is a patch on top of the previous patch: --- src/VBox/Runtime/r0drv/freebsd/memobj-r0drv-freebsd.c.orig2 2011-12-07 18:15:48.695189924 +0200 +++ src/VBox/Runtime/r0drv/freebsd/memobj-r0drv-freebsd.c 2011-12-07 18:17:35.359192030 +0200 @@ -251,7 +251,7 @@ static int FreeBSDPhysAllocHelper(vm_obj vm_page_free(pPage); vm_page_unlock_queues(); } - VM_OBJECT_LOCK(pObject); + VM_OBJECT_UNLOCK(pObject); return VERR_NO_MEMORY; } } -- Andriy Gapon