/kernel/linux/linux-6.6/drivers/spi/ |
H A D | spi-bitbang-txrx.h | 50 unsigned nsecs, unsigned cpol, unsigned flags, in bitbang_txrx_be_cpha0() 53 /* if (cpol == 0) this is SPI_MODE_0; else this is SPI_MODE_2 */ in bitbang_txrx_be_cpha0() 68 setsck(spi, !cpol); in bitbang_txrx_be_cpha0() 75 setsck(spi, cpol); in bitbang_txrx_be_cpha0() 82 unsigned nsecs, unsigned cpol, unsigned flags, in bitbang_txrx_be_cpha1() 85 /* if (cpol == 0) this is SPI_MODE_1; else this is SPI_MODE_3 */ in bitbang_txrx_be_cpha1() 92 setsck(spi, !cpol); in bitbang_txrx_be_cpha1() 101 setsck(spi, cpol); in bitbang_txrx_be_cpha1() 114 unsigned int nsecs, unsigned int cpol, unsigned int flags, in bitbang_txrx_le_cpha0() 117 /* if (cpol in bitbang_txrx_le_cpha0() 49 bitbang_txrx_be_cpha0(struct spi_device *spi, unsigned nsecs, unsigned cpol, unsigned flags, u32 word, u8 bits) bitbang_txrx_be_cpha0() argument 81 bitbang_txrx_be_cpha1(struct spi_device *spi, unsigned nsecs, unsigned cpol, unsigned flags, u32 word, u8 bits) bitbang_txrx_be_cpha1() argument 113 bitbang_txrx_le_cpha0(struct spi_device *spi, unsigned int nsecs, unsigned int cpol, unsigned int flags, u32 word, u8 bits) bitbang_txrx_le_cpha0() argument 146 bitbang_txrx_le_cpha1(struct spi_device *spi, unsigned int nsecs, unsigned int cpol, unsigned int flags, u32 word, u8 bits) bitbang_txrx_le_cpha1() argument [all...] |
H A D | spi-cavium.c | 38 bool cpha, cpol; in octeon_spi_do_transfer() local 46 cpol = mode & SPI_CPOL; in octeon_spi_do_transfer() 56 mpi_cfg.s.idlelo = cpha != cpol; in octeon_spi_do_transfer()
|
H A D | spi-lp8841-rtc.c | 67 unsigned usecs, unsigned cpol, unsigned flags, in bitbang_txrx_be_cpha0_lsb() 70 /* if (cpol == 0) this is SPI_MODE_0; else this is SPI_MODE_2 */ in bitbang_txrx_be_cpha0_lsb() 87 setsck(data, !cpol); in bitbang_txrx_be_cpha0_lsb() 90 setsck(data, cpol); in bitbang_txrx_be_cpha0_lsb() 66 bitbang_txrx_be_cpha0_lsb(struct spi_lp8841_rtc *data, unsigned usecs, unsigned cpol, unsigned flags, u32 word, u8 bits) bitbang_txrx_be_cpha0_lsb() argument
|
H A D | spi-slave-mt27xx.c | 134 bool cpha, cpol; in mtk_spi_slave_prepare_message() local 138 cpol = spi->mode & SPI_CPOL ? 1 : 0; in mtk_spi_slave_prepare_message() 145 if (cpol) in mtk_spi_slave_prepare_message()
|
H A D | spi-stm32.c | 195 * @cpol: clock polarity register and polarity bit 207 const struct stm32_spi_reg cpol; member 332 .cpol = { STM32F4_SPI_CR1, STM32F4_SPI_CR1_CPOL }, 351 .cpol = { STM32H7_SPI_CFG2, STM32H7_SPI_CFG2_CPOL }, 982 setb |= spi->cfg->regs->cpol.mask; in stm32_spi_prepare_msg() 984 clrb |= spi->cfg->regs->cpol.mask; in stm32_spi_prepare_msg() 1001 dev_dbg(spi->dev, "cpol=%d cpha=%d lsb_first=%d cs_high=%d\n", in stm32_spi_prepare_msg() 1026 (readl_relaxed(spi->base + spi->cfg->regs->cpol.reg) & in stm32_spi_prepare_msg() 1028 spi->base + spi->cfg->regs->cpol.reg); in stm32_spi_prepare_msg()
|
H A D | spi-sh-msiof.c | 350 u32 cpol, u32 cpha, in sh_msiof_spi_set_pin_regs() 381 tmp |= SICTR_TSCKIZ_SCK | cpol << SICTR_TSCKIZ_POL_SHIFT; in sh_msiof_spi_set_pin_regs() 382 tmp |= SICTR_RSCKIZ_SCK | cpol << SICTR_RSCKIZ_POL_SHIFT; in sh_msiof_spi_set_pin_regs() 384 edge = cpol ^ !cpha; in sh_msiof_spi_set_pin_regs() 349 sh_msiof_spi_set_pin_regs(struct sh_msiof_spi_priv *p, u32 ss, u32 cpol, u32 cpha, u32 tx_hi_z, u32 lsb_first, u32 cs_high) sh_msiof_spi_set_pin_regs() argument
|
H A D | spi-geni-qcom.c | 402 u32 loopback_cfg = 0, cpol = 0, cpha = 0, demux_output_inv = 0; in setup_fifo_params() local 410 cpol = CPOL; in setup_fifo_params() 425 writel(cpol, se->base + SE_SPI_CPOL); in setup_fifo_params()
|
H A D | spi-mt65xx.c | 353 u16 cpha, cpol; in mtk_spi_hw_init() local 359 cpol = spi->mode & SPI_CPOL ? 1 : 0; in mtk_spi_hw_init() 375 if (cpol) in mtk_spi_hw_init()
|
H A D | spi-atmel.c | 437 u32 cpol = (spi->mode & SPI_CPOL) ? SPI_BIT(CPOL) : 0; in cs_activate() local 444 if ((csr ^ cpol) & SPI_BIT(CPOL)) in cs_activate()
|
/kernel/linux/linux-5.10/drivers/spi/ |
H A D | spi-bitbang-txrx.h | 48 unsigned nsecs, unsigned cpol, unsigned flags, in bitbang_txrx_be_cpha0() 51 /* if (cpol == 0) this is SPI_MODE_0; else this is SPI_MODE_2 */ in bitbang_txrx_be_cpha0() 66 setsck(spi, !cpol); in bitbang_txrx_be_cpha0() 73 setsck(spi, cpol); in bitbang_txrx_be_cpha0() 80 unsigned nsecs, unsigned cpol, unsigned flags, in bitbang_txrx_be_cpha1() 83 /* if (cpol == 0) this is SPI_MODE_1; else this is SPI_MODE_3 */ in bitbang_txrx_be_cpha1() 90 setsck(spi, !cpol); in bitbang_txrx_be_cpha1() 99 setsck(spi, cpol); in bitbang_txrx_be_cpha1() 47 bitbang_txrx_be_cpha0(struct spi_device *spi, unsigned nsecs, unsigned cpol, unsigned flags, u32 word, u8 bits) bitbang_txrx_be_cpha0() argument 79 bitbang_txrx_be_cpha1(struct spi_device *spi, unsigned nsecs, unsigned cpol, unsigned flags, u32 word, u8 bits) bitbang_txrx_be_cpha1() argument
|
H A D | spi-cavium.c | 38 bool cpha, cpol; in octeon_spi_do_transfer() local 46 cpol = mode & SPI_CPOL; in octeon_spi_do_transfer() 56 mpi_cfg.s.idlelo = cpha != cpol; in octeon_spi_do_transfer()
|
H A D | spi-lp8841-rtc.c | 68 unsigned usecs, unsigned cpol, unsigned flags, in bitbang_txrx_be_cpha0_lsb() 71 /* if (cpol == 0) this is SPI_MODE_0; else this is SPI_MODE_2 */ in bitbang_txrx_be_cpha0_lsb() 88 setsck(data, !cpol); in bitbang_txrx_be_cpha0_lsb() 91 setsck(data, cpol); in bitbang_txrx_be_cpha0_lsb() 67 bitbang_txrx_be_cpha0_lsb(struct spi_lp8841_rtc *data, unsigned usecs, unsigned cpol, unsigned flags, u32 word, u8 bits) bitbang_txrx_be_cpha0_lsb() argument
|
H A D | spi-slave-mt27xx.c | 117 bool cpha, cpol; in mtk_spi_slave_prepare_message() local 121 cpol = spi->mode & SPI_CPOL ? 1 : 0; in mtk_spi_slave_prepare_message() 128 if (cpol) in mtk_spi_slave_prepare_message()
|
H A D | spi-stm32.c | 195 * @cpol: clock polarity register and polarity bit 206 const struct stm32_spi_reg cpol; member 325 .cpol = { STM32F4_SPI_CR1, STM32F4_SPI_CR1_CPOL }, 343 .cpol = { STM32H7_SPI_CFG2, STM32H7_SPI_CFG2_CPOL }, 1013 setb |= spi->cfg->regs->cpol.mask; in stm32_spi_prepare_msg() 1015 clrb |= spi->cfg->regs->cpol.mask; in stm32_spi_prepare_msg() 1027 dev_dbg(spi->dev, "cpol=%d cpha=%d lsb_first=%d cs_high=%d\n", in stm32_spi_prepare_msg() 1038 (readl_relaxed(spi->base + spi->cfg->regs->cpol.reg) & in stm32_spi_prepare_msg() 1040 spi->base + spi->cfg->regs->cpol.reg); in stm32_spi_prepare_msg()
|
H A D | spi-geni-qcom.c | 294 u32 loopback_cfg = 0, cpol = 0, cpha = 0, demux_output_inv = 0; in setup_fifo_params() local 302 cpol = CPOL; in setup_fifo_params() 317 writel(cpol, se->base + SE_SPI_CPOL); in setup_fifo_params()
|
H A D | spi-mt65xx.c | 198 u16 cpha, cpol; in mtk_spi_prepare_message() local 205 cpol = spi->mode & SPI_CPOL ? 1 : 0; in mtk_spi_prepare_message() 212 if (cpol) in mtk_spi_prepare_message()
|
H A D | spi-sh-msiof.c | 347 u32 cpol, u32 cpha, in sh_msiof_spi_set_pin_regs() 378 tmp |= SICTR_TSCKIZ_SCK | cpol << SICTR_TSCKIZ_POL_SHIFT; in sh_msiof_spi_set_pin_regs() 379 tmp |= SICTR_RSCKIZ_SCK | cpol << SICTR_RSCKIZ_POL_SHIFT; in sh_msiof_spi_set_pin_regs() 381 edge = cpol ^ !cpha; in sh_msiof_spi_set_pin_regs() 346 sh_msiof_spi_set_pin_regs(struct sh_msiof_spi_priv *p, u32 ss, u32 cpol, u32 cpha, u32 tx_hi_z, u32 lsb_first, u32 cs_high) sh_msiof_spi_set_pin_regs() argument
|
H A D | spi-atmel.c | 356 u32 cpol = (spi->mode & SPI_CPOL) ? SPI_BIT(CPOL) : 0; in cs_activate() local 363 if ((csr ^ cpol) & SPI_BIT(CPOL)) in cs_activate()
|