>On Mon, Dec 10, 2001 at 09:19:16AM -0800, Gareth Hughes wrote:
>> On Mon, Dec 10, 2001 at 12:39:57AM -0800, Philip Brown wrote:
>> > So I'm looking through the AGP stuff, still learning...
>> > and it seems that there's a whole lot of redundancy in the current API.
>> > ...
>> > The allocate and bind parts seem to be useless, since the program has
>> > to call mmap() anyway [right?] 
>> 
>> Every time you update the GATT, you have to flush the cache and/or
>> TLBs.  This is expensive.  Therefore, you allocate and bind the pages
>> you'll use, and mmap() just returns the right pages when needed.
>
>But I thought that GATT is simply a scatter/gather table, so
>you only have to update the GATT when you "allocate and bind" pages.
>Then, if you "allocate and bind" the whole range at once, you're done, and
>you dont have to do any cache flushing from that point on.
>So sounds like you are agreeing with me?? :->

Please, beware of another problem with AGP. Several chipsets including
Apple's UniNorth or some ia64 ones can't let the CPU access the AGP
aperture. So the kernel has to map real physical memory pages into
the process space when mmap'ing bits of the aperture. That makes
very difficult to handle unbind when other processes already map
part of the aperture.

We got it to work properly with the in kernel AGP API by hacking both
agpgart and the DRM, and since most DRI drivers actually allocate the
whole AGP memory once and don't touch it.

Ben.



_______________________________________________
Dri-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to