On 2002.05.03 15:41 graeme fisher wrote:
> Hi,
> 
> Could some one please explain to me how the batch buffers in the drm
> modules work.
> Specifically, where do the commands for the batch buffer get setup and
> where is it filled What information is typically contained in the batch
> buffers?  How do commands get from the 3D driver via the batch buffer to
> the graphics hardware.  For instance, if I want to display a pixel on
> the screen, what are the steps that the 3D driver goes through to
> actually put the pixel on the screen and what information does the 3D
> driver need to communicate to the drm module.
> appreciated
> 
> Cheers
> Graeme

Graeme,

This is somewhat card specific. The DRM source code has a series of 
templates which can or not be used by a driver to accomplish this. 
The key issue is security (see 
http://dri.sourceforge.net/doc/faq/getting-started.html#NEW-DRIVER). One 
must ensure that no malicious command can get to the card. The only 
trusted subsystems are the DRM and the DDX. If it's impossible to a client 
to issue commands that threat the security then the "batch buffers" you 
mention can be issued directly from the client. If not they must either be 
issued or "validated" by the DRM.

The best sources of information about this are the *_{ioctl,tris}.c files 
in the Mesa driver, and the *_{dma,state}.c files in the DRM. Take a look 
on those of a couple of drivers, especially one with a similar design to 
the card you're interested in supporting.

The FAQ also has a another question regarding this, 
http://dri.sourceforge.net/doc/faq/hardware.html#AEN1466, which gives some 
more details about the buffer management made in the DRM.

Regards,

Jos� Fonseca

_______________________________________________________________

Have big pipes? SourceForge.net is looking for download mirrors. We supply
the hardware. You get the recognition. Email Us: [EMAIL PROTECTED]
_______________________________________________
Dri-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to