From owner-freebsd-stable@FreeBSD.ORG Wed Feb 17 02:45:13 2010 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1EF42106566B; Wed, 17 Feb 2010 02:45:13 +0000 (UTC) (envelope-from oliver.pntr@gmail.com) Received: from mail-bw0-f223.google.com (mail-bw0-f223.google.com [209.85.218.223]) by mx1.freebsd.org (Postfix) with ESMTP id 20C988FC17; Wed, 17 Feb 2010 02:45:11 +0000 (UTC) Received: by bwz23 with SMTP id 23so1650626bwz.13 for ; Tue, 16 Feb 2010 18:45:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type; bh=jA9KB50VzJ5dSNnz3VxI9q+mggCsP4oMpRr6F0JArpA=; b=E88ZDKM9pL4CMqmZ62/AZAwVB6rt2vV9sAKHCFsqbRjY2ZN32JH0oRumS+2bGU81iV 6mbYIXI5aqmuG0v21kffetHRUHp2Fdz0UtHeCguRD9ZOgK30oWykzcVJlNxwLixroUvM 1zkfHvn1XRCQXZS45YkITt2e31Vtna844fHLE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=ohuiMGW2O3f6x0Id2NClVl8Uvhb61bOi5eZndVjIf/f2Qycpqu+/laF2WBEKNGCvTh u61t5jwwzVCfF9uVY3ekEsDseFj66gQ1BOP7vPofuJ2bWFTD0/WRN5IPSV44jB4OrS3b DVmamu16q48It5o0hJbI15Fq9vdEJBME2sG70= MIME-Version: 1.0 Received: by 10.204.38.71 with SMTP id a7mr4863891bke.159.1266374710988; Tue, 16 Feb 2010 18:45:10 -0800 (PST) In-Reply-To: <1266249418.11131.7.camel@balrog.2hip.net> References: <6101e8c41002091524q25a7e026u585e575eb4f1589c@mail.gmail.com> <20100211074933.GJ9748@acme.spoerlein.net> <1266080709.89452.21.camel@balrog.2hip.net> <201002131137.34812.npapke@acm.org> <1266096425.89452.30.camel@balrog.2hip.net> <20100215142305.3f0d7e65@miknet.dk> <1266249418.11131.7.camel@balrog.2hip.net> Date: Wed, 17 Feb 2010 02:45:09 +0000 Message-ID: <6101e8c41002161845q5d78eb99x61f8ba3ca4eb90c9@mail.gmail.com> From: Oliver Pinter To: Robert Noland Content-Type: multipart/mixed; boundary=0003255592bacd100b047fc2d630 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: Martin Kristensen , freebsd-stable@freebsd.org Subject: Re: freebsd7 (and 8), radeon, xorg-server -> deadlock or so X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Feb 2010 02:45:13 -0000 --0003255592bacd100b047fc2d630 Content-Type: text/plain; charset=ISO-8859-1 Xorg.log after: #killall xdm #kldunload radeon #dmesg: info: [drm] Resetting GPU vgapci0: child drm0 requested pci_disable_busmaster info: [drm] MSI released drm0: detached Warning: memory type drm_bufs leaked memory on destroy (2 allocations, 64 bytes leaked). drm0: on vgapci0 #kldload radeon #dmesg: drm0: on vgapci0 info: [drm] MSI enabled 1 message(s) vgapci0: child drm0 requested pci_enable_busmaster info: [drm] Initialized radeon 1.31.0 20080613 #xdm after this procedure the X never come up, but the system not crashed, and the log attached. On 2/15/10, Robert Noland wrote: > On Mon, 2010-02-15 at 14:23 +0100, Martin Kristensen wrote: >> On Sat, 13 Feb 2010 15:27:04 -0600 >> Robert Noland wrote: >> >> > On Sat, 2010-02-13 at 11:37 -0800, Norbert Papke wrote: >> > > On February 13, 2010, Robert Noland wrote: >> > > > Ok, I've put up a patch at: >> > > > >> > > > http://people.freebsd.org/~rnoland/drm-radeon-test.patch >> > > > >> > >> > http://people.freebsd.org/~rnoland/drm-radeon-8-test.patch >> > >> > This one should work on 8... >> > >> > robert. >> > >> > > > This is sort of a mega patch and includes: >> > > > >> > > > Re-worked drm mapping code, that ensures that we don't end up >> > > > incorrectly mapping certain maps with overlapping offsets. This >> > > > generally shows up as the ring buffer not being cleared >> > > > (contents != 0 in xorg.log) which leads to corruption and other >> > > > bad behavior. >> > > > >> > > > Re-written scatter gather allocation code. This interacts >> > > > directly with the VM system, rather than using bus_dma to allow >> > > > us to grab non-contiguous pages for the scatter gather backing of >> > > > the GART. It also makes it easier to handle the caching mode of >> > > > the backing pages. >> > > > >> > > > Disable cache snooping on radeon cards, since we have write >> > > > combining set properly now. >> > > > >> > > > I have at least done a test build on -CURRENT with this patch, >> > > > but I haven't had time to do much else without the rest of the >> > > > code in my tree. I've been running most all of this code for a >> > > > month or two now at least, so it is mostly just a question of >> > > > whether or not I got all of the conflicts sorted out properly >> > > > when I made this patch. >> > > > >> > > > The re-mapping code has the most widespread impact and has been >> > > > tested on radeon r600 amd64, intel g45 i386 and mga amd64. >> > > > >> > > > robert. >> >> The patch applied cleanly. I have applied the patch to a clean 8-STABLE >> environment with WITNESS, INVARIANTS and KDB_UNATTENDED in the kernel. >> I still see the crashes when starting X with DRI on. This is what I see >> in messages: >> >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_mmap] called with offset >> 0000070001c7b000 >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_mmap] called with offset >> 0000070001c7c000 >> Feb 14 19:13:44 alpha kernel: >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_mmap] called with offset >> 0000070001c7d000 >> Feb 14 19:13:44 alpha kernel: >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_mmap] called with offset >> 0000070001c7e000 >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_mmap] called with offset >> 0000070001c7f000 >> Feb 14 19:13:44 alpha kernel: >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_ioctl] pid=30467, >> cmd=0xc0286415, nr=0x15, dev 0xffffff0001a79400, auth=1 >> Feb 14 19:13:44 alpha kernel: >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_addmap] offset = >> 0xfe8e0000, size = 0x00010000, type = 1 >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_addmap] Found kernel map 1 >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_addmap] Added map 1 >> 0xfe8e0000/0x10000 >> Feb 14 19:13:44 alpha kernel: [drm:pid30467:drm_ioctl] pid=30467, >> cmd=0x80106459, nr=0x59, dev 0xffffff0001a79400, auth=1 >> >> >> There has been one odd development. If I startx with DRI off or NoAccel >> set it starts as usual. If I then quit and to cli and restart, I see the >> same crash as if I had DRI on. > > I'm really starting to think that this is a bug in the Xserver > somewhere... If DRI is off, the kernel drm is not involved at all. The > radeon driver does grope around on the pci bus (via libpciaccess) which > could potentially cause issues, but... miwi and a few other folks have > picked up the ball to get us up to xorg 7.5, since I just don't have > time to do it all now. That might be a good thing to try, I expect that > they will have a patch ready soon, like within a few days. > > robert. > >> Martin > -- > Robert Noland > FreeBSD > > _______________________________________________ > freebsd-stable@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-stable > To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org" > --0003255592bacd100b047fc2d630--