Skip to content

Commit 74f9e3d

Browse files
committed
Fix warnings
1 parent 81002a8 commit 74f9e3d

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

os/src/drivers/gpu/mod.rs

-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ use tinybmp::Bmp;
77
use virtio_drivers::{VirtIOGpu, VirtIOHeader};
88
const VIRTIO7: usize = 0x10007000;
99
pub trait GpuDevice: Send + Sync + Any {
10-
fn update_cursor(&self);
1110
fn get_framebuffer(&self) -> &mut [u8];
1211
fn flush(&self);
1312
}
@@ -64,5 +63,4 @@ impl GpuDevice for VirtIOGpuWrapper {
6463
core::slice::from_raw_parts_mut(ptr, self.fb.len())
6564
}
6665
}
67-
fn update_cursor(&self) {}
6866
}

os/src/net/tcp.rs

+2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,9 @@ pub struct TCP {
1818
pub target: IPv4,
1919
pub sport: u16,
2020
pub dport: u16,
21+
#[allow(unused)]
2122
pub seq: u32,
23+
#[allow(unused)]
2224
pub ack: u32,
2325
pub socket_index: usize,
2426
}

os/src/trap/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use core::arch::{asm, global_asm};
1111
use riscv::register::{
1212
mtvec::TrapMode,
1313
scause::{self, Exception, Interrupt, Trap},
14-
sie, sip, sscratch, sstatus, stval, stvec,
14+
sie, sscratch, sstatus, stval, stvec,
1515
};
1616

1717
global_asm!(include_str!("trap.S"));

0 commit comments

Comments
 (0)