Alan,
        I know we have talked about this issue before, but I want to rehash.  The
statement that only what the bios programs is not entirely correct, but this
does hold true for some chipsets where we don't know all the details of agp
mode switching.  In fact the agp specification does not require that the
bios setup and enable the agp aperture on bootup.  So if we stick to your
premise that the bios has to deal with it, we will break on such setups.  On
the broken chipsets we need to override the code in the setmode function,
but we can also get the details from the vendor to support this properly.  I
would recommend that these chipsets override the base set mode function and
not allow any mode switching until we find out the details on how to do it
correctly.  According to the agp spec whatever capability bits are available
are the modes that are valid for use.  The agp kernel module will look at
the capability bits and only allow bits that are set in the capability
register to be used.  It was designed this way to protect the user against
setting agp modes that are not supported by the hardware, thus a user can't
set agp mode to 4x if 4x isn't in the capability register.  According to the
agp spec, thats how mode setting is supposed to work.
        The biggest problem with only using the bios default is that there is alot
of motherboard and graphics card combinations which don't work reliably at
anything but AGP 1x.  The timings for 2x and 4x if they are off by even a
little bit, the graphics card will not be able to reliably DMA from main
memory.  This is why the Xserver defaults to agp 1x in almost all cases,
since its the most reliable setting.  This variable actually can be tuned,
but unless you are agp bandwidth limited (which is not the common case,
especially if your rendering tri/line strips) this variable will not get you
much performance improvement.  However if you are doing alot of blits to and
from agp mapped memory, or other extremely bandwidth intensive applications
the agp mode setting can completely detrimine your performance.
        So if the bios says we want agp 2x but the card in their agp slot only
works at agp 1x with that motherboard then we have broken someones
configuration that was working before.  agp 1x is the only safe setting IF
we are sure we have the mode setting code correct for that chipset.  If we
don't know that ALL bets are off.  For tuning purposes depending on they
usage of agp bandwidth, agp mode 1x is not always the optimal setting.  I
wish we could just say always go to the max agp setting or whatever the
current chipsets mode register is set at.  Unfortunately that will not work
in many cases.  Just going with what is already programmed in the mode
register is going to break peoples configurations that worked fine before.
        If someone will give me a list of chipsets (pci vendor/device pairs) that
we know require the agp mode to be programmed by the bios I will write an
overrided function for their agp drivers so they will not set the graphics
mode to anything but what is required.  This is the simple solution to the
problems people are having, and I can get a patch ready very shortly.
        I hope this clears up the issue, cause I know it has been a source of pain
for Alan and many other kernel developers.  I wish this was a simple issue,
but it is not unfortunately.

Hope this clears up some things,
-Jeff



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Dri-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to