Lines Matching refs:bits_per_word

141 				      int bits_per_word, int msb_first)  in fsl_spi_qe_cpu_set_shifts()  argument
146 if (bits_per_word <= 8) { in fsl_spi_qe_cpu_set_shifts()
149 } else if (bits_per_word <= 16) { in fsl_spi_qe_cpu_set_shifts()
154 if (bits_per_word <= 8) in fsl_spi_qe_cpu_set_shifts()
160 int bits_per_word, int msb_first) in fsl_spi_grlib_set_shifts() argument
164 if (bits_per_word <= 16) { in fsl_spi_grlib_set_shifts()
167 *tx_shift = 32 - bits_per_word; /* MSB in bit 31 */ in fsl_spi_grlib_set_shifts()
169 *rx_shift = 16 - bits_per_word; /* MSB in bit 15 */ in fsl_spi_grlib_set_shifts()
177 int bits_per_word) in mspi_apply_cpu_mode_quirks() argument
181 if (bits_per_word <= 8) { in mspi_apply_cpu_mode_quirks()
184 } else if (bits_per_word <= 16) { in mspi_apply_cpu_mode_quirks()
187 } else if (bits_per_word <= 32) { in mspi_apply_cpu_mode_quirks()
195 bits_per_word, in mspi_apply_cpu_mode_quirks()
203 return bits_per_word; in mspi_apply_cpu_mode_quirks()
208 int bits_per_word) in mspi_apply_qe_mode_quirks() argument
217 bits_per_word > 8) in mspi_apply_qe_mode_quirks()
219 if (bits_per_word > 8) in mspi_apply_qe_mode_quirks()
221 return bits_per_word; in mspi_apply_qe_mode_quirks()
228 int bits_per_word = 0; in fsl_spi_setup_transfer() local
236 bits_per_word = t->bits_per_word; in fsl_spi_setup_transfer()
241 if (!bits_per_word) in fsl_spi_setup_transfer()
242 bits_per_word = spi->bits_per_word; in fsl_spi_setup_transfer()
248 bits_per_word = mspi_apply_cpu_mode_quirks(cs, spi, in fsl_spi_setup_transfer()
250 bits_per_word); in fsl_spi_setup_transfer()
252 bits_per_word = mspi_apply_qe_mode_quirks(cs, spi, in fsl_spi_setup_transfer()
253 bits_per_word); in fsl_spi_setup_transfer()
255 if (bits_per_word < 0) in fsl_spi_setup_transfer()
256 return bits_per_word; in fsl_spi_setup_transfer()
258 if (bits_per_word == 32) in fsl_spi_setup_transfer()
259 bits_per_word = 0; in fsl_spi_setup_transfer()
261 bits_per_word = bits_per_word - 1; in fsl_spi_setup_transfer()
267 cs->hw_mode |= SPMODE_LEN(bits_per_word); in fsl_spi_setup_transfer()
313 u8 bits_per_word; in fsl_spi_bufs() local
317 bits_per_word = spi->bits_per_word; in fsl_spi_bufs()
318 if (t->bits_per_word) in fsl_spi_bufs()
319 bits_per_word = t->bits_per_word; in fsl_spi_bufs()
321 if (bits_per_word > 8) { in fsl_spi_bufs()
327 if (bits_per_word > 16) { in fsl_spi_bufs()
373 if (t->len < 256 || t->bits_per_word != 8) in fsl_spi_do_one_msg()
376 t->bits_per_word = 32; in fsl_spi_do_one_msg()
378 t->bits_per_word = 16; in fsl_spi_do_one_msg()
399 if (cs_change || last_bpw != t->bits_per_word) in fsl_spi_do_one_msg()
403 last_bpw = t->bits_per_word; in fsl_spi_do_one_msg()