aboutsummaryrefslogtreecommitdiff
path: root/embassy-rp/src/dma.rs
diff options
context:
space:
mode:
authorCaleb Jamison <[email protected]>2024-08-12 04:32:31 -0400
committerCaleb Jamison <[email protected]>2024-08-12 04:32:31 -0400
commit778241fd71b8a0cb541d23b69c3f9e47ec2753ff (patch)
tree101e75f936463a8d3dc6a6f123d4484210717be4 /embassy-rp/src/dma.rs
parent9dc4375f185d5098d9b61116bb5c5279e7298222 (diff)
Fix CI, rename private feature, address comments from dirbaio.
Diffstat (limited to 'embassy-rp/src/dma.rs')
-rw-r--r--embassy-rp/src/dma.rs13
1 files changed, 8 insertions, 5 deletions
diff --git a/embassy-rp/src/dma.rs b/embassy-rp/src/dma.rs
index b00ab3f3b..34abe3e2d 100644
--- a/embassy-rp/src/dma.rs
+++ b/embassy-rp/src/dma.rs
@@ -147,7 +147,7 @@ fn copy_inner<'a, C: Channel>(
147 p.trans_count().write(|w| { 147 p.trans_count().write(|w| {
148 *w = len as u32; 148 *w = len as u32;
149 }); 149 });
150 #[cfg(feature = "rp235x")] 150 #[cfg(feature = "_rp235x")]
151 p.trans_count().write(|w| { 151 p.trans_count().write(|w| {
152 w.set_mode(0.into()); 152 w.set_mode(0.into());
153 w.set_count(len as u32); 153 w.set_count(len as u32);
@@ -208,7 +208,10 @@ impl<'a, C: Channel> Future for Transfer<'a, C> {
208 } 208 }
209} 209}
210 210
211#[cfg(feature = "rp2040")]
211pub(crate) const CHANNEL_COUNT: usize = 12; 212pub(crate) const CHANNEL_COUNT: usize = 12;
213#[cfg(feature = "_rp235x")]
214pub(crate) const CHANNEL_COUNT: usize = 16;
212const NEW_AW: AtomicWaker = AtomicWaker::new(); 215const NEW_AW: AtomicWaker = AtomicWaker::new();
213static CHANNEL_WAKERS: [AtomicWaker; CHANNEL_COUNT] = [NEW_AW; CHANNEL_COUNT]; 216static CHANNEL_WAKERS: [AtomicWaker; CHANNEL_COUNT] = [NEW_AW; CHANNEL_COUNT];
214 217
@@ -303,11 +306,11 @@ channel!(DMA_CH8, 8);
303channel!(DMA_CH9, 9); 306channel!(DMA_CH9, 9);
304channel!(DMA_CH10, 10); 307channel!(DMA_CH10, 10);
305channel!(DMA_CH11, 11); 308channel!(DMA_CH11, 11);
306#[cfg(feature = "rp235x")] 309#[cfg(feature = "_rp235x")]
307channel!(DMA_CH12, 12); 310channel!(DMA_CH12, 12);
308#[cfg(feature = "rp235x")] 311#[cfg(feature = "_rp235x")]
309channel!(DMA_CH13, 13); 312channel!(DMA_CH13, 13);
310#[cfg(feature = "rp235x")] 313#[cfg(feature = "_rp235x")]
311channel!(DMA_CH14, 14); 314channel!(DMA_CH14, 14);
312#[cfg(feature = "rp235x")] 315#[cfg(feature = "_rp235x")]
313channel!(DMA_CH15, 15); 316channel!(DMA_CH15, 15);