/linux/drivers/net/ethernet/intel/ice/ |
H A D | ice_txrx_lib.c | 244 ice_clean_xdp_tx_buf(struct device *dev, struct ice_tx_buf *tx_buf, in ice_clean_xdp_tx_buf() argument 247 dma_unmap_single(dev, dma_unmap_addr(tx_buf, dma), in ice_clean_xdp_tx_buf() 248 dma_unmap_len(tx_buf, len), DMA_TO_DEVICE); in ice_clean_xdp_tx_buf() 249 dma_unmap_len_set(tx_buf, len, 0); in ice_clean_xdp_tx_buf() 251 switch (tx_buf->type) { in ice_clean_xdp_tx_buf() 253 page_frag_free(tx_buf->raw_buf); in ice_clean_xdp_tx_buf() 256 xdp_return_frame_bulk(tx_buf->xdpf, bq); in ice_clean_xdp_tx_buf() 260 tx_buf->type = ICE_TX_BUF_EMPTY; in ice_clean_xdp_tx_buf() 280 idx = xdp_ring->tx_buf[ntc].rs_idx; in ice_clean_xdp_irq() 298 struct ice_tx_buf *tx_buf = &xdp_ring->tx_buf[ntc]; in ice_clean_xdp_irq() local [all …]
|
H A D | ice_txrx.c | 36 struct ice_tx_buf *tx_buf, *first; in ice_prgm_fdir_fltr() local 68 first = &tx_ring->tx_buf[i]; in ice_prgm_fdir_fltr() 75 tx_buf = &tx_ring->tx_buf[i]; in ice_prgm_fdir_fltr() 80 memset(tx_buf, 0, sizeof(*tx_buf)); in ice_prgm_fdir_fltr() 81 dma_unmap_len_set(tx_buf, len, ICE_FDIR_MAX_RAW_PKT_SIZE); in ice_prgm_fdir_fltr() 82 dma_unmap_addr_set(tx_buf, dma, dma); in ice_prgm_fdir_fltr() 88 tx_buf->type = ICE_TX_BUF_DUMMY; in ice_prgm_fdir_fltr() 89 tx_buf->raw_buf = raw_packet; in ice_prgm_fdir_fltr() 113 ice_unmap_and_free_tx_buf(struct ice_tx_ring *ring, struct ice_tx_buf *tx_buf) in ice_unmap_and_free_tx_buf() argument 115 if (dma_unmap_len(tx_buf, len)) in ice_unmap_and_free_tx_buf() [all …]
|
/linux/drivers/spi/ |
H A D | spi-loopback-test.c | 96 .tx_buf = TX(0), 110 .tx_buf = TX(PAGE_SIZE - 4), 123 .tx_buf = TX(0), 148 .tx_buf = TX(0), 152 .tx_buf = TX(SPI_TEST_MAX_SIZE_HALF), 165 .tx_buf = TX(64), 169 .tx_buf = TX(0), 183 .tx_buf = TX(0), 186 .tx_buf = TX(64), 199 .tx_buf = TX(0), [all …]
|
H A D | spi-cavium.c | 39 const u8 *tx_buf; in octeon_spi_do_transfer() local 68 tx_buf = xfer->tx_buf; in octeon_spi_do_transfer() 74 if (tx_buf) in octeon_spi_do_transfer() 75 d = *tx_buf++; in octeon_spi_do_transfer() 83 mpi_tx.s.txnum = tx_buf ? OCTEON_SPI_MAX_BYTES : 0; in octeon_spi_do_transfer() 98 if (tx_buf) in octeon_spi_do_transfer() 99 d = *tx_buf++; in octeon_spi_do_transfer() 111 mpi_tx.s.txnum = tx_buf ? len : 0; in octeon_spi_do_transfer()
|
H A D | spi-xlp.c | 92 const u8 *tx_buf; /* tx data buffer */ member 213 tx_data |= xspi->tx_buf[i] << (j * 8); in xlp_spi_fill_txfifo() 217 xspi->tx_buf += nbytes; in xlp_spi_fill_txfifo() 259 if (xspi->tx_buf) in xlp_spi_send_cmd() 270 const unsigned char *tx_buf, in xlp_spi_xfer_block() argument 276 xs->tx_buf = tx_buf; in xlp_spi_xfer_block() 278 xs->tx_len = (xs->tx_buf == NULL) ? 0 : xfer_len; in xlp_spi_xfer_block() 323 const unsigned char *tx_buf; in xlp_spi_txrx_bufs() local 325 tx_buf = t->tx_buf; in xlp_spi_txrx_bufs() 330 sz = xlp_spi_xfer_block(xs, tx_buf, rx_buf, in xlp_spi_txrx_bufs() [all …]
|
H A D | spi-realtek-rtl.c | 98 const void *tx_buf; in transfer_one() local 101 tx_buf = xfer->tx_buf; in transfer_one() 104 if (tx_buf) { in transfer_one() 106 send4(rtspi, tx_buf); in transfer_one() 107 tx_buf += 4; in transfer_one() 111 send1(rtspi, tx_buf); in transfer_one() 112 tx_buf++; in transfer_one()
|
H A D | spi-clps711x.c | 30 u8 *tx_buf; member 59 hw->tx_buf = (u8 *)xfer->tx_buf; in spi_clps711x_transfer_one() 63 data = hw->tx_buf ? *hw->tx_buf++ : 0; in spi_clps711x_transfer_one() 82 data = hw->tx_buf ? *hw->tx_buf++ : 0; in spi_clps711x_isr()
|
H A D | spi-armada-3700.c | 108 const u8 *tx_buf; member 429 a3700_spi->tx_buf = xfer->tx_buf; in a3700_spi_transfer_setup() 456 if (a3700_spi->tx_buf) { in a3700_spi_header_set() 477 val = (val << 8) | a3700_spi->tx_buf[0]; in a3700_spi_header_set() 478 a3700_spi->tx_buf++; in a3700_spi_header_set() 498 val = *(u32 *)a3700_spi->tx_buf; in a3700_spi_fifo_write() 501 a3700_spi->tx_buf += 4; in a3700_spi_fifo_write() 606 if (xfer->tx_buf) in a3700_spi_transfer_one_fifo() 633 } else if (xfer->tx_buf) { in a3700_spi_transfer_one_fifo() 649 if (a3700_spi->tx_buf) { in a3700_spi_transfer_one_fifo() [all …]
|
/linux/drivers/net/ethernet/broadcom/bnxt/ |
H A D | bnxt_xdp.c | 31 struct bnxt_sw_tx_bd *tx_buf; in bnxt_xmit_bd() local 45 tx_buf = &txr->tx_buf_ring[RING_TX(bp, prod)]; in bnxt_xmit_bd() 46 tx_buf->nr_frags = num_frags; in bnxt_xmit_bd() 48 tx_buf->page = virt_to_head_page(xdp->data); in bnxt_xmit_bd() 92 return tx_buf; in bnxt_xmit_bd() 99 struct bnxt_sw_tx_bd *tx_buf; in __bnxt_xmit_xdp() local 101 tx_buf = bnxt_xmit_bd(bp, txr, mapping, len, xdp); in __bnxt_xmit_xdp() 102 tx_buf->rx_prod = rx_prod; in __bnxt_xmit_xdp() 103 tx_buf->action = XDP_TX; in __bnxt_xmit_xdp() 112 struct bnxt_sw_tx_bd *tx_buf; in __bnxt_xmit_xdp_redirect() local [all …]
|
/linux/drivers/char/tpm/st33zp24/ |
H A D | spi.c | 57 u8 tx_buf[ST33ZP24_SPI_BUFFER_SIZE]; member 103 .tx_buf = phy->tx_buf, in st33zp24_spi_send() 108 phy->tx_buf[total_length++] = TPM_WRITE_DIRECTION | LOCALITY0; in st33zp24_spi_send() 109 phy->tx_buf[total_length++] = tpm_register; in st33zp24_spi_send() 112 phy->tx_buf[total_length++] = tpm_size >> 8; in st33zp24_spi_send() 113 phy->tx_buf[total_length++] = tpm_size; in st33zp24_spi_send() 116 memcpy(&phy->tx_buf[total_length], tpm_data, tpm_size); in st33zp24_spi_send() 119 memset(&phy->tx_buf[total_length], TPM_DUMMY_BYTE, phy->latency); in st33zp24_spi_send() 146 .tx_buf = phy->tx_buf, in st33zp24_spi_read8_reg() 151 phy->tx_buf[total_length++] = LOCALITY0; in st33zp24_spi_read8_reg() [all …]
|
/linux/drivers/input/rmi4/ |
H A D | rmi_spi.c | 44 u8 *tx_buf; member 75 rmi_spi->tx_buf = &rmi_spi->rx_buf[buf_size]; in rmi_spi_manage_pools() 113 const struct rmi_spi_cmd *cmd, const u8 *tx_buf, in rmi_spi_xfer() argument 163 rmi_spi->tx_buf[0] = (addr >> 8); in rmi_spi_xfer() 164 rmi_spi->tx_buf[1] = addr & 0xFF; in rmi_spi_xfer() 167 rmi_spi->tx_buf[0] = (addr >> 8) | 0x80; in rmi_spi_xfer() 168 rmi_spi->tx_buf[1] = addr & 0xFF; in rmi_spi_xfer() 175 rmi_spi->tx_buf[0] = 0x40; in rmi_spi_xfer() 176 rmi_spi->tx_buf[1] = (addr >> 8) & 0xFF; in rmi_spi_xfer() 177 rmi_spi->tx_buf[2] = addr & 0xFF; in rmi_spi_xfer() [all …]
|
H A D | rmi_i2c.c | 38 u8 *tx_buf; member 90 if (!rmi_i2c->tx_buf || rmi_i2c->tx_buf_size < tx_size) { in rmi_i2c_write_block() 91 if (rmi_i2c->tx_buf) in rmi_i2c_write_block() 92 devm_kfree(&client->dev, rmi_i2c->tx_buf); in rmi_i2c_write_block() 94 rmi_i2c->tx_buf = devm_kzalloc(&client->dev, in rmi_i2c_write_block() 97 if (!rmi_i2c->tx_buf) { in rmi_i2c_write_block() 104 rmi_i2c->tx_buf[0] = addr & 0xff; in rmi_i2c_write_block() 105 memcpy(rmi_i2c->tx_buf + 1, buf, len); in rmi_i2c_write_block() 113 retval = i2c_master_send(client, rmi_i2c->tx_buf, tx_size); in rmi_i2c_write_block()
|
/linux/drivers/gpu/drm/panel/ |
H A D | panel-tpo-td028ttec1.c | 97 u16 tx_buf = JBT_COMMAND | reg; in jbt_ret_write_0() local 103 ret = spi_write(spi, (u8 *)&tx_buf, sizeof(tx_buf)); in jbt_ret_write_0() 118 u16 tx_buf[2]; in jbt_reg_write_1() local 124 tx_buf[0] = JBT_COMMAND | reg; in jbt_reg_write_1() 125 tx_buf[1] = JBT_DATA | data; in jbt_reg_write_1() 127 ret = spi_write(spi, (u8 *)tx_buf, sizeof(tx_buf)); in jbt_reg_write_1() 142 u16 tx_buf[3]; in jbt_reg_write_2() local 148 tx_buf[0] = JBT_COMMAND | reg; in jbt_reg_write_2() 149 tx_buf[1] = JBT_DATA | (data >> 8); in jbt_reg_write_2() 150 tx_buf[2] = JBT_DATA | (data & 0xff); in jbt_reg_write_2() [all …]
|
/linux/drivers/input/touchscreen/ |
H A D | wdt87xx_i2c.c | 222 u8 tx_buf[] = { 0x22, 0x00, 0x10, 0x0E, 0x23, 0x00 }; in wdt87xx_get_desc() local 225 tx_buf[2] |= desc_idx & 0xF; in wdt87xx_get_desc() 227 error = wdt87xx_i2c_xfer(client, tx_buf, sizeof(tx_buf), in wdt87xx_get_desc() 248 u8 tx_buf[] = { 0x22, 0x00, 0x13, 0x0E, str_idx, 0x23, 0x00 }; in wdt87xx_get_string() local 256 error = wdt87xx_i2c_xfer(client, tx_buf, sizeof(tx_buf), in wdt87xx_get_string() 280 u8 tx_buf[8]; in wdt87xx_get_feature() local 290 tx_buf[tx_len++] = 0x22; in wdt87xx_get_feature() 291 tx_buf[tx_len++] = 0x00; in wdt87xx_get_feature() 293 tx_buf[tx_len++] = 0x30; in wdt87xx_get_feature() 294 tx_buf[tx_len++] = 0x02; in wdt87xx_get_feature() [all …]
|
/linux/drivers/net/ethernet/intel/idpf/ |
H A D | idpf_singleq_txrx.c | 197 struct idpf_tx_buf *tx_buf = first; in idpf_tx_singleq_map() local 226 dma_unmap_len_set(tx_buf, len, size); in idpf_tx_singleq_map() 227 dma_unmap_addr_set(tx_buf, dma, dma); in idpf_tx_singleq_map() 228 tx_buf->type = LIBETH_SQE_FRAG; in idpf_tx_singleq_map() 243 tx_buf = &tx_q->tx_buf[0]; in idpf_tx_singleq_map() 247 tx_buf++; in idpf_tx_singleq_map() 251 tx_buf->type = LIBETH_SQE_EMPTY; in idpf_tx_singleq_map() 267 tx_buf = &tx_q->tx_buf[0]; in idpf_tx_singleq_map() 271 tx_buf++; in idpf_tx_singleq_map() 314 txq->tx_buf[ntu].type = LIBETH_SQE_CTX; in idpf_tx_singleq_get_ctx_desc() [all …]
|
H A D | idpf_txrx.c | 89 if (!txq->tx_buf) in idpf_tx_buf_rel_all() 94 libeth_tx_complete(&txq->tx_buf[i], &cp); in idpf_tx_buf_rel_all() 96 kfree(txq->tx_buf); in idpf_tx_buf_rel_all() 97 txq->tx_buf = NULL; in idpf_tx_buf_rel_all() 205 tx_q->tx_buf = kzalloc(buf_size, GFP_KERNEL); in idpf_tx_buf_alloc_all() 206 if (!tx_q->tx_buf) in idpf_tx_buf_alloc_all() 1699 struct idpf_tx_buf *tx_buf) in idpf_stash_flow_sch_buffers() argument 1703 if (unlikely(tx_buf->type <= LIBETH_SQE_CTX)) in idpf_stash_flow_sch_buffers() 1715 stash->buf.skb = tx_buf->skb; in idpf_stash_flow_sch_buffers() 1716 stash->buf.bytes = tx_buf->bytes; in idpf_stash_flow_sch_buffers() [all …]
|
/linux/drivers/iio/adc/ |
H A D | ti-adc108s102.c | 80 __be16 tx_buf[9] __aligned(IIO_DMA_MINALIGN); 124 st->tx_buf[cmds++] = cpu_to_be16(ADC108S102_CMD(bit)); in adc108s102_update_scan_mode() 127 st->tx_buf[cmds++] = 0x00; in adc108s102_update_scan_mode() 130 st->ring_xfer.tx_buf = &st->tx_buf[0]; in adc108s102_update_scan_mode() 132 st->ring_xfer.len = cmds * sizeof(st->tx_buf[0]); in adc108s102_update_scan_mode() 166 st->tx_buf[0] = cpu_to_be16(ADC108S102_CMD(ch)); in adc108s102_scan_direct() 249 st->scan_single_xfer.tx_buf = st->tx_buf; in adc108s102_probe() 251 st->scan_single_xfer.len = 2 * sizeof(st->tx_buf[0]); in adc108s102_probe()
|
H A D | ad7298.c | 53 __be16 tx_buf[2]; member 121 st->tx_buf[0] = cpu_to_be16(command); in ad7298_update_scan_mode() 124 st->ring_xfer[0].tx_buf = &st->tx_buf[0]; in ad7298_update_scan_mode() 127 st->ring_xfer[1].tx_buf = &st->tx_buf[1]; in ad7298_update_scan_mode() 170 st->tx_buf[0] = cpu_to_be16(AD7298_WRITE | st->ext_ref | in ad7298_scan_direct() 329 st->scan_single_xfer[0].tx_buf = &st->tx_buf[0]; in ad7298_probe() 332 st->scan_single_xfer[1].tx_buf = &st->tx_buf[1]; in ad7298_probe()
|
H A D | ti-adc0832.c | 39 u8 tx_buf[2] __aligned(IIO_DMA_MINALIGN); 140 .tx_buf = adc->tx_buf, in adc0832_adc_conversion() 150 adc->tx_buf[0] = 1 << (adc->mux_bits + 1); in adc0832_adc_conversion() 152 adc->tx_buf[0] |= differential ? 0 : (1 << adc->mux_bits); in adc0832_adc_conversion() 154 adc->tx_buf[0] |= (channel % 2) << (adc->mux_bits - 1); in adc0832_adc_conversion() 157 adc->tx_buf[0] |= channel / 2; in adc0832_adc_conversion() 160 adc->tx_buf[0] <<= 1; in adc0832_adc_conversion()
|
H A D | ti-ads8344.c | 31 u8 tx_buf __aligned(IIO_DMA_MINALIGN); 82 adc->tx_buf = ADS8344_START; in ads8344_adc_conversion() 84 adc->tx_buf |= ADS8344_SINGLE_END; in ads8344_adc_conversion() 85 adc->tx_buf |= ADS8344_CHANNEL(channel); in ads8344_adc_conversion() 86 adc->tx_buf |= ADS8344_CLOCK_INTERNAL; in ads8344_adc_conversion() 88 ret = spi_write(spi, &adc->tx_buf, 1); in ads8344_adc_conversion()
|
/linux/drivers/net/ethernet/netronome/nfp/nfd3/ |
H A D | rings.c | 48 struct nfp_nfd3_tx_buf *tx_buf; in nfp_nfd3_tx_ring_reset() local 53 tx_buf = &tx_ring->txbufs[idx]; in nfp_nfd3_tx_ring_reset() 58 if (tx_buf->fidx == -1) { in nfp_nfd3_tx_ring_reset() 60 dma_unmap_single(dp->dev, tx_buf->dma_addr, in nfp_nfd3_tx_ring_reset() 64 frag = &skb_shinfo(skb)->frags[tx_buf->fidx]; in nfp_nfd3_tx_ring_reset() 65 dma_unmap_page(dp->dev, tx_buf->dma_addr, in nfp_nfd3_tx_ring_reset() 70 if (tx_buf->fidx == nr_frags - 1) in nfp_nfd3_tx_ring_reset() 73 tx_buf->dma_addr = 0; in nfp_nfd3_tx_ring_reset() 74 tx_buf->skb = NULL; in nfp_nfd3_tx_ring_reset() 75 tx_buf->fidx = -2; in nfp_nfd3_tx_ring_reset()
|
/linux/include/trace/events/ |
H A D | spi.h | 175 (xfer->tx_buf && xfer->tx_buf != msg->spi->controller->dummy_tx) 193 __dynamic_array(u8, tx_buf, 205 memcpy(__get_dynamic_array(tx_buf), 206 xfer->tx_buf, __get_dynamic_array_len(tx_buf)); 216 __get_dynamic_array_len(tx_buf), __get_dynamic_array(tx_buf),
|
/linux/drivers/mux/ |
H A D | adgs1408.c | 28 u8 tx_buf[2]; in adgs1408_spi_reg_write() local 30 tx_buf[0] = reg_addr; in adgs1408_spi_reg_write() 31 tx_buf[1] = reg_data; in adgs1408_spi_reg_write() 33 return spi_write_then_read(spi, tx_buf, sizeof(tx_buf), NULL, 0); in adgs1408_spi_reg_write()
|
/linux/drivers/video/fbdev/omap2/omapfb/displays/ |
H A D | panel-tpo-td028ttec1.c | 57 u16 tx_buf = JBT_COMMAND | reg; in jbt_ret_write_0() local 59 rc = spi_write(ddata->spi_dev, (u8 *)&tx_buf, in jbt_ret_write_0() 71 u16 tx_buf[2]; in jbt_reg_write_1() local 73 tx_buf[0] = JBT_COMMAND | reg; in jbt_reg_write_1() 74 tx_buf[1] = JBT_DATA | data; in jbt_reg_write_1() 75 rc = spi_write(ddata->spi_dev, (u8 *)tx_buf, in jbt_reg_write_1() 87 u16 tx_buf[3]; in jbt_reg_write_2() local 89 tx_buf[0] = JBT_COMMAND | reg; in jbt_reg_write_2() 90 tx_buf[1] = JBT_DATA | (data >> 8); in jbt_reg_write_2() 91 tx_buf[2] = JBT_DATA | (data & 0xff); in jbt_reg_write_2() [all …]
|
/linux/drivers/platform/mellanox/ |
H A D | mlxbf-tmfifo.c | 145 struct circ_buf tx_buf; member 466 seg = CIRC_SPACE_TO_END(cons->tx_buf.head, cons->tx_buf.tail, in mlxbf_tmfifo_console_output_one() 469 memcpy(cons->tx_buf.buf + cons->tx_buf.head, addr, len); in mlxbf_tmfifo_console_output_one() 471 memcpy(cons->tx_buf.buf + cons->tx_buf.head, addr, seg); in mlxbf_tmfifo_console_output_one() 473 memcpy(cons->tx_buf.buf, addr, len - seg); in mlxbf_tmfifo_console_output_one() 475 cons->tx_buf.head = (cons->tx_buf.head + len) % in mlxbf_tmfifo_console_output_one() 496 avail = CIRC_SPACE(cons->tx_buf.head, cons->tx_buf.tail, in mlxbf_tmfifo_console_output() 551 if (!cons || !cons->tx_buf.buf) in mlxbf_tmfifo_console_tx() 555 size = CIRC_CNT(cons->tx_buf.head, cons->tx_buf.tail, in mlxbf_tmfifo_console_tx() 573 addr = cons->tx_buf.buf + cons->tx_buf.tail; in mlxbf_tmfifo_console_tx() [all …]
|