Skip to content

Commit

Permalink
Run rustfmt
Browse files Browse the repository at this point in the history
Signed-off-by: Nick Spinale <[email protected]>
  • Loading branch information
nspin committed Oct 28, 2024
1 parent 902810b commit b532b4a
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 4 deletions.
10 changes: 8 additions & 2 deletions crates/drivers/virtio/net/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,14 @@ impl<H: Hal, T: Transport> GetNetDeviceMeta for DeviceWrapper<H, T> {
}

impl<H: Hal, T: Transport> Device for DeviceWrapper<H, T> {
type RxToken<'a> = VirtioRxToken<H, T> where Self: 'a;
type TxToken<'a> = VirtioTxToken<H, T> where Self: 'a;
type RxToken<'a>
= VirtioRxToken<H, T>
where
Self: 'a;
type TxToken<'a>
= VirtioTxToken<H, T>
where
Self: 'a;

fn receive(&mut self, _timestamp: Instant) -> Option<(Self::RxToken<'_>, Self::TxToken<'_>)> {
match self.inner.borrow_mut().receive() {
Expand Down
14 changes: 12 additions & 2 deletions crates/sel4-shared-ring-buffer/smoltcp/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,18 @@ impl<A: AbstractBounceBufferAllocator, R: RawMutex, P: AbstractRcT> DeviceImpl<A
}

impl<A: AbstractBounceBufferAllocator, R: RawMutex, P: AbstractRcT> Device for DeviceImpl<A, R, P> {
type RxToken<'a> = RxToken<A, R, P> where A: 'a, R: 'a, P: 'a;
type TxToken<'a> = TxToken<A, R, P> where A: 'a, R: 'a, P: 'a;
type RxToken<'a>
= RxToken<A, R, P>
where
A: 'a,
R: 'a,
P: 'a;
type TxToken<'a>
= TxToken<A, R, P>
where
A: 'a,
R: 'a,
P: 'a;

fn capabilities(&self) -> DeviceCapabilities {
self.inner().lock().caps().clone()
Expand Down

0 comments on commit b532b4a

Please sign in to comment.