| /linux/drivers/spi/ |
| H A D | spi-fsl-spi.c | 115 int bits_per_word, int msb_first) in fsl_spi_qe_cpu_set_shifts() argument 120 if (bits_per_word <= 8) { in fsl_spi_qe_cpu_set_shifts() 123 } else if (bits_per_word <= 16) { in fsl_spi_qe_cpu_set_shifts() 128 if (bits_per_word <= 8) in fsl_spi_qe_cpu_set_shifts() 134 int bits_per_word, int msb_first) in fsl_spi_grlib_set_shifts() argument 138 if (bits_per_word <= 16) { in fsl_spi_grlib_set_shifts() 141 *tx_shift = 32 - bits_per_word; /* MSB in bit 31 */ in fsl_spi_grlib_set_shifts() 143 *rx_shift = 16 - bits_per_word; /* MSB in bit 15 */ in fsl_spi_grlib_set_shifts() 151 int bits_per_word) in mspi_apply_cpu_mode_quirks() argument 155 if (bits_per_word <= 8) { in mspi_apply_cpu_mode_quirks() [all …]
|
| H A D | spi-bitbang.c | 58 unsigned int bits = t->bits_per_word; in bitbang_txrx_8() 89 unsigned int bits = t->bits_per_word; in bitbang_txrx_16() 120 unsigned int bits = t->bits_per_word; in bitbang_txrx_32() 147 u8 bits_per_word; in spi_bitbang_setup_transfer() local 151 bits_per_word = t->bits_per_word; in spi_bitbang_setup_transfer() 154 bits_per_word = 0; in spi_bitbang_setup_transfer() 159 if (!bits_per_word) in spi_bitbang_setup_transfer() 160 bits_per_word = spi->bits_per_word; in spi_bitbang_setup_transfer() 161 if (bits_per_word <= 8) in spi_bitbang_setup_transfer() 163 else if (bits_per_word <= 16) in spi_bitbang_setup_transfer() [all …]
|
| H A D | spi-mpc512x-psc.c | 57 u8 bits_per_word; member 65 int bits_per_word; member 79 cs->bits_per_word = (t && t->bits_per_word) in mpc512x_psc_spi_transfer_setup() 80 ? t->bits_per_word : spi->bits_per_word; in mpc512x_psc_spi_transfer_setup() 81 cs->bits_per_word = ((cs->bits_per_word + 7) / 8) * 8; in mpc512x_psc_spi_transfer_setup() 122 mps->bits_per_word = cs->bits_per_word; in mpc512x_psc_spi_activate_cs() 361 if (spi->bits_per_word % 8) in mpc512x_psc_spi_setup() 372 cs->bits_per_word = spi->bits_per_word; in mpc512x_psc_spi_setup() 437 mps->bits_per_word = 8; in mpc512x_psc_spi_port_config()
|
| H A D | spi-bcm-qspi.c | 180 u8 bits_per_word; member 606 (cur->bits_per_word != prev->bits_per_word); in bcmspi_parms_did_change() 632 if (xp->bits_per_word != 16 && xp->bits_per_word != 64) in bcm_qspi_hw_set_parms() 633 spcr |= xp->bits_per_word << MSPI_SPCR0_MSB_BITS_SHIFT; in bcm_qspi_hw_set_parms() 661 if (xp->bits_per_word > 16) { in bcm_qspi_hw_set_parms() 700 xp.bits_per_word = trans->bits_per_word; in bcm_qspi_update_parms() 710 if (spi->bits_per_word > 64) in bcm_qspi_setup() 723 if (spi->bits_per_word) in bcm_qspi_setup() 724 xp->bits_per_word = spi->bits_per_word; in bcm_qspi_setup() 726 xp->bits_per_word = 8; in bcm_qspi_setup() [all …]
|
| H A D | spi-imx.c | 111 unsigned int bits_per_word; member 229 static int spi_imx_bytes_per_word(const int bits_per_word) in spi_imx_bytes_per_word() argument 231 if (bits_per_word <= 8) in spi_imx_bytes_per_word() 233 else if (bits_per_word <= 16) in spi_imx_bytes_per_word() 333 bytes_per_word = spi_imx_bytes_per_word(spi_imx->bits_per_word); in spi_imx_buf_rx_swap_u32() 358 if (spi_imx_bytes_per_word(spi_imx->bits_per_word) == 2) { in spi_imx_buf_rx_swap() 388 bytes_per_word = spi_imx_bytes_per_word(spi_imx->bits_per_word); in spi_imx_buf_tx_swap_u32() 410 if (spi_imx_bytes_per_word(spi_imx->bits_per_word) == 2) { in spi_imx_buf_tx_swap() 430 unsigned int bytes_per_word = spi_imx_bytes_per_word(spi_imx->bits_per_word); in mx53_ecspi_rx_target() 473 bytes_per_word = spi_imx_bytes_per_word(spi_imx->bits_per_word); in mx53_ecspi_tx_target() [all …]
|
| H A D | spi-fsl-espi.c | 164 if (first->bits_per_word != t->bits_per_word || in fsl_espi_check_message() 172 if (!(m->spi->mode & SPI_LSB_FIRST) && first->bits_per_word != 8 && in fsl_espi_check_message() 173 first->bits_per_word != 16) { in fsl_espi_check_message() 176 first->bits_per_word); in fsl_espi_check_message() 327 int bits_per_word = t ? t->bits_per_word : spi->bits_per_word; in fsl_espi_setup_transfer() local 335 cs->hw_mode |= CSMODE_LEN(bits_per_word - 1); in fsl_espi_setup_transfer() 404 espi->swab = spi->mode & SPI_LSB_FIRST && trans->bits_per_word > 8; in fsl_espi_trans() 460 trans.bits_per_word = t->bits_per_word; in fsl_espi_do_one_msg()
|
| H A D | spi-xilinx.c | 396 int ret, num_cs = 0, bits_per_word; in xilinx_spi_probe() local 405 bits_per_word = pdata->bits_per_word; in xilinx_spi_probe() 412 &bits_per_word); in xilinx_spi_probe() 414 bits_per_word = 8; in xilinx_spi_probe() 470 host->bits_per_word_mask = SPI_BPW_MASK(bits_per_word); in xilinx_spi_probe() 471 xspi->bytes_per_word = bits_per_word / 8; in xilinx_spi_probe()
|
| H A D | spi-omap2-mcspi.c | 916 u8 word_len = spi->bits_per_word; in omap2_mcspi_setup_transfer() 921 if (t != NULL && t->bits_per_word) in omap2_mcspi_setup_transfer() 922 word_len = t->bits_per_word; in omap2_mcspi_setup_transfer() 1182 (t->bits_per_word != spi->bits_per_word)) { in omap2_mcspi_transfer_one() 1188 t->bits_per_word == spi->bits_per_word) in omap2_mcspi_transfer_one() 1265 u8 bits_per_word; in omap2_mcspi_prepare_message() local 1277 if (!tr->bits_per_word) in omap2_mcspi_prepare_message() 1278 bits_per_word = msg->spi->bits_per_word; in omap2_mcspi_prepare_message() 1280 bits_per_word = tr->bits_per_word; in omap2_mcspi_prepare_message() 1285 if (bits_per_word < 8 && tr->len == 1) { in omap2_mcspi_prepare_message() [all …]
|
| H A D | spi-ingenic.c | 106 bits_per_word = xfer->bits_per_word ?: spi->bits_per_word; in spi_ingenic_prepare_transfer() local 113 regmap_field_write(priv->flen_field, bits_per_word - 2); in spi_ingenic_prepare_transfer() 245 unsigned int bits = xfer->bits_per_word ?: spi->bits_per_word; in spi_ingenic_transfer_one()
|
| H A D | spi-tegra114.c | 263 unsigned bits_per_word = t->bits_per_word; in tegra_spi_calculate_curr_xfer_param() local 267 tspi->bytes_per_word = DIV_ROUND_UP(bits_per_word, 8); in tegra_spi_calculate_curr_xfer_param() 269 if ((bits_per_word == 8 || bits_per_word == 16 || in tegra_spi_calculate_curr_xfer_param() 270 bits_per_word == 32) && t->len > 3) { in tegra_spi_calculate_curr_xfer_param() 272 tspi->words_per_32bit = 32/bits_per_word; in tegra_spi_calculate_curr_xfer_param() 366 u32 rx_mask = ((u32)1 << t->bits_per_word) - 1; in tegra_spi_read_rx_fifo_to_client_rxbuf() 442 u32 rx_mask = ((u32)1 << t->bits_per_word) - 1; in tegra_spi_copy_spi_rxbuf_to_client_rxbuf() 778 u8 bits_per_word = t->bits_per_word; in tegra_spi_setup_transfer_one() local 798 command1 |= SPI_BIT_LENGTH(bits_per_word - 1); in tegra_spi_setup_transfer_one() 859 command1 |= SPI_BIT_LENGTH(bits_per_word - 1); in tegra_spi_setup_transfer_one() [all …]
|
| H A D | spi-sprd.c | 179 u32 size = t->bits_per_word * SPRD_SPI_FIFO_SIZE; in sprd_spi_transfer_max_timeout() 718 u8 bits_per_word = t->bits_per_word; in sprd_spi_setup_transfer() local 733 sprd_spi_set_transfer_bits(ss, bits_per_word); in sprd_spi_setup_transfer() 735 if (bits_per_word > 16) in sprd_spi_setup_transfer() 736 bits_per_word = round_up(bits_per_word, 16); in sprd_spi_setup_transfer() 738 bits_per_word = round_up(bits_per_word, 8); in sprd_spi_setup_transfer() 740 switch (bits_per_word) { in sprd_spi_setup_transfer()
|
| H A D | spi-meson-spicc.c | 592 DIV_ROUND_UP(spicc->xfer->bits_per_word, 8); in meson_spicc_transfer_one() 615 if (xfer->bits_per_word == 64) { in meson_spicc_transfer_one() 744 if (spi->bits_per_word != 8 && in meson_spicc_setup() 745 spi->bits_per_word != 16 && in meson_spicc_setup() 746 spi->bits_per_word != 24 && in meson_spicc_setup() 747 spi->bits_per_word != 32 && in meson_spicc_setup() 748 spi->bits_per_word != 64) in meson_spicc_setup()
|
| H A D | spi-st-ssc4.c | 128 if (spi->bits_per_word > 8) { in spi_st_transfer_one() 136 } else if (spi->bits_per_word == 8 && !(t->len & 0x1)) { in spi_st_transfer_one() 236 var |= (spi->bits_per_word - 1); in spi_st_setup()
|
| /linux/drivers/net/wireless/silabs/wfx/ |
| H A D | bus_spi.c | 227 if (!func->bits_per_word) in wfx_spi_probe() 228 func->bits_per_word = 16; in wfx_spi_probe() 240 spi_get_chipselect(func, 0), func->mode, func->bits_per_word, func->max_speed_hz); in wfx_spi_probe() 241 if (func->bits_per_word != 16 && func->bits_per_word != 8) in wfx_spi_probe() 242 dev_warn(&func->dev, "unusual bits/word value: %d\n", func->bits_per_word); in wfx_spi_probe() 250 if (func->bits_per_word == 8 || IS_ENABLED(CONFIG_CPU_BIG_ENDIAN)) in wfx_spi_probe()
|
| /linux/drivers/net/wireless/st/cw1200/ |
| H A D | cw1200_spi.c | 91 if (self->func->bits_per_word == 8) in cw1200_spi_memcpy_fromio() 114 if (self->func->bits_per_word == 8) in cw1200_spi_memcpy_fromio() 156 if (self->func->bits_per_word == 8) in cw1200_spi_memcpy_toio() 186 if (self->func->bits_per_word == 8) in cw1200_spi_memcpy_toio() 369 func->bits_per_word = plat_data->spi_bits_per_word; in cw1200_spi_probe() 370 if (!func->bits_per_word) in cw1200_spi_probe() 371 func->bits_per_word = 16; in cw1200_spi_probe() 377 spi_get_chipselect(func, 0), func->mode, func->bits_per_word, in cw1200_spi_probe()
|
| /linux/include/trace/events/ |
| H A D | spi.h | 53 __field(unsigned int, bits_per_word) 62 __entry->bits_per_word = spi->bits_per_word; 74 __entry->bits_per_word, __entry->max_speed_hz,
|
| /linux/drivers/input/touchscreen/ |
| H A D | tsc2005.c | 30 .bits_per_word = 8, in tsc2005_cmd() 54 spi->bits_per_word = 8; in tsc2005_probe()
|
| /linux/drivers/net/ethernet/asix/ |
| H A D | ax88796c_spi.c | 56 xfer->bits_per_word = 8; in axspi_read_rxq() 63 xfer->bits_per_word = 8; in axspi_read_rxq()
|
| /linux/include/linux/spi/ |
| H A D | xilinx_spi.h | 21 u8 bits_per_word; member
|
| /linux/lib/ |
| H A D | sbitmap.c | 105 unsigned int bits_per_word; in sbitmap_init_node() local 111 bits_per_word = 1U << shift; in sbitmap_init_node() 112 if (bits_per_word > BITS_PER_LONG) in sbitmap_init_node() 117 sb->map_nr = DIV_ROUND_UP(sb->depth, bits_per_word); in sbitmap_init_node() 147 unsigned int bits_per_word = 1U << sb->shift; in sbitmap_resize() local 154 sb->map_nr = DIV_ROUND_UP(sb->depth, bits_per_word); in sbitmap_resize()
|
| /linux/drivers/video/backlight/ |
| H A D | ili922x.c | 172 xfer.bits_per_word = 8; in ili922x_read_status() 211 xfer_regindex.bits_per_word = 8; in ili922x_read() 266 xfer_regindex.bits_per_word = 8; in ili922x_write() 341 xfer.bits_per_word = 8; in set_write_to_gram_reg()
|
| /linux/drivers/rtc/ |
| H A D | rtc-ds1302.c | 116 if (spi->bits_per_word && (spi->bits_per_word != 8)) { in ds1302_probe()
|
| H A D | rtc-rx6110.c | 346 if ((spi->bits_per_word && spi->bits_per_word != 8) || in rx6110_spi_probe() 350 spi->bits_per_word, spi->max_speed_hz, spi->mode); in rx6110_spi_probe()
|
| /linux/include/uapi/linux/spi/ |
| H A D | spidev.h | 78 __u8 bits_per_word; member
|
| /linux/drivers/iio/adc/ |
| H A D | ad7606_spi.c | 79 .bits_per_word = 14, in ad7606_spi_read_block14to16() 92 .bits_per_word = 18, in ad7606_spi_read_block18to32() 164 xfer->bits_per_word = scan_type->realbits; in ad7606_spi_offload_buffer_postenable()
|