• Home
  • Raw
  • Download

Lines Matching refs:tx_len

283 	size_t tx_len = 0;  in wdt87xx_get_feature()  local
291 tx_buf[tx_len++] = 0x22; in wdt87xx_get_feature()
292 tx_buf[tx_len++] = 0x00; in wdt87xx_get_feature()
294 tx_buf[tx_len++] = 0x30; in wdt87xx_get_feature()
295 tx_buf[tx_len++] = 0x02; in wdt87xx_get_feature()
296 tx_buf[tx_len++] = buf[CMD_REPORT_ID_OFFSET]; in wdt87xx_get_feature()
298 tx_buf[tx_len++] = 0x30 | buf[CMD_REPORT_ID_OFFSET]; in wdt87xx_get_feature()
299 tx_buf[tx_len++] = 0x02; in wdt87xx_get_feature()
301 tx_buf[tx_len++] = 0x23; in wdt87xx_get_feature()
302 tx_buf[tx_len++] = 0x00; in wdt87xx_get_feature()
304 error = wdt87xx_i2c_xfer(client, tx_buf, tx_len, rx_buf, rx_len); in wdt87xx_get_feature()
322 int tx_len = 0; in wdt87xx_set_feature() local
326 tx_buf[tx_len++] = 0x22; in wdt87xx_set_feature()
327 tx_buf[tx_len++] = 0x00; in wdt87xx_set_feature()
329 tx_buf[tx_len++] = 0x30; in wdt87xx_set_feature()
330 tx_buf[tx_len++] = 0x03; in wdt87xx_set_feature()
331 tx_buf[tx_len++] = buf[CMD_REPORT_ID_OFFSET]; in wdt87xx_set_feature()
333 tx_buf[tx_len++] = 0x30 | buf[CMD_REPORT_ID_OFFSET]; in wdt87xx_set_feature()
334 tx_buf[tx_len++] = 0x03; in wdt87xx_set_feature()
336 tx_buf[tx_len++] = 0x23; in wdt87xx_set_feature()
337 tx_buf[tx_len++] = 0x00; in wdt87xx_set_feature()
338 tx_buf[tx_len++] = (buf_size & 0xFF); in wdt87xx_set_feature()
339 tx_buf[tx_len++] = ((buf_size & 0xFF00) >> 8); in wdt87xx_set_feature()
341 if (tx_len + buf_size > sizeof(tx_buf)) in wdt87xx_set_feature()
344 memcpy(&tx_buf[tx_len], buf, buf_size); in wdt87xx_set_feature()
345 tx_len += buf_size; in wdt87xx_set_feature()
347 error = i2c_master_send(client, tx_buf, tx_len); in wdt87xx_set_feature()