Commit Graph

508 Commits

Author SHA1 Message Date
Eric Anholt 68cef9f4e0 Move output connection detection to a per-output method.
This will be used by RandR, and should let us clean up some of the initial
display configuration, hopefully.

Also, analog hotplug-based detection is now enabled on G965.
2006-10-31 14:32:00 -08:00
Eric Anholt 9fd719fce2 Move SDVOB_PRESERVE_MASK next to SDVOC_PRESERVE_MASK. 2006-10-31 14:29:44 -08:00
Eric Anholt 4f5d4d8870 i830SetLVDSPanelPower is now a static function in i830_lvds.c, so remove it. 2006-10-31 13:37:23 -08:00
Eric Anholt 49bbdf16c0 Fix many inconsistencies in the SDVO code compared to the spec.
Also, fix some struct padding  so that the right bits are sent out.
2006-10-31 11:42:03 -08:00
Eric Anholt e7d546cac0 Remove some dead code from BIOS modesetting. 2006-10-30 11:24:43 -08:00
Eric Anholt 2ca57040b0 Remove GetBIOSVersion().
This info hardly useful now that we don't use the BIOS for mode setting.
2006-10-30 11:19:19 -08:00
Eric Anholt 837b2f6320 Warning fix. 2006-10-30 11:17:55 -08:00
Eric Anholt bca9e6ccbd Remove SetPipeAccess and now-unnecessary VBE reinit. 2006-10-30 11:17:27 -08:00
Eric Anholt 819a47b27c Use the new fields for SDVO pixel multiply on the G965.
This should fix display at resolutions/refresh rates in a different multiplier
class than the console display (generally, high resolution modes).
2006-10-30 11:00:20 -08:00
Eric Anholt 71545db461 Return and use valid status bits for i830_sdvo_get_trained_inputs(). 2006-10-30 09:46:10 -08:00
Eric Anholt c357eca10c Clean up whitespace in i830_randr.c. 2006-10-30 09:44:55 -08:00
Eric Anholt 3ab9f5a4a8 Move vbeInfo out of the driver struct to the one place it's used. 2006-10-25 16:11:06 -07:00
Eric Anholt df14838eb5 Remove dead memsize reporting.
The calculation no longer made sense, as we don't use the BIOS for mode
selection.
2006-10-25 16:11:06 -07:00
Eric Anholt 3a6104ab89 Remove disabled I830DetectMonitorChange().
This used to be called when switching back in to X.  It might make some sense
to detect monitors at this time (it happens to occur at resume time, when
monitors are likely to have changed), but it should probably live in either
userland policy with RandR 1.2 or RandR 1.2 XFree86-DDX generic code.
2006-10-25 16:11:06 -07:00
Eric Anholt 88c12f577f Move LVDS initialization and blacklisting damage to the LVDS support file. 2006-10-25 16:11:05 -07:00
Eric Anholt 2631014e9d Clean up the SDVO code.
The main change is to send SDVO commands using data passed into the send
command function, and receive responses into memory passed into the read
response function, rather than stuff things in/out through dev_priv->sdvo_regs.
This lets us use structures to represent some arguments, which results in a
nice cleanup (and 100% fewer arguments named magicN as a side effect).

Also, the mode set path is changed to not do any preferred input timing
work.  We weren't doing anything legitimate with the results, since we didn't
modify the CRTC timing appropriately, so now we just stuff the CRTC timing into
both and hope for the best.  This should probably be revisited later.
2006-10-25 12:21:57 -07:00
Eric Anholt ddb986e54f Nuke trailing whitespace in SDVO code not already cleaned up. 2006-10-25 12:21:57 -07:00
Eric Anholt cd2f0d948a Clean up SDVO code, moving the private structure internal and cleaning up caps.
All the SDVO code should now be in lower case rather than StudlyCaps.

This also adjusts the I2C setup to create a bus per SDVO output we set up.
The previous setup with shared buses was failing in some circumstances, which
is probably due to the lack of refcounting in xf86i2c.c.
2006-10-25 12:21:57 -07:00
Keith Packard cd9c6e2914 Merge branch 'modesetting-origin' into modesetting 2006-10-24 16:53:46 -07:00
Eric Anholt eec5580cef Merge branch 'overhaul' into modesetting 2006-10-23 14:52:55 -07:00
Eric Anholt a91c0cbab5 Add work-in-progress integrated TV-out support.
This is the TV connector on board for the 915GM and 945GM.

