Lines Matching refs:mxs_slave
54 struct mxs_spi_slave *mxs_slave; in spi_setup_slave() local
61 mxs_slave = spi_alloc_slave(struct mxs_spi_slave, bus, cs); in spi_setup_slave()
62 if (!mxs_slave) in spi_setup_slave()
68 mxs_slave->max_khz = max_hz / 1000; in spi_setup_slave()
69 mxs_slave->mode = mode; in spi_setup_slave()
70 mxs_slave->regs = mxs_ssp_regs_by_bus(bus); in spi_setup_slave()
72 return &mxs_slave->slave; in spi_setup_slave()
75 free(mxs_slave); in spi_setup_slave()
81 struct mxs_spi_slave *mxs_slave = to_mxs_slave(slave); in spi_free_slave() local
82 free(mxs_slave); in spi_free_slave()
87 struct mxs_spi_slave *mxs_slave = to_mxs_slave(slave); in spi_claim_bus() local
88 struct mxs_ssp_regs *ssp_regs = mxs_slave->regs; in spi_claim_bus()
98 reg |= (mxs_slave->mode & SPI_CPOL) ? SSP_CTRL1_POLARITY : 0; in spi_claim_bus()
99 reg |= (mxs_slave->mode & SPI_CPHA) ? SSP_CTRL1_PHASE : 0; in spi_claim_bus()
104 mxs_set_ssp_busclock(slave->bus, mxs_slave->max_khz); in spi_claim_bus()
308 struct mxs_spi_slave *mxs_slave = to_mxs_slave(slave); in spi_xfer() local
309 struct mxs_ssp_regs *ssp_regs = mxs_slave->regs; in spi_xfer()
353 return mxs_spi_xfer_pio(mxs_slave, data, len, write, flags); in spi_xfer()
356 return mxs_spi_xfer_dma(mxs_slave, data, len, write, flags); in spi_xfer()