From owner-freebsd-current@FreeBSD.ORG Mon Jun 14 21:30:09 2010 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 D1B1A1065672; Mon, 14 Jun 2010 21:30:09 +0000 (UTC) (envelope-from r.c.ladan@gmail.com) Received: from mail-ww0-f54.google.com (mail-ww0-f54.google.com [74.125.82.54]) by mx1.freebsd.org (Postfix) with ESMTP id CE4158FC0A; Mon, 14 Jun 2010 21:30:08 +0000 (UTC) Received: by wwa36 with SMTP id 36so198215wwa.13 for ; Mon, 14 Jun 2010 14:30:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from :user-agent:mime-version:to:cc:subject:references:in-reply-to :x-enigmail-version:content-type; bh=Ogn2vTgnt4EfB3P/fRnRFKOgCS2P9qpHTJcWvz/y9Y0=; b=Z3DxhbFG9VkC9ycbwQFDl7qE2gIUQlaxdDt8/C+chAIkWUg0aCIg2Opwoe20asbHRp IO2Hxk03VY3FBi+cBPm/Izri3BWBPiDyoIjQt4wOyhcJTdWV2qKkl13DSgbRLQHgNpb0 kvFBCTaU0n8oAv+GtjEilITTXy/Fr8hdJVJ1g= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:x-enigmail-version:content-type; b=YfierNKHnGc95zETo9eRnCxEce2jGpH07bgF7kC2gkTFDFWG8uFCR2nyoP/L3GPX4O R2ivO4uY4eYcZhkusc31YPb3tAwSf915DEh1cqOwVDfNBZMCBzQSHNrhYKg4bgNS8wmp O75OnNwAsQxccrg9h7AvxXoEDZJBgS3104dA8= Received: by 10.227.146.3 with SMTP id f3mr6205496wbv.211.1276551007510; Mon, 14 Jun 2010 14:30:07 -0700 (PDT) Received: from acer.rene-ladan.nl (ip4da3ae31.direct-adsl.nl [77.163.174.49]) by mx.google.com with ESMTPS id n31sm11419526wba.9.2010.06.14.14.30.04 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 14 Jun 2010 14:30:05 -0700 (PDT) Message-ID: <4C169F5B.7040409@gmail.com> Date: Mon, 14 Jun 2010 23:30:03 +0200 From: Rene Ladan User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; nl-NL; rv:1.9.1.9) Gecko/20100612 Thunderbird/3.0.4 MIME-Version: 1.0 To: John Baldwin References: <4C15A09B.8080501@FreeBSD.org> <201006140848.55979.jhb@freebsd.org> In-Reply-To: <201006140848.55979.jhb@freebsd.org> X-Enigmail-Version: 1.0 Content-Type: multipart/mixed; boundary="------------080607050105060508060303" X-Mailman-Approved-At: Tue, 15 Jun 2010 02:35:02 +0000 Cc: alc@freebsd.org, Alan Cox , freebsd-current@freebsd.org, Christian Zander , Doug Barton Subject: Re: nvidia-driver 195.22 use horribly broken on amd64 between r206173 and 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: Mon, 14 Jun 2010 21:30:10 -0000 This is a multi-part message in MIME format. --------------080607050105060508060303 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit On 14-06-2010 14:48, John Baldwin wrote: > On Sunday 13 June 2010 11:23:07 pm Doug Barton wrote: >> On 06/13/10 19:09, Alan Cox wrote: >>> On Sun, Jun 13, 2010 at 8:38 PM, Doug Barton wrote: >>> >>>> On 06/01/10 08:26, John Baldwin wrote: >>>> >>>>> >>>>> I've asked the driver author if the calls to vm_page_wire() and >>>>> vm_page_unwire() can simply be removed but have not heard back yet. >>>>> >>>> >>>> Is there any news on this? I have updated to the latest current so I'm >>>> running the nv driver now, but I'd like to get the nvidia driver running >>>> again. >>>> >>>> >>> Yes, the unnecessary (and now problematic) wiring and unwiring calls will > be >>> removed in a future release of the driver. >> >> Excellent! Any ETA? Or are there patches against an existing version of >> the driver? > > I would just remove the calls to vm_page_wire() and vm_page_unwire() along > with the immediately adjacent calls to vm_page_{un,}lock_queues(). > Just to confirm, like the attached patch? This is with a GeForce GT 240M, current/amd64 r209035, nvidia-driver 195.36.15 I haven't runtime-tested it yet... Rene -- http://www.rene-ladan.nl/ GPG fingerprint = E738 5471 D185 7013 0EE0 4FC8 3C1D 6F83 12E1 84F6 (subkeys.pgp.net) --------------080607050105060508060303 Content-Type: text/plain; name="patch-jhb-current" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="patch-jhb-current" --- src/nvidia_subr.c.orig 2010-03-12 17:48:52.000000000 +0100 +++ src/nvidia_subr.c 2010-06-14 23:25:28.000000000 +0200 @@ -1301,9 +1301,6 @@ for (i = 0; i < count; i++) { pte_array[i] = at->pte_array[i].physical_address; - vm_page_lock_queues(); - vm_page_wire(PHYS_TO_VM_PAGE(pte_array[i])); - vm_page_unlock_queues(); sglist_append_phys(at->sg_list, pte_array[i], PAGE_SIZE); } @@ -1365,9 +1362,6 @@ os_flush_cpu_cache(); for (i = 0; i < count; i++) { - vm_page_lock_queues(); - vm_page_unwire(PHYS_TO_VM_PAGE(at->pte_array[i].physical_address), 0); - vm_page_unlock_queues(); kmem_free(kernel_map, at->pte_array[i].virtual_address, PAGE_SIZE); malloc_type_freed(M_NVIDIA, PAGE_SIZE); --------------080607050105060508060303--