With this, we no longer allocate XV through the XF86 linear allocator in the
EXA case. We also no longer allocate extra space for the XF86 2D allocator
that we don't use in EXA mode, or space for the EXA allocator in XAA mode.
The EXA offscreen allocator now gets enough space for several screenfuls of
pixmaps plus one 1920x1088 movie.
A large duplicated section of code for allocating each framebuffer in the old
dual-screen mode was also factored out.
Monitors without detailed modes, or those which do not bother to set a
physical size in their detailed modes may still have physical size in the
global data.
For EDID with known errors, add a quirk mechanism to automatically
compensate. The first quirk is for a Belinea 1440x900 monitor which
incorrectly specifies sync polarities in the detailed mode.
Extract correct color conversion values for all video formats from
documentation. Use those, with appropriate conversions, for the color
conversion register values.
The constants provided in the documentation for the subcarrier DDA values
assumed the clock was programmed to precisely 108MHz, but the PLL can't hit
that value exactly (or our PLL computation can't, in any case). The
result was an incorrect subcarrier frequency which resulted in synthetic
subcarrier phase shift and a lovely rainbow effect on the screen.
Unfortunately, the documentation didn't exactly describe the function
performed by the subcarrier clock hardware, so a bit of detective work was
needed. New constants were computed using the code in tv.5c and those, along
with lots of other values from the documentation were inserted into the
necessary tables.
The result appears to generate stable NTSC video on the svideo connector.
TV output private type field was set to I830_OUTPUT_SDVO instead of
I830_OUTPUT_TVOUT. When DGA mode setting occurred, the sdvo output debug
code would be invoked and attempt to dereference sdvo-specific bits of the
private structure leading to a segfault.
Physical screen size from the config file or DDC will already
be set correctly in the screen structure, unless it was computed from the
virtual size using the -dpi command line option. Recompute physical size as
we reset the screen size if the -dpi option was used.
The old Init() function is removed and the previous Detect() function is now
init(). This leaves us room in the namespace for a detect() like other
outputs have ("is the monitor connected?"). Also, Power() became dpms(),
taking a DPMSMode*. In general, the mode setting path now matches the intel
internal path, except for the lack of mode_fixup().
Add delays after output and CRTC disable. Restore panel fit register before
PLLs are restarted. Move all VGA restore code last. Shuffle various register
writes around and add delays to match PipeSetMode code.
For some reason, the code was preferring the last possible output when
mapping outputs to crtcs. Use the earlier CRTC instead to make the i830
driver consistent with BIOS usage.
Oops--looks like a typo to me; the code was callint set_target_output
instead of set_active_outputs.
BIOS loops waiting for the SDVO input to sync before enabling outputs, this
makes sense to me.
Instead of delaying pll/pipe/plane enables to the dpms function, turn them
on right away in the crtc_set_mode function. To avoid rewriting these
registers in the subsequent dpms function, check each register written there
to see if the enable bit is already on and don't rewrite.
Instead of growing virtual to fit our desired sizes, if it is set in the
config file, use the value as the virtual size and make the default
configuration fit within that size (if possible).
Pull xf86CrtcConfig out of the driver private structure and allocate a
ScrnInfo private index for it. Also, make the arrays of outputs and crtcs
dynamic instead of fixed.
We can't figure out which chips are supposed to have TV out, so instead we
prod the TV_DAC register to see if it will hold the value written to it, if
not, we assume the chip doesn't have TV out.