[Mesa3d-dev] Re: library for cursors and mode setting

Jon Smirl jonsmirl at yahoo.com
Wed May 5 01:45:27 EST 2004


--- Egbert Eich <eich at pdx.freedesktop.org> wrote:
> Writing mode setting code is not easy. The stuff that is documented
> in the specs consumes about 10 percent of your time. What is not
> in documented provides the most grief. It would therefore be desirable
> having to do this only once (Today we do it at least twice already-
> in the Xserver and in the Linux kernel).
> I would therefore *strongly recommend* we come up with a solution
> that is usable everywhere: For everything that's interested in mode
> setting both on Linux and non-Linux OSes.

I'm all for this, I just attached Brian's file as a way to get started. I'm also
totally in favor of reusing every piece of code that we can.

Each of the existing solutions has it's flaws:

X drivers:
   X specific, not useful outside of X
   they do a lot more than mode setting and cursor support
   they are implemented completely in user space
   they manipulate the hardware without telling the kernel

Kernel drivers:
   They only know about a single head
   they don't do memory management, multi head support requires it
   DDC code in kernel is big, 100K, and relatively seldom used
   they are hard to debug
   hard to implement user space config files

My preference is for a blend of both worlds:
   Minimum code in kernel driver
   but all code that touches the hardware is in the driver
   Multihead support that is coordinated with DRI memory management
   user space library with single API
   user space library loads personality libs for each card family
   personality libs use private IOCTLs to their corresponding drivers
   mode computations done in user space with IOCTL to set result into HW
   DRM and FB are combined into single driver

Of course this blended system would be completely implemented by copying files
from the other projects.

=====
Jon Smirl
jonsmirl at yahoo.com


	
		
__________________________________
Do you Yahoo!?
Win a $20,000 Career Makeover at Yahoo! HotJobs  
http://hotjobs.sweepstakes.yahoo.com/careermakeover 



More information about the xserver mailing list