linux-hardened/include/drm
Jesse Barnes 40a518d9f1 drm: initial KMS config fixes
When mode setting is first initialized, the driver will call into
drm_helper_initial_config() to set up an initial output and framebuffer
configuration.  This routine is responsible for probing the available
connectors, encoders, and crtcs, looking for modes and putting together
something reasonable (where reasonable is defined as "allows kernel
messages to be visible on as many displays as possible").

However, the code was a bit too aggressive in setting default modes when
none were found on a given connector.  Even if some connectors had modes,
any connectors found lacking modes would have the default 800x600 mode added
to their mode list, which in some cases could cause problems later down the
line.  In my case, the LVDS was perfectly available, but the initial config
code added 800x600 modes to both of the detected but unavailable HDMI
connectors (which are on my non-existent docking station).  This ended up
preventing later code from setting a mode on my LVDS, which is bad.

This patch fixes that behavior by making the initial config code walk
through the connectors first, counting the available modes, before it decides
to add any default modes to a possibly connected output.  It also fixes the
logic in drm_target_preferred() that was causing zeroed out modes to be set
as the preferred mode for a given connector, even if no modes were available.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Dave Airlie <airlied@linux.ie>
2009-01-16 18:40:54 +10:00
..
drm.h drm: drop DRM_IOCTL_MODE_REPLACEFB, add+remove works just as well. 2008-12-29 17:47:25 +10:00
drm_core.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
drm_crtc.h drm: initial KMS config fixes 2009-01-16 18:40:54 +10:00
drm_crtc_helper.h drm: initial KMS config fixes 2009-01-16 18:40:54 +10:00
drm_edid.h DRM: add mode setting support 2008-12-29 17:47:23 +10:00
drm_hashtab.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
drm_memory.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
drm_memory_debug.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
drm_mode.h drm: sanitise drm modesetting API + remove unused hotplug 2008-12-29 17:47:25 +10:00
drm_os_linux.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
drm_pciids.h drm/i915: Filter pci devices based on PCI_CLASS_DISPLAY_VGA 2008-11-11 18:02:12 +10:00
drm_sarea.h drm: move to kref per-master structures. 2008-12-29 17:47:22 +10:00
drm_sman.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
drmP.h drm: Add a debug node for vblank state. 2008-12-29 17:47:27 +10:00
i810_drm.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
i830_drm.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
i915_drm.h drm/i915: Add missing userland definitions for gem init/execbuffer. 2008-12-29 17:47:25 +10:00
Kbuild DRM: add mode setting support 2008-12-29 17:47:23 +10:00
mga_drm.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
r128_drm.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
radeon_drm.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
savage_drm.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
sis_drm.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00
via_drm.h drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00