-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Eric Anholt wrote: > On Mon, 2005-06-27 at 12:13 -0700, Ian Romanick wrote: > >>Does this maintain the 256-byte alignment requirement for the WARP >>microcode? > > Addmap aligns to the same size as the allocation itself. I just assumed > that the warp_size was bigger than 256 bytes.
It is. IIRC, it's ~12KiB on G200 and ~20KiB on G400. This does raise another issue, though. This may make some allocations, such as the primary DMA buffer, fail when they don't need to. The primary DMA buffer "wants to be" 1MB, but it only needs 4-byte alignment. Ditto for the secondary buffers. They want to be 64KiB with 4-byte alignment. Hmmm... [snip] >>The following block of code is called during driver takedown (i.e., at >>rmmod time on Linux) *and* when the DDX calls mga_dma_init with func = >>MGA_CLEANUP_MGA. Basically, the DDX bootstraps and inits DMA at >>start-up, and tears it down when it exists. I think that starting X, >>exiting X, and re-starting X will fail with this code removed. >> >>I think we need some better documentation in drmP.h for *when* all the >>pre / post functions are called. I wasted a lot of time on my MGA >>changes doing guess-and-check to get it right. It also seems like some >>of that could be refacted into shared-core. There *is* a common sub-set >>between linux-core and bsd-core. > > takedown is called during last close of the device (when X > exits/restarts), not rmmod. I was actually testing "cleanup" is called > on rmmod. I would love to have better naming of these functions. I was > actually testing with a pair of "startx; glxgears; exit;" for the tests > I listed. I just verified that MGA worked as intended (this DRM, > current ddx and dri driver, no olddmainit). I tested this on an AGP G400 on Linux and it seems to work as expected. > Here's how I justified to myself that leaving map uninit to takedown was > fine: You can only have one shm area with the hardware lock inited at a > time, determined by whether hw_lock is set. The unsetting of hw_lock > only occurs at takedown. Therefore, if takedown isn't occuring between > X Server instances, you won't get DRI access anyway. That makes sense. One last comment. The patch-levels and the dates of the modified modules (drm, mga, radeon, and savage) need to be updated. Other than that, it looks fine to me. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFCwXNDX1gOwKyEAw8RAkpDAJ0b17P3Gs3VrsqLLc9P7X3zVAbyLwCeJR1W QFxlYZzpH3NUUtBaKhLjOuk= =QWfn -----END PGP SIGNATURE----- ------------------------------------------------------- SF.Net email is sponsored by: Discover Easy Linux Migration Strategies from IBM. Find simple to follow Roadmaps, straightforward articles, informative Webcasts and more! Get everything you need to get up to speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click -- _______________________________________________ Dri-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/dri-devel
