Merge pull request #3362 from showier-drastic/main

stm32/spi: issue correct DMA word length when reading to prevent hang
This commit is contained in:
Dario Nieuwenhuis 2024-09-22 19:39:47 +00:00 committed by GitHub
commit b9553badb3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -783,7 +783,7 @@ impl<'d> Spi<'d, Async> {
let rx_f = unsafe { self.rx_dma.as_mut().unwrap().read(rx_src, data, Default::default()) };
let tx_dst = self.info.regs.tx_ptr();
let clock_byte = 0x00u8;
let clock_byte = W::default();
let tx_f = unsafe {
self.tx_dma
.as_mut()
@ -1195,7 +1195,7 @@ trait SealedWord {
/// Word sizes usable for SPI.
#[allow(private_bounds)]
pub trait Word: word::Word + SealedWord {}
pub trait Word: word::Word + SealedWord + Default {}
macro_rules! impl_word {
($T:ty, $config:expr) => {