How to add an (S)VGA driver to XFree86 : Getting Started
Previous: Introduction
Next: Directory Tree Structure

## 2. Getting Started

The first step in developing a new driver is to get the documentation for your chipset. I've included a list of vendor contact information that I have collected so far (it's far from complete, so if you have any that isn't on the list, please send it to me). You need to obtain the databook for the chipset. Make sure that the person you speak to is aware that you intend to do register-level programming (so they don't send you the EE-style datasheet). Ask for any example code, or developer's kits, etc. I've learned that at the SVGA level, in general, a databook that lists and describes the registers is the most you can hope to find.

If you are not familiar with VGA register-level programming, you should get (and read!) a copy of Richard Ferraro's bible (see references below). The best way to understand what is happening in the server is to study the workings of the monochrome server's ``generic'' server, and compare it with the documentation in Ferraro's book (be aware that there are a few errors in the book). You can find the generic-VGA-register handling functions in the file ``vgaHW.c''.

Once you understand what's happening in the generic server, you should study one or more of the existing SVGA drivers. Obtain the databook for a supported SVGA chipset, and study the documentation along with the code. When you have a good understanding of what that driver does over and above the generic VGA, you will know what information you need to obtain from the databook for the new chipset. Once you have this information, you are ready to begin work on your new driver.

How to add an (S)VGA driver to XFree86 : Getting Started
Previous: Introduction
Next: Directory Tree Structure