Lines Matching refs:rx

192 	} rx;  in dln2_spi_get_cs_num()  local
193 unsigned rx_len = sizeof(rx); in dln2_spi_get_cs_num()
197 &rx, &rx_len); in dln2_spi_get_cs_num()
200 if (rx_len < sizeof(rx)) in dln2_spi_get_cs_num()
203 *cs_num = le16_to_cpu(rx.cs_count); in dln2_spi_get_cs_num()
218 } rx; in dln2_spi_get_speed() local
219 unsigned rx_len = sizeof(rx); in dln2_spi_get_speed()
223 ret = dln2_transfer(dln2->pdev, cmd, &tx, sizeof(tx), &rx, &rx_len); in dln2_spi_get_speed()
226 if (rx_len < sizeof(rx)) in dln2_spi_get_speed()
229 *freq = le32_to_cpu(rx.speed); in dln2_spi_get_speed()
268 } rx; in dln2_spi_set_speed() local
269 int rx_len = sizeof(rx); in dln2_spi_set_speed()
275 &rx, &rx_len); in dln2_spi_set_speed()
278 if (rx_len < sizeof(rx)) in dln2_spi_set_speed()
327 } *rx = dln2->buf; in dln2_spi_get_supported_frame_sizes() local
328 unsigned rx_len = sizeof(*rx); in dln2_spi_get_supported_frame_sizes()
334 &tx, sizeof(tx), rx, &rx_len); in dln2_spi_get_supported_frame_sizes()
337 if (rx_len < sizeof(*rx)) in dln2_spi_get_supported_frame_sizes()
339 if (rx->count > ARRAY_SIZE(rx->frame_sizes)) in dln2_spi_get_supported_frame_sizes()
343 for (i = 0; i < rx->count; i++) in dln2_spi_get_supported_frame_sizes()
344 *bpw_mask |= BIT(rx->frame_sizes[i] - 1); in dln2_spi_get_supported_frame_sizes()
460 } __packed *rx = dln2->buf; in dln2_spi_read_one() local
461 unsigned rx_len = sizeof(*rx); in dln2_spi_read_one()
463 BUILD_BUG_ON(sizeof(*rx) > DLN2_SPI_BUF_SIZE); in dln2_spi_read_one()
473 rx, &rx_len); in dln2_spi_read_one()
476 if (rx_len < sizeof(rx->size) + data_len) in dln2_spi_read_one()
478 if (le16_to_cpu(rx->size) != data_len) in dln2_spi_read_one()
481 dln2_spi_copy_from_buf(data, rx->buf, data_len, dln2->bpw); in dln2_spi_read_one()
502 } __packed *rx; in dln2_spi_read_write_one() local
506 sizeof(*rx) > DLN2_SPI_BUF_SIZE); in dln2_spi_read_write_one()
517 rx = dln2->buf; in dln2_spi_read_write_one()
526 rx_len = sizeof(*rx); in dln2_spi_read_write_one()
529 rx, &rx_len); in dln2_spi_read_write_one()
532 if (rx_len < sizeof(rx->size) + data_len) in dln2_spi_read_write_one()
534 if (le16_to_cpu(rx->size) != data_len) in dln2_spi_read_write_one()
537 dln2_spi_copy_from_buf(rx_data, rx->buf, data_len, dln2->bpw); in dln2_spi_read_write_one()