Lines Matching refs:i2c_data
221 qt1010_i2c_oper_t i2c_data[] = { in qt1010_init_meas1() local
227 for (i = 0; i < ARRAY_SIZE(i2c_data); i++) { in qt1010_init_meas1()
228 err = qt1010_writereg(priv, i2c_data[i].reg, in qt1010_init_meas1()
229 i2c_data[i].val); in qt1010_init_meas1()
256 qt1010_i2c_oper_t i2c_data[] = { in qt1010_init_meas2() local
266 for (i = 0; i < ARRAY_SIZE(i2c_data); i++) { in qt1010_init_meas2()
267 if (i2c_data[i].oper == QT1010_WR) { in qt1010_init_meas2()
268 err = qt1010_writereg(priv, i2c_data[i].reg, in qt1010_init_meas2()
269 i2c_data[i].val); in qt1010_init_meas2()
271 err = qt1010_readreg(priv, i2c_data[i].reg, &val); in qt1010_init_meas2()
287 static const qt1010_i2c_oper_t i2c_data[] = { in qt1010_init() local
327 for (i = 0; i < ARRAY_SIZE(i2c_data); i++) { in qt1010_init()
328 switch (i2c_data[i].oper) { in qt1010_init()
330 err = qt1010_writereg(priv, i2c_data[i].reg, in qt1010_init()
331 i2c_data[i].val); in qt1010_init()
334 if (i2c_data[i].val == 0x20) in qt1010_init()
338 err = qt1010_readreg(priv, i2c_data[i].reg, valptr); in qt1010_init()
341 if (i2c_data[i].val == 0x25) in qt1010_init()
343 else if (i2c_data[i].val == 0x1f) in qt1010_init()
348 if (i >= ARRAY_SIZE(i2c_data) - 1) in qt1010_init()
351 err = qt1010_init_meas1(priv, i2c_data[i + 1].reg, in qt1010_init()
352 i2c_data[i].reg, in qt1010_init()
353 i2c_data[i].val, valptr); in qt1010_init()