1 Adding EXA support to your X.Org video driver
2 ---------------------------------------------
3 EXA (for EXcellent Architecture or Ex-kaa aXeleration Architecture or
4 whatever) aims to extend the life of the venerable XFree86 video drivers by
5 introducing a new set of acceleration hooks that efficiently accelerate the X
6 Render extension, including solid fills, blits within screen memory and to and
7 from system memory, and Porter-Duff compositing and transform operations.
11 Some drivers implement a per-instance useEXA flag to track whether EXA is
14 Setting the flag can be done in the driver's Options parsing routine.
18 EXA drivers in the XFree86 DDX should use the loadable module loader to load
19 the EXA core. Careful versioning allows the EXA API to be extended without
20 breaking the ABI for older versions of drivers. Example code for loading EXA:
22 static const char *exaSymbols[] = {
37 info->exaReq.majorversion = 2;
38 info->exaReq.minorversion = 0;
40 if (!LoadSubModule(pScrn->module, "exa", NULL, NULL, NULL,
41 &info->exaReq, &errmaj, &errmin)) {
42 LoaderErrorMsg(NULL, "exa", errmaj, errmin);
45 xf86LoaderReqSymLists(exaSymbols, NULL);
48 EXA is then initialized using exaDriverAlloc and exaDriverInit. See doxygen
49 documentation for getting started there.
53 The EXA driver interface and public API is documented using doxygen in
54 xserver/xorg/exa/. To build the documentation, run:
57 The resulting documentation will appear an html/index.html under the current
62 Your driver's AccelInit routine must initialize an ExaDriverRec structure if
63 EXA support is enabled, with appropriate error handling (i.e. NoAccel and
64 NoXvideo should be set to true if EXA fails to initialize for whatever
67 The AccelInit routine also needs to make sure that there's enough offscreen
68 memory for certain operations to function, like Xvideo, which should advertise
69 a maximum size no larger than can be dealt with given the amount of offscreen
74 Video support becomes easier with EXA since AllocateFBMemory can use
75 exaOffscreenAlloc directly, freeing a previous area if necessary and
76 allocating a new one. Likewise, FreeFBMemory can call exaOffscreenFree.
80 At screen close time, EXA drivers should call exaDriverFini with their screen
81 pointer, free their EXADriver structure, and do any other necessary teardown.
85 In many drivers, DGA support will need to be changed to be aware of the new
88 Send updates and corrections to Jesse Barnes <jbarnes@virtuousgeek.org> or
89 just check them in if you have permission.