Lines Matching defs:dvo

35 #include "dvo.h"
141 static bool ch7xxx_readb(struct intel_dvo_device *dvo, int addr, uint8_t *ch)
143 struct ch7xxx_priv *ch7xxx= dvo->dev_priv;
144 struct i2c_adapter *adapter = dvo->i2c_bus;
150 .addr = dvo->slave_addr,
156 .addr = dvo->slave_addr,
173 addr, adapter->name, dvo->slave_addr);
179 static bool ch7xxx_writeb(struct intel_dvo_device *dvo, int addr, uint8_t ch)
181 struct ch7xxx_priv *ch7xxx = dvo->dev_priv;
182 struct i2c_adapter *adapter = dvo->i2c_bus;
185 .addr = dvo->slave_addr,
199 addr, adapter->name, dvo->slave_addr);
205 static bool ch7xxx_init(struct intel_dvo_device *dvo,
217 dvo->i2c_bus = adapter;
218 dvo->dev_priv = ch7xxx;
221 if (!ch7xxx_readb(dvo, CH7xxx_REG_VID, &vendor))
228 vendor, adapter->name, dvo->slave_addr);
233 if (!ch7xxx_readb(dvo, CH7xxx_REG_DID, &device))
240 vendor, adapter->name, dvo->slave_addr);
253 static enum drm_connector_status ch7xxx_detect(struct intel_dvo_device *dvo)
257 (void) ch7xxx_readb(dvo, CH7xxx_PM, &orig_pm);
263 (void) ch7xxx_writeb(dvo, CH7xxx_PM, pm);
265 (void) ch7xxx_readb(dvo, CH7xxx_CONNECTION_DETECT, &cdet);
267 (void) ch7xxx_writeb(dvo, CH7xxx_PM, orig_pm);
275 static int ch7xxx_mode_valid(struct intel_dvo_device *dvo,
284 static void ch7xxx_mode_set(struct intel_dvo_device *dvo,
303 (void) ch7xxx_writeb(dvo, CH7xxx_TCTL, 0x00);
304 (void) ch7xxx_writeb(dvo, CH7xxx_TVCO, tvco);
305 (void) ch7xxx_writeb(dvo, CH7xxx_TPCP, tpcp);
306 (void) ch7xxx_writeb(dvo, CH7xxx_TPD, tpd);
307 (void) ch7xxx_writeb(dvo, CH7xxx_TPVT, 0x30);
308 (void) ch7xxx_writeb(dvo, CH7xxx_TLPF, tlpf);
309 (void) ch7xxx_writeb(dvo, CH7xxx_TCT, 0x00);
311 (void) ch7xxx_readb(dvo, CH7xxx_IDF, &idf);
320 (void) ch7xxx_writeb(dvo, CH7xxx_IDF, idf);
324 static void ch7xxx_dpms(struct intel_dvo_device *dvo, bool enable)
327 (void) ch7xxx_writeb(dvo, CH7xxx_PM, CH7xxx_PM_DVIL | CH7xxx_PM_DVIP);
329 (void) ch7xxx_writeb(dvo, CH7xxx_PM, CH7xxx_PM_FPD);
332 static bool ch7xxx_get_hw_state(struct intel_dvo_device *dvo)
336 ch7xxx_readb(dvo, CH7xxx_PM, &val);
344 static void ch7xxx_dump_regs(struct intel_dvo_device *dvo)
352 (void) ch7xxx_readb(dvo, i, &val);
357 static void ch7xxx_destroy(struct intel_dvo_device *dvo)
359 struct ch7xxx_priv *ch7xxx = dvo->dev_priv;
363 dvo->dev_priv = NULL;