Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 30 Aug 2007 15:49:56 -0400
From:      Coleman Kane <cokane@FreeBSD.org>
To:        Robert Noland <rnoland@2hip.net>
Cc:        freebsd-x11@freebsd.org
Subject:   Re: AIGLX, ATI/AMD Radeons and FreeBSD -current
Message-ID:  <46D71F64.8050107@FreeBSD.org>
In-Reply-To: <1188493811.1234.15.camel@rnoland-ibm.acs.internap.com>
References:  <46D6D0F8.3080700@FreeBSD.org>	 <20070830163302.GD2332@deviant.kiev.zoral.com.ua> <1188493811.1234.15.camel@rnoland-ibm.acs.internap.com>

next in thread | previous in thread | raw e-mail | index | archive | help

[-- Attachment #1 --]
Robert Noland wrote:
> On Thu, 2007-08-30 at 19:33 +0300, Kostik Belousov wrote:
>   
>> On Thu, Aug 30, 2007 at 10:15:20AM -0400, Coleman Kane wrote:
>>     
>>> Hi,
>>>
>>> I am curious what the state of AIGLX is using the ATI R300+ cards (I've 
>>> an rv350) under FreeBSD. I have been trying to track down what work is 
>>> being done on the problem.
>>>
>>> I see a number of references detailing that it *is* broken, but I am 
>>> having difficulty tracking down any progress or unofficial patches to 
>>> deal with fixing it... is there anybody who's actively working on fixing 
>>> this problem?
>>>
>>> I found PR 112984: http://www.freebsd.org/cgi/query-pr.cgi?pr=112984 
>>> which documents some spotty working/not working cases... all referencing 
>>> 6.2-STABLE. Is this the only progress made so far? Is there any "working 
>>> solution" under -current (or does the -stable fix apply to -current 
>>> too)? Does the xorg-server-snap get better results?
>>>
>>> I'm hoping that someone else has already trudged through here and can 
>>> help shortcut what may be a drawn-out compile/test/debug/recompile cycle...
>>>       
>> Try https://bugs.freedesktop.org/show_bug.cgi?id=11870
>>     
>
> Yes, this is the place to look.  I'm trying to push getting this fixed
> as best I can.  AIGLX is required for compiz to run on radeon hardware,
> which is mostly what I have...
>
> robert.
>   
Found a patch that was posted here not too long ago.... attaching it 
here. This seems to work with me except it has the side effect that DRI 
fails to start when X is restarted. If I kldunload then kldload radeon, 
then restart the X server once more, it fixes the problem (and DRI is 
inititalized).

It looks similar to the patches posted in the issue you linked. I will 
try the latest patch from Jung-uk Kim, and see where it gets me. I have 
compiz working well, except I get some white artifacts if I have 
/apps/compiz/plugins/decoration/allscreens/options/shadow_match set to 
"any". I set it to "none" and now graphics look fine. I had to learn the 
ins-and-outs of how compiz works...yay.

I'll update you guys as it proceeds along.

[-- Attachment #2 --]
--- a/sys/dev/drm/drm_drv.c
+++ b/sys/dev/drm/drm_drv.c
@@ -711,6 +711,15 @@ int drm_close(struct cdev *kdev, int flags, int fmt, DRM_STRUCTPROC *p)
 		return EINVAL;
 	}
 
+	atomic_inc( &dev->counts[_DRM_STAT_CLOSES] );
+#ifdef __FreeBSD__
+	device_unbusy(dev->device);
+#endif
+	if (--dev->open_count != 0) {
+		DRM_UNLOCK();
+		return (0);
+	}
+
 	if (dev->driver.preclose != NULL)
 		dev->driver.preclose(dev, filp);
 
@@ -797,13 +806,8 @@ int drm_close(struct cdev *kdev, int flags, int fmt, DRM_STRUCTPROC *p)
 	 * End inline drm_release
 	 */
 
-	atomic_inc( &dev->counts[_DRM_STAT_CLOSES] );
-#ifdef __FreeBSD__
-	device_unbusy(dev->device);
-#endif
-	if (--dev->open_count == 0) {
-		retcode = drm_lastclose(dev);
-	}
+
+	retcode = drm_lastclose(dev);
 
 	DRM_UNLOCK();

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?46D71F64.8050107>