Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 218094
b: refs/heads/master
c: 428d2e8
h: refs/heads/master
v: v3
  • Loading branch information
Chris Wilson committed Sep 24, 2010
1 parent 9c42d15 commit bb78131
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 29e1316ab129f2d3a9ea874e7c9a4cb936f43542
refs/heads/master: 428d2e828c0a68206e5158a42451487601dc9194
21 changes: 21 additions & 0 deletions trunk/drivers/gpu/drm/i915/intel_lvds.c
Original file line number Diff line number Diff line change
Expand Up @@ -810,6 +810,22 @@ static bool lvds_is_present_in_vbt(struct drm_device *dev)
return false;
}

static bool intel_lvds_ddc_probe(struct drm_device *dev)
{
struct drm_i915_private *dev_priv = dev->dev_private;
u8 buf = 0;
struct i2c_msg msgs[] = {
{
.addr = 0xA0,
.flags = 0,
.len = 1,
.buf = &buf,
},
};
struct i2c_adapter *i2c = &dev_priv->gmbus[GMBUS_PORT_PANEL].adapter;
return i2c_transfer(i2c, msgs, 1) == 1;
}

/**
* intel_lvds_init - setup LVDS connectors on this device
* @dev: drm device
Expand Down Expand Up @@ -849,6 +865,11 @@ void intel_lvds_init(struct drm_device *dev)
gpio = PCH_GPIOC;
}

if (!intel_lvds_ddc_probe(dev)) {
DRM_DEBUG_KMS("LVDS did not respond to DDC probe\n");
return;
}

intel_lvds = kzalloc(sizeof(struct intel_lvds), GFP_KERNEL);
if (!intel_lvds) {
return;
Expand Down

0 comments on commit bb78131

Please sign in to comment.