diff options
| author | Dario Nieuwenhuis <[email protected]> | 2025-10-06 22:56:31 +0200 |
|---|---|---|
| committer | Dario Nieuwenhuis <[email protected]> | 2025-10-06 23:19:53 +0200 |
| commit | 8730a013c395cf0bf4c2fa8eeb7f138288103039 (patch) | |
| tree | 39eca5fbc4570bd0129c9a291f134de5dab98820 /cyw43/src | |
| parent | abc8e450f936567ad42cb34b5d2a7941b206aa5d (diff) | |
Rustfmt for edition 2024.
Diffstat (limited to 'cyw43/src')
| -rw-r--r-- | cyw43/src/bluetooth.rs | 2 | ||||
| -rw-r--r-- | cyw43/src/bus.rs | 6 | ||||
| -rw-r--r-- | cyw43/src/control.rs | 2 | ||||
| -rw-r--r-- | cyw43/src/ioctl.rs | 2 | ||||
| -rw-r--r-- | cyw43/src/runner.rs | 6 |
5 files changed, 7 insertions, 11 deletions
diff --git a/cyw43/src/bluetooth.rs b/cyw43/src/bluetooth.rs index d176c4b09..332b7048d 100644 --- a/cyw43/src/bluetooth.rs +++ b/cyw43/src/bluetooth.rs | |||
| @@ -15,7 +15,7 @@ use crate::bus::Bus; | |||
| 15 | pub use crate::bus::SpiBusCyw43; | 15 | pub use crate::bus::SpiBusCyw43; |
| 16 | use crate::consts::*; | 16 | use crate::consts::*; |
| 17 | use crate::util::round_up; | 17 | use crate::util::round_up; |
| 18 | use crate::{util, CHIP}; | 18 | use crate::{CHIP, util}; |
| 19 | 19 | ||
| 20 | pub(crate) struct BtState { | 20 | pub(crate) struct BtState { |
| 21 | rx: [BtPacketBuf; 4], | 21 | rx: [BtPacketBuf; 4], |
diff --git a/cyw43/src/bus.rs b/cyw43/src/bus.rs index 8a53484d5..aa2b66a40 100644 --- a/cyw43/src/bus.rs +++ b/cyw43/src/bus.rs | |||
| @@ -340,11 +340,7 @@ where | |||
| 340 | self.status = self.spi.cmd_read(cmd, &mut buf[..len]).await; | 340 | self.status = self.spi.cmd_read(cmd, &mut buf[..len]).await; |
| 341 | 341 | ||
| 342 | // if we read from the backplane, the result is in the second word, after the response delay | 342 | // if we read from the backplane, the result is in the second word, after the response delay |
| 343 | if func == FUNC_BACKPLANE { | 343 | if func == FUNC_BACKPLANE { buf[1] } else { buf[0] } |
| 344 | buf[1] | ||
| 345 | } else { | ||
| 346 | buf[0] | ||
| 347 | } | ||
| 348 | } | 344 | } |
| 349 | 345 | ||
| 350 | async fn writen(&mut self, func: u32, addr: u32, val: u32, len: u32) { | 346 | async fn writen(&mut self, func: u32, addr: u32, val: u32, len: u32) { |
diff --git a/cyw43/src/control.rs b/cyw43/src/control.rs index fd0d4d532..49e3faee4 100644 --- a/cyw43/src/control.rs +++ b/cyw43/src/control.rs | |||
| @@ -10,7 +10,7 @@ use crate::events::{Event, EventSubscriber, Events}; | |||
| 10 | use crate::fmt::Bytes; | 10 | use crate::fmt::Bytes; |
| 11 | use crate::ioctl::{IoctlState, IoctlType}; | 11 | use crate::ioctl::{IoctlState, IoctlType}; |
| 12 | use crate::structs::*; | 12 | use crate::structs::*; |
| 13 | use crate::{countries, events, PowerManagementMode}; | 13 | use crate::{PowerManagementMode, countries, events}; |
| 14 | 14 | ||
| 15 | /// Control errors. | 15 | /// Control errors. |
| 16 | #[derive(Debug)] | 16 | #[derive(Debug)] |
diff --git a/cyw43/src/ioctl.rs b/cyw43/src/ioctl.rs index 35135e296..deccc945d 100644 --- a/cyw43/src/ioctl.rs +++ b/cyw43/src/ioctl.rs | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | use core::cell::{Cell, RefCell}; | 1 | use core::cell::{Cell, RefCell}; |
| 2 | use core::future::{poll_fn, Future}; | 2 | use core::future::{Future, poll_fn}; |
| 3 | use core::task::{Poll, Waker}; | 3 | use core::task::{Poll, Waker}; |
| 4 | 4 | ||
| 5 | use embassy_sync::waitqueue::WakerRegistration; | 5 | use embassy_sync::waitqueue::WakerRegistration; |
diff --git a/cyw43/src/runner.rs b/cyw43/src/runner.rs index 77910b281..7c38be24a 100644 --- a/cyw43/src/runner.rs +++ b/cyw43/src/runner.rs | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | use embassy_futures::select::{select4, Either4}; | 1 | use embassy_futures::select::{Either4, select4}; |
| 2 | use embassy_net_driver_channel as ch; | 2 | use embassy_net_driver_channel as ch; |
| 3 | use embassy_time::{block_for, Duration, Timer}; | 3 | use embassy_time::{Duration, Timer, block_for}; |
| 4 | use embedded_hal_1::digital::OutputPin; | 4 | use embedded_hal_1::digital::OutputPin; |
| 5 | 5 | ||
| 6 | use crate::bus::Bus; | 6 | use crate::bus::Bus; |
| @@ -12,7 +12,7 @@ use crate::ioctl::{IoctlState, IoctlType, PendingIoctl}; | |||
| 12 | use crate::nvram::NVRAM; | 12 | use crate::nvram::NVRAM; |
| 13 | use crate::structs::*; | 13 | use crate::structs::*; |
| 14 | use crate::util::slice8_mut; | 14 | use crate::util::slice8_mut; |
| 15 | use crate::{events, Core, CHIP, MTU}; | 15 | use crate::{CHIP, Core, MTU, events}; |
| 16 | 16 | ||
| 17 | #[cfg(feature = "firmware-logs")] | 17 | #[cfg(feature = "firmware-logs")] |
| 18 | struct LogState { | 18 | struct LogState { |
