aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--embassy-mcxa/src/dma.rs10
1 files changed, 7 insertions, 3 deletions
diff --git a/embassy-mcxa/src/dma.rs b/embassy-mcxa/src/dma.rs
index e31cf5907..8d519d99b 100644
--- a/embassy-mcxa/src/dma.rs
+++ b/embassy-mcxa/src/dma.rs
@@ -773,7 +773,12 @@ impl<C: Channel> DmaChannel<C> {
773 /// 773 ///
774 /// The source and destination buffers must remain valid for the 774 /// The source and destination buffers must remain valid for the
775 /// duration of the transfer. 775 /// duration of the transfer.
776 pub fn mem_to_mem<W: Word>(&self, src: &[W], dst: &mut [W], options: TransferOptions) -> Result<Transfer<'_>, Error> { 776 pub fn mem_to_mem<W: Word>(
777 &self,
778 src: &[W],
779 dst: &mut [W],
780 options: TransferOptions,
781 ) -> Result<Transfer<'_>, Error> {
777 let mut invalid = false; 782 let mut invalid = false;
778 invalid |= src.is_empty(); 783 invalid |= src.is_empty();
779 invalid |= src.len() > dst.len(); 784 invalid |= src.len() > dst.len();
@@ -1789,7 +1794,7 @@ impl<'a> Transfer<'a> {
1789 if es.err().is_error() { 1794 if es.err().is_error() {
1790 // Currently, all error fields are in the lowest 8 bits, as-casting truncates 1795 // Currently, all error fields are in the lowest 8 bits, as-casting truncates
1791 let errs = es.bits() as u8; 1796 let errs = es.bits() as u8;
1792 return Poll::Ready(Err(TransferErrorRaw(errs))) 1797 return Poll::Ready(Err(TransferErrorRaw(errs)));
1793 } 1798 }
1794 1799
1795 // Check if we're past the half-way point 1800 // Check if we're past the half-way point
@@ -1907,7 +1912,6 @@ impl TransferErrorRaw {
1907 pub fn has_source_address_err(&self) -> bool { 1912 pub fn has_source_address_err(&self) -> bool {
1908 (self.0 & (1 << 7)) != 0 1913 (self.0 & (1 << 7)) != 0
1909 } 1914 }
1910
1911} 1915}
1912 1916
1913impl Iterator for TransferErrorRawIter { 1917impl Iterator for TransferErrorRawIter {