Merge pull request #715 from goldlinker/master

chore: fix some minor issues in the comments
This commit is contained in:
Scott Mabin
2025-10-23 08:43:05 +00:00
committed by GitHub
2 changed files with 2 additions and 2 deletions

View File

@@ -12,7 +12,7 @@ use crate::util::AtomicCell;
/// each with its own `CS` pin.
///
/// Sharing is implemented with a [`AtomicDevice`], which consists of an `UnsafeCell` and an `AtomicBool` "locked" flag.
/// This means it has low overhead, like [`RefCellDevice`](crate::spi::RefCellDevice). Aditionally, it is `Send`,
/// This means it has low overhead, like [`RefCellDevice`](crate::spi::RefCellDevice). Additionally, it is `Send`,
/// which allows sharing a single bus across multiple threads (interrupt priority level), like [`CriticalSectionDevice`](crate::spi::CriticalSectionDevice),
/// while not using critical sections and therefore impacting real-time performance less.
///

View File

@@ -96,7 +96,7 @@ impl<T: tokio::io::AsyncWrite + Unpin + ?Sized> embedded_io_async::Write for Fro
impl<T: tokio::io::AsyncSeek + Unpin + ?Sized> embedded_io_async::Seek for FromTokio<T> {
async fn seek(&mut self, pos: embedded_io::SeekFrom) -> Result<u64, Self::Error> {
// Note: `start_seek` can return an error if there is another seek in progress.
// Therefor it is recommended to call `poll_complete` before any call to `start_seek`.
// Therefore it is recommended to call `poll_complete` before any call to `start_seek`.
poll_fn(|cx| Pin::new(&mut self.inner).poll_complete(cx)).await?;
Pin::new(&mut self.inner).start_seek(pos.into())?;
poll_fn(|cx| Pin::new(&mut self.inner).poll_complete(cx)).await