Understanding kdrive ati driver UploadToScreen function.

Dave Airlie airlied at gmail.com
Thu May 3 02:16:39 PDT 2007


On 5/3/07, Abhinav Duggal <abhinavduggal at gmail.com> wrote:
> Hi all,
> I was going through ati kdrive driver.The UploadToScreen gets a src pointer
> to the memory region to copy to the destination.But this address is a
> virtual space address.This address is used as follows to perform the upload
> operation.
> ATIUploadToScreen(PixmapPtr pDst, char *src, int src_pitch)
> {
> .....
> .....
> //code from  hw/kdrive/ati_draw.c
>  BEGIN_DMA(1);
>    OUT_RING(((CARD32 *)src)[i]);
>    END_DMA();
>  ....
> ....
> }

You missed the important part in your paste, the for loop...

It just writes out each 32-bit word into the DMA buffer, from src, it
doesn't actually write src anywhere..

Dave.



More information about the xorg mailing list