It is currently not hooked up to output initialization as it's entirely
untested.  However, I think this is a reasonable starting point for getting
TV-out actually working.
2006-10-23 14:30:38 -07:00
Eric Anholt 8149681f2e Add a per-output mode-valid method.
This is currently disconnected, but will be used in more overhaul work.
This should be where any output limitations, such as clocks, resolution,
scaling limits, or other options, are validated.  Other limitations, such as
chipset resolution limits, CRTC clock limits, etc. should be elsewhere.
2006-10-16 16:51:04 -07:00
Keith Packard c5cca4c20a Advertise textured video adapter first 2006-10-13 15:31:43 -07:00
Eric Anholt 1838671476 Only disable the output when marked disabled.
Also, remove a couple of dead variables.
2006-10-10 12:41:01 -07:00
Eric Anholt 2591c1fcf1 Fix LVDS restore path, and move pipe assignment for outputs to the right place. 2006-10-09 14:20:49 -07:00
Eric Anholt 09e3d10b0f Add a function for describing the output connection configuration. 2006-10-09 13:09:39 -07:00
Eric Anholt 317cc119c5 Move per-output mode setting code to per-output methods.
This is not a very clean interface, as a number of outputs require tweaks to
the DPLL registers.  When possible, the DPLLs are just adjusted in the
per-output post_set_mode, which happens just after the DPLL is enabled.
However, this seems better than the previous method of having all outputs
programmed in the same function.
2006-10-09 11:49:37 -07:00
Adam Jackson 53c28b3980 Expand the check for AOpen Mini-PC.
Just match on subsystem vendor, don't bother inspecting the subsystem device
ID, since apparently they're all busted.
2006-10-07 11:18:26 -04:00
Keith Packard bf3820f1f5 Compute LVDS resolution from server DPI and native panel size.
I was unable to find the native LVDS panel physical size in the BDB
information. I would prefer to report accurate information through RandR if
possible though.
2006-10-06 21:57:26 -07:00
Keith Packard d649fb0d96 Don't require MonitorLayout when two monitors are plugged in.
With randr12 working, we can just leave the second monitor off for now.
2006-10-05 22:46:07 -07:00
Eric Anholt 9bb7736ab3 Remove checks for output privates in various bits of code.
Now, the output is only set up if it fully initializes, so it will never exist
if the private it requires doesn't.
2006-10-05 16:16:45 -07:00
Eric Anholt ada8f62da2 Give each output type an init method in its file, making other methods static. 2006-10-05 15:55:07 -07:00
Keith Packard 0a5504e59f Fix DPI at startup in RandR 1.2 code.
Use requested monitor resolution to compute the appropriate screen size when
resizing the screen during RandR initialization.
2006-10-05 09:11:29 -07:00
Keith Packard 4ac81d58b7 Remove mode origins, add preferred mode count.
Just tracking changes in the 1.2 protocol spec.
2006-10-04 23:22:52 -07:00
Eric Anholt 103b4edce7 Move the save, restore, and DPMS per-output settings to per-output files. 2006-10-04 18:48:17 -07:00
Keith Packard 16988b2725 Merge branch 'modesetting-guitar' into modesetting 2006-10-04 18:44:43 -07:00
Keith Packard 5a06000248 Add mode origins for randr 2006-10-04 18:43:07 -07:00
Keith Packard cc4148e25d Merge branch 'modesetting-origin' into modesetting 2006-10-03 22:00:41 -07:00
Keith Packard 1bc1cedbcd Enable XV_PORT attribute even when not in Clone mode.
As Clone mode is now something that can change after server startup, always
enable the XV_PORT attribute as we cannot change the list of reported
attributes.
2006-10-03 22:00:14 -07:00
Keith Packard 33629ed304 Always register list of modes for outputs, even when disabled. 2006-10-03 09:39:22 -07:00
Eric Anholt 3e6f81f70f Move cursor base address register setting to a separate function. 2006-10-02 09:53:57 -07:00
Eric Anholt 6ea16bf6b0 Merge branch 'master' into modesetting
This reverts most of the mergedfb code.  This will instead be done in device-
independent RandR code.

Conflicts:

	src/Makefile.am
	src/i810_driver.c
	src/i810_reg.h
	src/i830.h
	src/i830_cursor.c
	src/i830_driver.c
	src/i830_modes.c
	src/i830_video.c
2006-09-27 16:38:01 -07:00
Eric Anholt fdb6de6635 Re-disable broken load-based CRT detection. 2006-09-27 13:59:41 -07:00
Eric Anholt 1407a42c73 Merge branch 'randr-1.2' into modesetting 2006-09-27 13:33:23 -07:00
Eric Anholt 25890ecda9 Merge branch 'acpi-hotkey' into modesetting
Conflicts:

	src/i830.h
	src/i830_driver.c
2006-09-27 13:33:17 -07:00
Eric Anholt 117ff04b50 Attempt to make the ACPI hotkey support a little more modesetting-compatible.
Previously, we watched for the BIOS to have changed the layout, and repaired
the resulting configuration.  Now, we request that the BIOS make no changes,
but leave a note in a register for when the key has been pressed.  When we
notice this, we reprobe monitors and turn on/off the things we find.

This is a temporary solution until we can get the hotkey hooked up as an
input key to external applications to control the change using RandR 1.2.  It
is also untested as neither of my laptops do anything with the hotkey.
However, this code does result in many fewer BIOS calls.
2006-09-27 13:30:09 -07:00
Keith Packard 4bd3b89c73 Oops, duplicated CRT-redetect code. 2006-09-23 16:41:38 +01:00
Keith Packard c34490bbda Construct default monitor description for hotplug non-DDC monitor.
When detecting a monitor that doesn't support DDC, construct a default
monitor with "sensible" values instead of using whatever the builtin LCD
screen uses. Clearly we need a way to set the monitor parameters when we
cannot detect them.
2006-09-23 12:00:43 +01:00
Eric Anholt 965609f6fa Restructure i830_bios.c so we don't leak a copy of the BIOS per generation. 2006-09-22 10:52:04 -07:00
Eric Anholt c52242c227 Remove some dead code related to clock ranges. 2006-09-22 10:52:03 -07:00