Skip to content

Commit

Permalink
Update comments
Browse files Browse the repository at this point in the history
  • Loading branch information
vnt-dev committed Dec 31, 2024
1 parent 3c81939 commit d925b2e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions examples/ping-tun-offload-tokio.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ async fn main_entry(mut quit: Receiver<()>) -> Result<(), BoxError> {
config
.address_with_prefix((10, 0, 0, 9), 24)
.platform_config(|config| {
// After enabling the offload, you need to use recv_multiple and send_multiple to read and write data.
config.offload(true);
})
.mtu(1500)
Expand Down
1 change: 1 addition & 0 deletions examples/read-offload.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ fn main_entry(quit: Receiver<()>) -> Result<(), BoxError> {
config
.address_with_prefix("10.0.0.2", 24u8)
.platform_config(|config| {
// After enabling the offload, you need to use recv_multiple and send_multiple to read and write data.
config.offload(true);
})
.mtu(1500)
Expand Down
2 changes: 1 addition & 1 deletion src/platform/linux/device.rs
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ impl Device {
}
/// send multiple fragmented data packets.
/// GROTable can be reused, as it is used to assist in data merging.
/// Offset is the starting position of the data. Need to meet offset>10.
/// Offset is the starting position of the data. Need to meet offset>=10.
pub fn send_multiple<B: ExpandBuffer>(
&self,
gro_table: &mut GROTable,
Expand Down

0 comments on commit d925b2e

Please sign in to comment.