misc: Fix clippy issues

Signed-off-by: Bo Chen <chen.bo@intel.com>
This commit is contained in:
Bo Chen
2022-11-01 14:52:40 -07:00
committed by Sebastien Boeuf
parent 9266ea4995
commit a9ec0f33c0
35 changed files with 78 additions and 92 deletions

View File

@@ -114,7 +114,7 @@ impl Aml for AcpiGedDevice {
&aml::ResourceTemplate::new(vec![&aml::AddressSpace::new_memory(
aml::AddressSpaceCachable::NotCacheable,
true,
self.address.0 as u64,
self.address.0,
self.address.0 + GED_DEVICE_ACPI_SIZE as u64 - 1,
)]),
),

View File

@@ -199,7 +199,7 @@ impl Serial {
}
fn handle_write(&mut self, offset: u8, v: u8) -> Result<()> {
match offset as u8 {
match offset {
DLAB_LOW if self.is_dlab_set() => {
self.baud_divisor = (self.baud_divisor & 0xff00) | u16::from(v)
}