Trident driver

Eric Anholt eta@lclark.edu
Sat, 10 Jan 2004 10:37:59 -0800


On Sat, 2004-01-10 at 10:10, Joel Dice wrote:
> Hello all.  The following questions are mainly for Keith Packard, since he
> is the original author, but if anyone else has any tips, I'd appreciate
> them.
> 
> I've spent a bit of time lately trying to get the Trident driver up to
> date, but I'm not sure what to do next.  It now compiles nicely, but when
> I run the server it quickly exits with the following message:
> 
> Fatal server error:
> Trident COP not visible
> 
> I should note that I had to change the InitCard(char*) function in
> tridentstub.c to find my card (PCI device 0x10238500 instead of
> 0x10239525).  I have a CyberBlade/i1 (rev 6a).  It occurred to me that
> such a simple change will not work if the rest of the code is written
> specifically for a different device (the one identified by 0x10239525).
> Is this the case, or should the driver work for any Trident card?
> 
> Either way, I'm not sure how to proceed.  My main question is this: How
> does one write or modify a video driver without documentation?  So far
> I've considered three possibilities:
> 
> Reverse-engineer a Windows driver.
> 	If this is the proper way to do it, I give up now.
> 
> Study the relevant Xfree86 DDX.
> 	This is what I've been doing, but I'm having a hard time mapping
> 	the DDX system to the KDrive system.  Maybe I just need to spend
> 	more time on it.
> 
> Beg the manufacturer to provide documentation, probably under a NDA.
> 	Fine with me, if it's likely to succeed.  But will I still be
> 	allowed to write/modify an open-source driver with that
> 	information?
> 
> So, how is it done?  I wrote some simple device drivers in college, but
> then we had documentation.  Now I'm lost.  Any tips would be most
> appreciated.

The Cyberblade/i1 is somewhat different from the trident that
hw/kdrive/trident was written for.  I started working on a driver for
the CyberBlade/i1 (I've got one, too), but got stuck with a hang waiting
for idle.  The manufacturer provides docs pretty openly I think, but the
XFree86 source will probably be your best source of info at first.

-- 
Eric Anholt                                eta@lclark.edu          
http://people.freebsd.org/~anholt/         anholt@FreeBSD.org