Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 218033
b: refs/heads/master
c: 219adae
h: refs/heads/master
i:
  218031: 8dab8aa
v: v3
  • Loading branch information
Chris Wilson committed Sep 21, 2010
1 parent 4d36517 commit 2765c90
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e9e5f8e8d373e72f5c39dafde1ce110fc7082118
refs/heads/master: 219adae138513bae20b256f1946b9cb3b75ca05c
19 changes: 8 additions & 11 deletions trunk/drivers/gpu/drm/i915/intel_lvds.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
struct intel_lvds {
struct intel_encoder base;

bool edid_good;
struct edid *edid;

int fitting_mode;
u32 pfit_control;
Expand Down Expand Up @@ -475,14 +475,12 @@ static int intel_lvds_get_modes(struct drm_connector *connector)
{
struct intel_lvds *intel_lvds = intel_attached_lvds(connector);
struct drm_device *dev = connector->dev;
struct drm_i915_private *dev_priv = dev->dev_private;
struct drm_display_mode *mode;

if (intel_lvds->edid_good) {
int ret = intel_ddc_get_modes(connector,
&dev_priv->gmbus[GMBUS_PORT_PANEL].adapter);
if (ret)
return ret;
if (intel_lvds->edid) {
drm_mode_connector_update_edid_property(connector,
intel_lvds->edid);
return drm_add_edid_modes(connector, intel_lvds->edid);
}

mode = drm_mode_duplicate(dev, intel_lvds->fixed_mode);
Expand Down Expand Up @@ -906,11 +904,10 @@ void intel_lvds_init(struct drm_device *dev)
* Attempt to get the fixed panel mode from DDC. Assume that the
* preferred mode is the right one.
*/
intel_lvds->edid_good = true;
if (!intel_ddc_get_modes(connector, &dev_priv->gmbus[GMBUS_PORT_PANEL].adapter))
intel_lvds->edid_good = false;
intel_lvds->edid = drm_get_edid(connector,
&dev_priv->gmbus[GMBUS_PORT_PANEL].adapter);

if (!intel_lvds->edid_good) {
if (!intel_lvds->edid) {
/* Didn't get an EDID, so
* Set wide sync ranges so we get all modes
* handed to valid_mode for checking
Expand Down

0 comments on commit 2765c90

Please sign in to comment.