forked from rcore-os/zCore
fix cargo clippy for hypervisor
This commit is contained in:
parent
d95545cd8b
commit
f753d655cb
|
@ -114,7 +114,7 @@ impl GuestPhysMemorySetTrait for GuestPhysMemorySet {
|
|||
.handle_page_fault(gpaddr, mapping.get_flags())
|
||||
.map_err(From::from)
|
||||
} else {
|
||||
return Err(RvmError::NotFound);
|
||||
Err(RvmError::NotFound)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -48,6 +48,7 @@ pub struct VmmPageTable(ArchRvmPageTable);
|
|||
struct VmmPageTableFlags(MMUFlags);
|
||||
|
||||
impl VmmPageTable {
|
||||
#[allow(clippy::new_without_default)]
|
||||
pub fn new() -> Self {
|
||||
Self(ArchRvmPageTable::new())
|
||||
}
|
||||
|
|
|
@ -98,7 +98,7 @@ impl Syscall<'_> {
|
|||
}
|
||||
let proc = self.thread.proc();
|
||||
let guest = proc.get_object_with_rights::<Guest>(guest_handle, Rights::MANAGE_PROCESS)?;
|
||||
let vcpu = Vcpu::new(guest, entry, self.thread.clone())?;
|
||||
let vcpu = Vcpu::new(guest, entry, (*self.thread).clone())?;
|
||||
let handle_value = proc.add_handle(Handle::new(vcpu, Rights::DEFAULT_VCPU));
|
||||
out.write(handle_value)?;
|
||||
Ok(())
|
||||
|
|
Loading…
Reference in New Issue