Fix lints
This commit is contained in:
parent
96798efb7e
commit
374a31064a
@ -8,7 +8,7 @@ use device_types::{Class, InvalidClass};
|
||||
use pci_rpc::Server;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use spin::Mutex;
|
||||
use x86_64::{instructions::port::{Port, PortWriteOnly}, registers::control};
|
||||
use x86_64::instructions::port::{Port, PortWriteOnly};
|
||||
|
||||
pub mod device_types;
|
||||
|
||||
@ -78,7 +78,7 @@ impl ConfigRaw {
|
||||
match Cursor::new(&self.data).read_le() {
|
||||
Ok(cfg) => Ok(cfg),
|
||||
Err(binread::Error::NoVariantMatch { pos: _ }) => Err(InvalidHeaderType),
|
||||
Err(err) => Err(err).expect("Only NoVariantMatch should be possible"),
|
||||
Err(err) => panic!("Only NoVariantMatch should be possible: {:?}", err),
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -391,9 +391,9 @@ fn main() {
|
||||
let size = !(info_bits) + 1;
|
||||
accessor.write(bar_idx, bar);
|
||||
if bar & 0x1 == 1 {
|
||||
syslog_client.send_text_message("pci", format!("BAR {}: IO {:#x}, size {:#x}", i, bar & (!0x3), size));
|
||||
syslog_client.send_text_message("pci", format!("BAR {}: IO {:#x}, size {:#x}", i, bar & (!0x3), size)).unwrap();
|
||||
} else {
|
||||
syslog_client.send_text_message("pci", format!("BAR {}: MEM {:#x}, size {:#x}", i, bar & (!0xF), size));
|
||||
syslog_client.send_text_message("pci", format!("BAR {}: MEM {:#x}, size {:#x}", i, bar & (!0xF), size)).unwrap();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user