Skip to content

Commit

Permalink
Fix typos.
Browse files Browse the repository at this point in the history
  • Loading branch information
qwandor committed Nov 14, 2023
1 parent ceb6ee1 commit 8457333
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/device/net/dev_raw.rs
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ impl<H: Hal, T: Transport, const QUEUE_SIZE: usize> VirtIONetRaw<H, T, QUEUE_SIZ
/// [`fill_buffer_header`] before transmission. Then it calls [`poll_transmit`]
/// with the returned token to check whether the device has finished handling
/// the request. Once it has, the caller must call [`transmit_complete`] with
/// the same buffers before reading the result (transmitted length).
/// the same buffer before reading the result (transmitted length).
///
/// # Safety
///
Expand Down Expand Up @@ -167,7 +167,7 @@ impl<H: Hal, T: Transport, const QUEUE_SIZE: usize> VirtIONetRaw<H, T, QUEUE_SIZ
///
/// # Safety
///
/// The same buffer must be passed in again as were passed to
/// The same buffer must be passed in again as was passed to
/// [`transmit_begin`] when it returned the token.
///
/// [`transmit_begin`]: Self::transmit_begin
Expand Down Expand Up @@ -222,7 +222,7 @@ impl<H: Hal, T: Transport, const QUEUE_SIZE: usize> VirtIONetRaw<H, T, QUEUE_SIZ
///
/// # Safety
///
/// The same buffer must be passed in again as were passed to
/// The same buffer must be passed in again as was passed to
/// [`receive_begin`] when it returned the token.
///
/// [`receive_begin`]: Self::receive_begin
Expand All @@ -236,8 +236,7 @@ impl<H: Hal, T: Transport, const QUEUE_SIZE: usize> VirtIONetRaw<H, T, QUEUE_SIZ
Ok((NET_HDR_SIZE, packet_len))
}

/// Sends a packet to the network, and blocks until the request
/// completed.
/// Sends a packet to the network, and blocks until the request completed.
pub fn send(&mut self, tx_buf: &[u8]) -> Result {
let header = VirtioNetHdr::default();
if tx_buf.is_empty() {
Expand Down

0 comments on commit 8457333

Please sign in to comment.