Lines Matching defs:dvo

36 #include "dvo.h"
101 static bool tfp410_readb(struct intel_dvo_device *dvo, int addr, uint8_t *ch)
103 struct tfp410_priv *tfp = dvo->dev_priv;
104 struct i2c_adapter *adapter = dvo->i2c_bus;
110 .addr = dvo->slave_addr,
116 .addr = dvo->slave_addr,
133 addr, adapter->name, dvo->slave_addr);
138 static bool tfp410_writeb(struct intel_dvo_device *dvo, int addr, uint8_t ch)
140 struct tfp410_priv *tfp = dvo->dev_priv;
141 struct i2c_adapter *adapter = dvo->i2c_bus;
144 .addr = dvo->slave_addr,
158 addr, adapter->name, dvo->slave_addr);
164 static int tfp410_getid(struct intel_dvo_device *dvo, int addr)
168 if (tfp410_readb(dvo, addr+0, &ch1) &&
169 tfp410_readb(dvo, addr+1, &ch2))
176 static bool tfp410_init(struct intel_dvo_device *dvo,
187 dvo->i2c_bus = adapter;
188 dvo->dev_priv = tfp;
191 if ((id = tfp410_getid(dvo, TFP410_VID_LO)) != TFP410_VID) {
194 id, adapter->name, dvo->slave_addr);
198 if ((id = tfp410_getid(dvo, TFP410_DID_LO)) != TFP410_DID) {
201 id, adapter->name, dvo->slave_addr);
211 static enum drm_connector_status tfp410_detect(struct intel_dvo_device *dvo)
216 if (tfp410_readb(dvo, TFP410_CTL_2, &ctl2)) {
227 static int tfp410_mode_valid(struct intel_dvo_device *dvo,
235 static void tfp410_mode_set(struct intel_dvo_device *dvo,
250 static void tfp410_dpms(struct intel_dvo_device *dvo, bool enable)
254 if (!tfp410_readb(dvo, TFP410_CTL_1, &ctl1))
262 (void) tfp410_writeb(dvo, TFP410_CTL_1, ctl1);
265 static bool tfp410_get_hw_state(struct intel_dvo_device *dvo)
269 if (!tfp410_readb(dvo, TFP410_CTL_1, &ctl1))
277 static void tfp410_dump_regs(struct intel_dvo_device *dvo)
281 (void) tfp410_readb(dvo, TFP410_REV, &val);
283 (void) tfp410_readb(dvo, TFP410_CTL_1, &val);
285 (void) tfp410_readb(dvo, TFP410_CTL_2, &val);
287 (void) tfp410_readb(dvo, TFP410_CTL_3, &val);
289 (void) tfp410_readb(dvo, TFP410_USERCFG, &val);
291 (void) tfp410_readb(dvo, TFP410_DE_DLY, &val);
293 (void) tfp410_readb(dvo, TFP410_DE_CTL, &val);
295 (void) tfp410_readb(dvo, TFP410_DE_TOP, &val);
297 (void) tfp410_readb(dvo, TFP410_DE_CNT_LO, &val);
298 (void) tfp410_readb(dvo, TFP410_DE_CNT_HI, &val2);
300 (void) tfp410_readb(dvo, TFP410_DE_LIN_LO, &val);
301 (void) tfp410_readb(dvo, TFP410_DE_LIN_HI, &val2);
303 (void) tfp410_readb(dvo, TFP410_H_RES_LO, &val);
304 (void) tfp410_readb(dvo, TFP410_H_RES_HI, &val2);
306 (void) tfp410_readb(dvo, TFP410_V_RES_LO, &val);
307 (void) tfp410_readb(dvo, TFP410_V_RES_HI, &val2);
311 static void tfp410_destroy(struct intel_dvo_device *dvo)
313 struct tfp410_priv *tfp = dvo->dev_priv;
317 dvo->dev_priv = NULL;